Home
last modified time | relevance | path

Searched refs:mListeners (Results 1 – 25 of 146) sorted by relevance

123456

/frameworks/base/services/tests/uiservicestests/src/com/android/server/notification/
DNotificationListenersTest.java103 NotificationManagerService.NotificationListeners mListeners; field in NotificationListenersTest
116 mListeners = spy(mNm.new NotificationListeners( in setUp()
137 mListeners.readExtraTag(TAG_REQUESTED_LISTENERS, parser); in testReadExtraTag()
145 mListeners = spy(mNm.new NotificationListeners( in loadDefaultsFromConfig_forHeadlessSystemUser_loadUninstalled()
150 mListeners.loadDefaultsFromConfig(); in loadDefaultsFromConfig_forHeadlessSystemUser_loadUninstalled()
152 assertThat(mListeners.getDefaultComponents()).contains(mUninstalledComponent); in loadDefaultsFromConfig_forHeadlessSystemUser_loadUninstalled()
159 mListeners = spy(mNm.new NotificationListeners( in loadDefaultsFromConfig_forNonHeadlessSystemUser_ignoreUninstalled()
164 mListeners.loadDefaultsFromConfig(); in loadDefaultsFromConfig_forNonHeadlessSystemUser_ignoreUninstalled()
166 assertThat(mListeners.getDefaultComponents()).doesNotContain(mUninstalledComponent); in loadDefaultsFromConfig_forNonHeadlessSystemUser_ignoreUninstalled()
176 doReturn(components).when(mListeners).queryPackageForServices( in mockDefaultListenerConfigForUninstalledComponent()
[all …]
/frameworks/base/services/core/java/com/android/server/wm/
DPointerEventDispatcher.java31 private final ArrayList<PointerEventListener> mListeners = new ArrayList<>(); field in PointerEventDispatcher
45 synchronized (mListeners) { in onInputEvent()
47 mListenersArray = new PointerEventListener[mListeners.size()]; in onInputEvent()
48 mListeners.toArray(mListenersArray); in onInputEvent()
66 synchronized (mListeners) { in registerInputEventListener()
67 if (mListeners.contains(listener)) { in registerInputEventListener()
71 mListeners.add(listener); in registerInputEventListener()
81 synchronized (mListeners) { in unregisterInputEventListener()
82 if (!mListeners.contains(listener)) { in unregisterInputEventListener()
86 mListeners.remove(listener); in unregisterInputEventListener()
[all …]
/frameworks/base/core/java/com/android/internal/widget/
DMediaNotificationView.java35 private ArrayList<VisibilityChangeListener> mListeners; field in MediaNotificationView
62 if (mListeners != null) { in onVisibilityAggregated()
63 for (int i = 0; i < mListeners.size(); i++) { in onVisibilityAggregated()
64 mListeners.get(i).onAggregatedVisibilityChanged(isVisible); in onVisibilityAggregated()
75 if (mListeners == null) { in addVisibilityListener()
76 mListeners = new ArrayList<>(); in addVisibilityListener()
78 if (!mListeners.contains(listener)) { in addVisibilityListener()
79 mListeners.add(listener); in addVisibilityListener()
89 if (mListeners != null) { in removeVisibilityListener()
90 mListeners.remove(listener); in removeVisibilityListener()
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/
DReduceBrightColorsController.java51 private final ArrayList<ReduceBrightColorsController.Listener> mListeners = new ArrayList<>(); field in ReduceBrightColorsController
67 synchronized (mListeners) { in ReduceBrightColorsController()
68 if (setting != null && mListeners.size() != 0) { in ReduceBrightColorsController()
70 for (Listener listener : mListeners) { in ReduceBrightColorsController()
82 synchronized (mListeners) { in ReduceBrightColorsController()
83 if (mListeners.size() > 0) { in ReduceBrightColorsController()
97 synchronized (mListeners) { in addCallback()
98 if (!mListeners.contains(listener)) { in addCallback()
99 mListeners.add(listener); in addCallback()
100 if (mListeners.size() == 1) { in addCallback()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/policy/
DDataSaverControllerImpl.java31 private final ArrayList<Listener> mListeners = new ArrayList<>(); field in DataSaverControllerImpl
39 synchronized (mListeners) { in handleRestrictBackgroundChanged()
40 for (int i = 0; i < mListeners.size(); i++) { in handleRestrictBackgroundChanged()
41 mListeners.get(i).onDataSaverChanged(isDataSaving); in handleRestrictBackgroundChanged()
48 synchronized (mListeners) { in addCallback()
49 mListeners.add(listener); in addCallback()
50 if (mListeners.size() == 1) { in addCallback()
59 synchronized (mListeners) { in removeCallback()
60 mListeners.remove(listener); in removeCallback()
61 if (mListeners.size() == 0) { in removeCallback()
DSafetyController.java47 private final ArrayList<Listener> mListeners = new ArrayList<>(); field in SafetyController
78 synchronized (mListeners) { in addCallback()
79 mListeners.add(listener); in addCallback()
80 if (mListeners.size() == 1) { in addCallback()
94 synchronized (mListeners) { in removeCallback()
95 mListeners.remove(listener); in removeCallback()
96 if (mListeners.isEmpty()) { in removeCallback()
103 synchronized (mListeners) { in handleSafetyCenterEnableChange()
104 for (int i = 0; i < mListeners.size(); i++) { in handleSafetyCenterEnableChange()
105 mListeners.get(i).onSafetyCenterEnableChanged(mSafetyCenterEnabled); in handleSafetyCenterEnableChange()
/frameworks/base/services/core/java/com/android/server/location/injector/
DDeviceIdleHelper.java36 private final CopyOnWriteArrayList<DeviceIdleListener> mListeners; field in DeviceIdleHelper
39 mListeners = new CopyOnWriteArrayList<>(); in DeviceIdleHelper()
46 if (mListeners.add(listener) && mListeners.size() == 1) { in addListener()
55 if (mListeners.remove(listener) && mListeners.isEmpty()) { in removeListener()
63 for (DeviceIdleListener listener : mListeners) { in notifyDeviceIdleChanged()
DScreenInteractiveHelper.java41 private final CopyOnWriteArrayList<ScreenInteractiveChangedListener> mListeners; field in ScreenInteractiveHelper
44 mListeners = new CopyOnWriteArrayList<>(); in ScreenInteractiveHelper()
52 mListeners.add(listener); in addListener()
59 mListeners.remove(listener); in removeListener()
67 for (ScreenInteractiveChangedListener listener : mListeners) { in notifyScreenInteractiveChanged()
DAppForegroundHelper.java49 private final CopyOnWriteArrayList<AppForegroundListener> mListeners; field in AppForegroundHelper
52 mListeners = new CopyOnWriteArrayList<>(); in AppForegroundHelper()
59 mListeners.add(listener); in addListener()
66 mListeners.remove(listener); in removeListener()
70 for (AppForegroundListener listener : mListeners) { in notifyAppForeground()
DUserInfoHelper.java61 private final CopyOnWriteArrayList<UserListener> mListeners; field in UserInfoHelper
64 mListeners = new CopyOnWriteArrayList<>(); in UserInfoHelper()
71 mListeners.add(listener); in addListener()
78 mListeners.remove(listener); in removeListener()
86 for (UserListener listener : mListeners) { in dispatchOnUserStarted()
96 for (UserListener listener : mListeners) { in dispatchOnUserStopped()
111 for (UserListener listener : mListeners) { in dispatchOnCurrentUserChanged()
117 for (UserListener listener : mListeners) { in dispatchOnCurrentUserChanged()
DAppOpsHelper.java39 private final CopyOnWriteArrayList<LocationAppOpListener> mListeners; field in AppOpsHelper
42 mListeners = new CopyOnWriteArrayList<>(); in AppOpsHelper()
46 for (LocationAppOpListener listener : mListeners) { in notifyAppOpChanged()
55 mListeners.add(listener); in addListener()
62 mListeners.remove(listener); in removeListener()
DLocationPermissionsHelper.java51 private final CopyOnWriteArrayList<LocationPermissionsListener> mListeners; field in LocationPermissionsHelper
55 mListeners = new CopyOnWriteArrayList<>(); in LocationPermissionsHelper()
62 for (LocationPermissionsListener listener : mListeners) { in notifyLocationPermissionsChanged()
68 for (LocationPermissionsListener listener : mListeners) { in notifyLocationPermissionsChanged()
81 mListeners.add(listener); in addListener()
88 mListeners.remove(listener); in removeListener()
/frameworks/base/core/java/com/android/internal/util/
DProgressReporter.java60 private final RemoteCallbackList<IProgressListener> mListeners = new RemoteCallbackList<>(); field in ProgressReporter
91 mListeners.register(listener); in addListener()
204 mListeners.kill(); in finish()
209 for (int i = mListeners.beginBroadcast() - 1; i >= 0; i--) { in notifyStarted()
211 mListeners.getBroadcastItem(i).onStarted(id, extras); in notifyStarted()
215 mListeners.finishBroadcast(); in notifyStarted()
219 for (int i = mListeners.beginBroadcast() - 1; i >= 0; i--) { in notifyProgress()
221 mListeners.getBroadcastItem(i).onProgress(id, progress, extras); in notifyProgress()
225 mListeners.finishBroadcast(); in notifyProgress()
229 for (int i = mListeners.beginBroadcast() - 1; i >= 0; i--) { in notifyFinished()
[all …]
/frameworks/base/core/java/android/animation/
DAnimator.java42 ArrayList<AnimatorListener> mListeners = null; field in Animator
309 if (mListeners == null) { in addListener()
310 mListeners = new ArrayList<AnimatorListener>(); in addListener()
312 mListeners.add(listener); in addListener()
322 if (mListeners == null) { in removeListener()
325 mListeners.remove(listener); in removeListener()
326 if (mListeners.size() == 0) { in removeListener()
327 mListeners = null; in removeListener()
338 return mListeners; in getListeners()
376 if (mListeners != null) { in removeAllListeners()
[all …]
/frameworks/base/services/core/java/com/android/server/soundtrigger_middleware/
DExternalCaptureStateTracker.java37 private final List<Listener> mListeners = new LinkedList<>(); field in ExternalCaptureStateTracker
55 synchronized (mListeners) { in registerListener()
56 mListeners.add(listener); in registerListener()
63 synchronized (mListeners) { in unregisterListener()
64 mListeners.remove(listener); in unregisterListener()
90 synchronized (mListeners) { in setCaptureState()
92 for (Listener listener : mListeners) { in setCaptureState()
/frameworks/base/services/tests/mockingservicestests/src/com/android/server/location/injector/
DFakeDeviceStationaryHelper.java25 private final CopyOnWriteArrayList<DeviceIdleInternal.StationaryListener> mListeners = field in FakeDeviceStationaryHelper
32 synchronized (mListeners) { in addListener()
33 mListeners.add(listener); in addListener()
40 mListeners.remove(listener); in removeListener()
44 synchronized (mListeners) { in setStationary()
48 for (DeviceIdleInternal.StationaryListener listener : mListeners) { in setStationary()
/frameworks/base/tests/OneMedia/src/com/android/onemedia/playback/
DRenderer.java73 protected List<Listener> mListeners = new ArrayList<Listener>(); field in Renderer
150 if (!mListeners.contains(listener)) { in registerListener()
151 mListeners.add(listener); in registerListener()
156 mListeners.remove(listener); in unregisterListener()
164 for (Listener listener : mListeners) { in pushOnError()
170 for (Listener listener : mListeners) { in pushOnStateChanged()
176 for (Listener listener : mListeners) { in pushOnBufferingUpdate()
182 for (Listener listener : mListeners) { in pushOnFocusLost()
188 for (Listener listener : mListeners) { in pushOnNextStarted()
/frameworks/base/packages/SystemUI/src/com/android/systemui/accessibility/
DSecureSettingsContentObserver.java55 final List<T> mListeners = new ArrayList<>(); field in SecureSettingsContentObserver
78 if (!mListeners.contains(listener)) { in addListener()
79 mListeners.add(listener); in addListener()
82 if (mListeners.size() == 1) { in addListener()
97 mListeners.remove(listener); in removeListener()
99 if (mListeners.isEmpty()) { in removeListener()
115 final int listenerSize = mListeners.size(); in updateValueChanged()
117 onValueChanged(mListeners.get(i), value); in updateValueChanged()
/frameworks/base/location/java/android/location/
DCountryDetector.java84 private final HashMap<CountryListener, ListenerTransport> mListeners; field in CountryDetector
95 mListeners = new HashMap<CountryListener, ListenerTransport>(); in CountryDetector()
125 synchronized (mListeners) { in addCountryListener()
126 if (!mListeners.containsKey(listener)) { in addCountryListener()
130 mListeners.put(listener, transport); in addCountryListener()
143 synchronized (mListeners) { in removeCountryListener()
144 ListenerTransport transport = mListeners.get(listener); in removeCountryListener()
147 mListeners.remove(listener); in removeCountryListener()
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/
DStatusBarStateControllerImpl.java102 private final ArrayList<RankedListener> mListeners = new ArrayList<>(); field in StatusBarStateControllerImpl
212 synchronized (mListeners) { in setState()
215 for (RankedListener rl : new ArrayList<>(mListeners)) { in setState()
223 for (RankedListener rl : new ArrayList<>(mListeners)) { in setState()
227 for (RankedListener rl : new ArrayList<>(mListeners)) { in setState()
246 for (RankedListener rl : new ArrayList<>(mListeners)) { in updateUpcomingState()
290 synchronized (mListeners) { in setIsDozing()
293 for (RankedListener rl : new ArrayList<>(mListeners)) { in setIsDozing()
313 synchronized (mListeners) { in setIsDreaming()
316 for (RankedListener rl : new ArrayList<>(mListeners)) { in setIsDreaming()
[all …]
/frameworks/base/telephony/java/android/telephony/
DBinderCacheManager.java60 private final HashMap<Object, Runnable> mListeners = new HashMap<>(); field in BinderCacheManager.BinderDeathTracker
76 synchronized (mListeners) { in addListener()
78 mListeners.put(key, r); in addListener()
84 synchronized (mListeners) { in removeListener()
85 mListeners.remove(runnableKey); in removeListener()
92 synchronized (mListeners) { in binderDied()
93 listeners = new ArrayList<>(mListeners.values()); in binderDied()
94 mListeners.clear(); in binderDied()
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/
DNotifInflationErrorManager.java40 List<NotifInflationErrorListener> mListeners = new ArrayList<>(); field in NotifInflationErrorManager
52 for (int i = 0; i < mListeners.size(); i++) { in setInflationError()
53 mListeners.get(i).onNotifInflationError(entry, e); in setInflationError()
63 for (int i = 0; i < mListeners.size(); i++) { in clearInflationError()
64 mListeners.get(i).onNotifInflationErrorCleared(entry); in clearInflationError()
80 mListeners.add(listener); in addInflationErrorListener()
/frameworks/base/services/core/java/com/android/server/twilight/
DTwilightService.java61 private final ArrayMap<TwilightListener, Handler> mListeners = new ArrayMap<>(); field in TwilightService
88 synchronized (mListeners) { in onStart()
89 final boolean wasEmpty = mListeners.isEmpty(); in onStart()
90 mListeners.put(listener, handler); in onStart()
92 if (wasEmpty && !mListeners.isEmpty()) { in onStart()
100 synchronized (mListeners) { in onStart()
101 final boolean wasEmpty = mListeners.isEmpty(); in onStart()
102 mListeners.remove(listener); in onStart()
104 if (!wasEmpty && mListeners.isEmpty()) { in onStart()
112 synchronized (mListeners) { in onStart()
[all …]
/frameworks/opt/telephony/src/java/com/android/internal/telephony/
DConnection.java247 public Set<Listener> mListeners = new CopyOnWriteArraySet<>(); field in Connection
906 mListeners = c.mListeners; in migrateFrom()
929 mListeners.add(listener); in addListener()
938 mListeners.remove(listener); in removeListener()
1053 for (Listener l : mListeners) { in setVideoState()
1068 for (Listener l : mListeners) { in setConnectionCapabilities()
1085 for (Listener l : mListeners) { in setCallRadioTech()
1106 for (Listener l : mListeners) { in setAudioQuality()
1115 for (Listener l: mListeners) { in notifyMediaAttributesChanged()
1143 for (Listener l : mListeners) { in setConnectionExtras()
[all …]
/frameworks/base/core/java/android/view/accessibility/
DCaptioningManager.java58 private final ArrayList<CaptioningChangeListener> mListeners = new ArrayList<>(); field in CaptioningManager
213 synchronized (mListeners) { in addCaptioningChangeListener()
214 if (mListeners.isEmpty()) { in addCaptioningChangeListener()
229 mListeners.add(listener); in addCaptioningChangeListener()
244 synchronized (mListeners) { in removeCaptioningChangeListener()
245 mListeners.remove(listener); in removeCaptioningChangeListener()
247 if (mListeners.isEmpty()) { in removeCaptioningChangeListener()
268 synchronized (mListeners) { in notifyEnabledChanged()
269 for (CaptioningChangeListener listener : mListeners) { in notifyEnabledChanged()
277 synchronized (mListeners) { in notifyUserStyleChanged()
[all …]

123456