Home
last modified time | relevance | path

Searched refs:clock (Results 1 – 25 of 217) sorted by relevance

123456789

/frameworks/native/services/surfaceflinger/tests/unittests/
DOneShotTimerTest.cpp51 fake::FakeClock* clock = new fake::FakeClock(); in TEST_F() local
53 "TestTimer", 3ms, [] {}, [] {}, std::unique_ptr<fake::FakeClock>(clock)); in TEST_F()
57 fake::FakeClock* clock = new fake::FakeClock(); in TEST_F() local
61 std::unique_ptr<fake::FakeClock>(clock)); in TEST_F()
66 clock->advanceTime(2ms); in TEST_F()
69 clock->advanceTime(2ms); in TEST_F()
77 fake::FakeClock* clock = new fake::FakeClock(); in TEST_F() local
81 std::unique_ptr<fake::FakeClock>(clock)); in TEST_F()
86 clock->advanceTime(2ms); in TEST_F()
90 clock->advanceTime(2ms); in TEST_F()
[all …]
/frameworks/base/packages/SystemUI/compose/features/src/com/android/systemui/keyguard/ui/composable/section/
DWeatherClockSection.kt54 clock: ClockController, in Time()
66 clock = clock, in Time()
74 clock: ClockController, in SceneScope()
79 clock = clock, in SceneScope()
87 clock: ClockController, in Weather()
92 clock = clock, in Weather()
100 clock: ClockController, in SceneScope()
105 clock = clock, in SceneScope()
113 clock: ClockController, in Temperature()
118 clock = clock, in Temperature()
[all …]
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/util/concurrency/
DMockExecutorHandlerTest.kt34 val clock = FakeSystemClock() in testNoDelay() constant
35 val fakeExecutor = FakeExecutor(clock) in testNoDelay()
38 assertEquals(10000, clock.uptimeMillis()) in testNoDelay()
44 assertEquals(10000, clock.uptimeMillis()) in testNoDelay()
48 assertEquals(10000, clock.uptimeMillis()) in testNoDelay()
54 assertEquals(10000, clock.uptimeMillis()) in testNoDelay()
59 assertEquals(10000, clock.uptimeMillis()) in testNoDelay()
69 assertEquals(10000, clock.uptimeMillis()) in testNoDelay()
74 assertEquals(10000, clock.uptimeMillis()) in testNoDelay()
81 val clock = FakeSystemClock() in testDelayed() constant
[all …]
DFakeExecutorTest.java52 FakeSystemClock clock = new FakeSystemClock(); in testNoDelay() local
53 FakeExecutor fakeExecutor = new FakeExecutor(clock); in testNoDelay()
56 assertEquals(10000, clock.uptimeMillis()); in testNoDelay()
62 assertEquals(10000, clock.uptimeMillis()); in testNoDelay()
66 assertEquals(10000, clock.uptimeMillis()); in testNoDelay()
72 assertEquals(10000, clock.uptimeMillis()); in testNoDelay()
77 assertEquals(10000, clock.uptimeMillis()); in testNoDelay()
87 assertEquals(10000, clock.uptimeMillis()); in testNoDelay()
92 assertEquals(10000, clock.uptimeMillis()); in testNoDelay()
101 FakeSystemClock clock = new FakeSystemClock(); in testDelayed() local
[all …]
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/shared/clocks/
DDefaultClockProviderTest.kt95 val clock = provider.createClock(DEFAULT_CLOCK_ID) in createClock() constant
96 assertNotNull(clock) in createClock()
97 assertEquals(mockSmallClockView, clock.smallClock.view) in createClock()
98 assertEquals(mockLargeClockView, clock.largeClock.view) in createClock()
103 val clock = provider.createClock(DEFAULT_CLOCK_ID) in createClock() constant
107 clock.initialize(resources, 0f, 0f) in createClock()
121 val clock = provider.createClock(DEFAULT_CLOCK_ID) in createClock() constant
122 clock.smallClock.events.onTimeTick() in createClock()
123 clock.largeClock.events.onTimeTick() in createClock()
131 val clock = provider.createClock(DEFAULT_CLOCK_ID) in createClock() constant
[all …]
/frameworks/base/packages/SystemUI/src/com/android/keyguard/
DClockEventController.kt109 var clock: ClockController? = null in <lambda>() variable in com.android.keyguard.ClockEventController
117 private fun disconnectClock(clock: ClockController?) { in <lambda>()
118 if (clock == null) { in <lambda>()
122 clock.smallClock.view.removeOnAttachStateChangeListener(it) in <lambda>()
126 clock.largeClock.view.removeOnAttachStateChangeListener(it) in <lambda>()
130 private fun connectClock(clock: ClockController?) { in <lambda>()
131 if (clock == null) { in <lambda>()
134 val clockStr = clock.toString() in <lambda>()
137 clock.initialize(resources, dozeAmount, 0f) in <lambda>()
144 clock.smallClock.view, in <lambda>()
[all …]
DKeyguardClockSwitchController.java492 ClockController clock = getClock(); in displayClock() local
494 if (clock != null && animate && appeared && clockSize == LARGE) { in displayClock()
495 mUiExecutor.executeDelayed(() -> clock.getLargeClock().getAnimations().enter(), in displayClock()
504 ClockController clock = getClock(); in animateFoldToAod() local
505 if (clock != null) { in animateFoldToAod()
506 clock.getSmallClock().getAnimations().fold(foldFraction); in animateFoldToAod()
507 clock.getLargeClock().getAnimations().fold(foldFraction); in animateFoldToAod()
519 ClockController clock = getClock(); in refresh() local
520 if (clock != null) { in refresh()
521 clock.getSmallClock().getEvents().onTimeTick(); in refresh()
[all …]
DConnectedDisplayKeyguardPresentation.kt60 private var clock: View? = null variable
87 clock?.let { in onLayoutChange()
123 clock = requireViewById(R.id.clock) in onCreate()
126 .build(clock as KeyguardStatusView, display) in onCreate()
137 clockEventController.registerListeners(clock!!) in onAttachedToWindow()
158 clock?.removeOnLayoutChangeListener(layoutChangeListener) in setClock()
162 clock = faceController.view.also { it.addOnLayoutChangeListener(layoutChangeListener) } in setClock()
164 clock, in setClock()
172 clockEventController.clock = clockController in setClock()
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/collection/coordinator/
DSmartspaceDedupingCoordinatorTest.kt78 private val clock = FakeSystemClock() constant in com.android.systemui.statusbar.notification.collection.coordinator.SmartspaceDedupingCoordinatorTest
79 private val executor = FakeExecutor(clock)
80 private val now = clock.currentTimeMillis()
97 clock in setUp()
205 clock.advanceTime(20000) in testExceptionExpires()
224 clock.advanceTime(20000) in testExceptionIsEventuallyFiltered()
227 assertTrue(filter.shouldFilterOut(entry1HasRecentlyAlerted, clock.uptimeMillis())) in testExceptionIsEventuallyFiltered()
236 assertFalse(filter.shouldFilterOut(entry1HasRecentlyAlerted, clock.uptimeMillis())) in testExceptionIsUpdated()
240 .setLastAudiblyAlertedMs(clock.currentTimeMillis() - 500) in testExceptionIsUpdated()
243 assertFalse(filter.shouldFilterOut(entry1HasRecentlyAlerted, clock.uptimeMillis())) in testExceptionIsUpdated()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/keyguard/ui/view/layout/sections/
DClockSection.kt93 keyguardClockViewModel.currentClock.value?.let { clock -> in applyConstraints() method
94 constraintSet.applyDeltaFrom(buildConstraints(clock, constraintSet)) in applyConstraints()
101 clock: ClockController, in buildConstraints()
106 getNonTargetClockFace(clock).applyConstraints(constraintSet) in buildConstraints()
107 getTargetClockFace(clock).applyConstraints(constraintSet) in buildConstraints()
111 setVisibility(getTargetClockFace(clock).views, VISIBLE) in buildConstraints()
112 setVisibility(getNonTargetClockFace(clock).views, GONE) in buildConstraints()
113 setAlpha(getTargetClockFace(clock).views, 1F) in buildConstraints()
114 setAlpha(getNonTargetClockFace(clock).views, 0F) in buildConstraints()
121 private fun getTargetClockFace(clock: ClockController): ClockFaceLayout = in getTargetClockFace()
[all …]
/frameworks/base/location/java/android/location/
DGnssClock.java78 public void set(GnssClock clock) { in set() argument
79 mFlags = clock.mFlags; in set()
80 mLeapSecond = clock.mLeapSecond; in set()
81 mTimeNanos = clock.mTimeNanos; in set()
82 mTimeUncertaintyNanos = clock.mTimeUncertaintyNanos; in set()
83 mFullBiasNanos = clock.mFullBiasNanos; in set()
84 mBiasNanos = clock.mBiasNanos; in set()
85 mBiasUncertaintyNanos = clock.mBiasUncertaintyNanos; in set()
86 mDriftNanosPerSecond = clock.mDriftNanosPerSecond; in set()
87 mDriftUncertaintyNanosPerSecond = clock.mDriftUncertaintyNanosPerSecond; in set()
[all …]
DGpsClock.java83 public void set(GpsClock clock) { in set() argument
84 mFlags = clock.mFlags; in set()
85 mLeapSecond = clock.mLeapSecond; in set()
86 mType = clock.mType; in set()
87 mTimeInNs = clock.mTimeInNs; in set()
88 mTimeUncertaintyInNs = clock.mTimeUncertaintyInNs; in set()
89 mFullBiasInNs = clock.mFullBiasInNs; in set()
90 mBiasInNs = clock.mBiasInNs; in set()
91 mBiasUncertaintyInNs = clock.mBiasUncertaintyInNs; in set()
92 mDriftInNsPerSec = clock.mDriftInNsPerSec; in set()
[all …]
DGpsMeasurementsEvent.java82 public GpsMeasurementsEvent(GpsClock clock, GpsMeasurement[] measurements) { in GpsMeasurementsEvent() argument
83 if (clock == null) { in GpsMeasurementsEvent()
91 mClock = clock; in GpsMeasurementsEvent()
115 GpsClock clock = in.readParcelable(classLoader, android.location.GpsClock.class);
121 return new GpsMeasurementsEvent(clock, measurementsArray);
DGnssMeasurementsEvent.java130 @NonNull GnssClock clock, in GnssMeasurementsEvent() argument
137 mClock = clock; in GnssMeasurementsEvent()
195 GnssClock clock = in.readParcelable(getClass().getClassLoader(),
201 return new GnssMeasurementsEvent(flag, clock, measurements, agcs, isFullTracking);
270 public Builder setClock(@NonNull GnssClock clock) { in setClock() argument
271 Preconditions.checkNotNull(clock); in setClock()
272 mClock = clock; in setClock()
/frameworks/base/packages/SystemUI/docs/
Dclock-plugins.md3 The clock appearing on the lock screen and always on display (AOD) can be customized via the
7 The lockscreen code has two main components, a [clock customization library](../customization), and
9 the default clock, and some support code for managing clocks and picking the correct one to render.
12 clock controller.
16 serve as the interface between the lockscreen (or other host application) and the clock that is
23 implement these interfaces for the default lockscreen clock. They handle relevant events from the
24 lockscreen to update and control the small and large clock view as appropriate.
26 is the view that DefaultClockController uses to render both the small and large clock.
31 determines which clock should be shown, and handles creating them. It does this by maintaining a
43 SystemUI event dispatchers to the clock controllers. It maintains a set of event listeners, but
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/keyguard/domain/interactor/
DKeyguardClockInteractor.kt75 var clock: ClockController? by keyguardClockRepository.clockEventController::clock in <lambda>() variable
142 return clock?.let { clock -> clock.config.id } in <lambda>() method
150 clock?.let { clock -> in <lambda>() method
151 clock.smallClock.animations.fold(foldFraction) in <lambda>()
152 clock.largeClock.animations.fold(foldFraction) in <lambda>()
/frameworks/base/services/core/jni/gnss/
DGnssMeasurementCallback.cpp235 void setMeasurementData(JNIEnv* env, jobject& callbacksObj, jobject clock, in setMeasurementData() argument
242 method_gnssMeasurementsEventBuilderSetClock, clock); in setMeasurementData()
318 void setClockFields_V1_0(const T_Clock& clock, JavaObject& object) { in setClockFields_V1_0() argument
319 uint32_t flags = static_cast<uint32_t>(clock.gnssClockFlags); in setClockFields_V1_0()
321 SET(LeapSecond, static_cast<int32_t>(clock.leapSecond)); in setClockFields_V1_0()
325 SET(TimeUncertaintyNanos, clock.timeUncertaintyNs); in setClockFields_V1_0()
329 SET(FullBiasNanos, clock.fullBiasNs); in setClockFields_V1_0()
333 SET(BiasNanos, clock.biasNs); in setClockFields_V1_0()
337 SET(BiasUncertaintyNanos, clock.biasUncertaintyNs); in setClockFields_V1_0()
341 SET(DriftNanosPerSecond, clock.driftNsps); in setClockFields_V1_0()
[all …]
/frameworks/base/services/tests/powerstatstests/src/com/android/server/power/stats/
DMockBatteryStatsImpl.java63 MockBatteryStatsImpl(Clock clock) { in MockBatteryStatsImpl() argument
64 this(clock, null); in MockBatteryStatsImpl()
67 MockBatteryStatsImpl(Clock clock, File historyDirectory) { in MockBatteryStatsImpl() argument
68 this(clock, historyDirectory, new Handler(Looper.getMainLooper())); in MockBatteryStatsImpl()
71 MockBatteryStatsImpl(Clock clock, File historyDirectory, Handler handler) { in MockBatteryStatsImpl() argument
72 this(DEFAULT_CONFIG, clock, historyDirectory, handler, new PowerStatsUidResolver()); in MockBatteryStatsImpl()
75 MockBatteryStatsImpl(BatteryStatsConfig config, Clock clock, File historyDirectory) { in MockBatteryStatsImpl() argument
76 this(config, clock, historyDirectory, new Handler(Looper.getMainLooper()), in MockBatteryStatsImpl()
80 MockBatteryStatsImpl(BatteryStatsConfig config, Clock clock, File historyDirectory, in MockBatteryStatsImpl() argument
82 super(config, clock, new MonotonicClock(0, clock), historyDirectory, handler, in MockBatteryStatsImpl()
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/dump/
DLogBufferFreezerTest.kt55 val clock = FakeSystemClock() constant in com.android.systemui.dump.LogBufferFreezerTest
56 val executor = FakeExecutor(clock)
93 clock.advanceTime(501) in testBuffersAreUnfrozenAfterTimeout()
104 clock.advanceTime(499) in testBuffersAreNotPrematurelyUnfrozen()
113 clock.advanceTime(101) in testBuffersAreNotPrematurelyUnfrozen()
117 clock.advanceTime(401) in testBuffersAreNotPrematurelyUnfrozen()
/frameworks/opt/net/wifi/libs/WifiTrackerLib/src/com/android/wifitrackerlib/
DNetworkDetailsTracker.java69 @NonNull Clock clock, in createNetworkDetailsTracker() argument
81 clock, in createNetworkDetailsTracker()
96 @NonNull Clock clock, in createNetworkDetailsTracker() argument
102 connectivityManager, mainHandler, workerHandler, clock, in createNetworkDetailsTracker()
106 connectivityManager, mainHandler, workerHandler, clock, in createNetworkDetailsTracker()
110 connectivityManager, mainHandler, workerHandler, clock, in createNetworkDetailsTracker()
130 @NonNull Clock clock, in NetworkDetailsTracker() argument
135 mainHandler, workerHandler, clock, maxScanAgeMillis, scanIntervalMillis, in NetworkDetailsTracker()
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/keyguard/ui/binder/
DKeyguardClockViewBinderTest.kt49 @Mock private lateinit var clock: ClockController variable in com.android.systemui.keyguard.ui.binder.KeyguardClockViewBinderTest
71 KeyguardClockViewBinder.addClockViews(clock, rootView) in addClockViews_WeatherClock()
79 KeyguardClockViewBinder.addClockViews(clock, rootView) in addClockViews_nonWeatherClock()
115 whenever(clock.config).thenReturn(clockConfig) in setupWeatherClock()
121 whenever(clock.config).thenReturn(clockConfig) in setupNonWeatherClock()
127 whenever(clock.largeClock).thenReturn(largeClock) in setupClock()
128 whenever(clock.smallClock).thenReturn(smallClock) in setupClock()
131 currentClock.value = clock in setupClock()
/frameworks/base/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/
DKeyguardClockViewBinder.kt142 clockController?.let { clock -> in <lambda>() method
145 clock.smallClock.layout.views.forEach { burnInLayer?.removeView(it) } in <lambda>()
148 clock.smallClock.layout.views.forEach { burnInLayer?.addView(it) } in <lambda>()
164 lastClock?.let { clock -> in <lambda>() method
165 clock.smallClock.layout.views.forEach { in <lambda>()
169 clock.largeClock.layout.views.forEach { rootView.removeView(it) } in <lambda>()
181 clockController?.let { clock -> in <lambda>() method
182 clock.smallClock.layout.views.forEach { in <lambda>()
188 clock.largeClock.layout.views.forEach { in <lambda>()
/frameworks/base/packages/SystemUI/src/com/android/systemui/keyguard/ui/preview/
DKeyguardPreviewRenderer.kt588 clockController.clock?.run { in <lambda>()
606 if (clockController.clock !is DefaultClockController) { in <lambda>()
607 clockController.clock in <lambda>()
613 clockController.clock in <lambda>()
630 private suspend fun updateClockAppearance(clock: ClockController) { in <lambda>()
632 clockController.clock = clock in <lambda>()
647 clock.events.onSeedColorChanged( in <lambda>()
654 clockController.clock = clock in <lambda>()
662 val clock = clockRegistry.createCurrentClock() in <lambda>() constant
663 clockController.clock = clock in <lambda>()
[all …]
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/flags/
DRestartDozeListenerTest.kt47 val clock = FakeSystemClock() constant
48 val executor = FakeExecutor(clock)
55 RestartDozeListener(settings, statusBarStateController, powerManager, clock, executor) in setup()
84 .wakeUp(eq(clock.uptimeMillis()), eq(PowerManager.WAKE_REASON_APPLICATION), anyString()) in testRestoreDozeState_dozingShouldStart()
85 verify(powerManager).goToSleep(clock.uptimeMillis()) in testRestoreDozeState_dozingShouldStart()
/frameworks/rs/perf-test-scripts/
Dset-gpu-freq49 elif fileexists /d/clock/gbus/possible_rates; then
50 frequencies=(`getprop /d/clock/gbus/possible_rates`)
85 setprop /d/clock/override.gbus/state 1
86 setprop /d/clock/override.gbus/rate $freq

123456789