Home
last modified time | relevance | path

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

12345

/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/packages/SystemUI/shared/src/com/android/systemui/shared/system/
DPinnedStackListenerForwarder.java35 private List<PinnedStackListener> mListeners = new ArrayList<>(); field in PinnedStackListenerForwarder
39 mListeners.add(listener); in addListener()
44 mListeners.remove(listener); in removeListener()
49 for (PinnedStackListener listener : mListeners) { in onListenerRegistered()
56 for (PinnedStackListener listener : mListeners) { in onMovementBoundsChanged()
63 for (PinnedStackListener listener : mListeners) { in onImeVisibilityChanged()
70 for (PinnedStackListener listener : mListeners) { in onActionsChanged()
77 for (PinnedStackListener listener : mListeners) { in onActivityHidden()
84 for (PinnedStackListener listener : mListeners) { in onDisplayInfoChanged()
91 for (PinnedStackListener listener : mListeners) { in onConfigurationChanged()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/policy/
DDataSaverControllerImpl.java29 private final ArrayList<Listener> mListeners = new ArrayList<>(); field in DataSaverControllerImpl
37 synchronized (mListeners) { in handleRestrictBackgroundChanged()
38 for (int i = 0; i < mListeners.size(); i++) { in handleRestrictBackgroundChanged()
39 mListeners.get(i).onDataSaverChanged(isDataSaving); in handleRestrictBackgroundChanged()
45 synchronized (mListeners) { in addCallback()
46 mListeners.add(listener); in addCallback()
47 if (mListeners.size() == 1) { in addCallback()
55 synchronized (mListeners) { in removeCallback()
56 mListeners.remove(listener); in removeCallback()
57 if (mListeners.size() == 0) { in removeCallback()
DDeviceProvisionedControllerImpl.java43 protected final ArrayList<DeviceProvisionedListener> mListeners = new ArrayList<>(); field in DeviceProvisionedControllerImpl
91 mListeners.add(listener); in addCallback()
92 if (mListeners.size() == 1) { in addCallback()
101 mListeners.remove(listener); in removeCallback()
102 if (mListeners.size() == 0) { in removeCallback()
131 for (int i = mListeners.size() - 1; i >= 0; --i) { in notifyUserChanged()
132 mListeners.get(i).onUserSwitched(); in notifyUserChanged()
137 for (int i = mListeners.size() - 1; i >= 0; --i) { in notifySetupChanged()
138 mListeners.get(i).onUserSetupChanged(); in notifySetupChanged()
143 for (int i = mListeners.size() - 1; i >= 0; --i) { in notifyProvisionedChanged()
[all …]
DSensorPrivacyControllerImpl.java35 private final List<OnSensorPrivacyChangedListener> mListeners; field in SensorPrivacyControllerImpl
48 mListeners = new ArrayList<>(1); in SensorPrivacyControllerImpl()
65 mListeners.add(listener); in addCallback()
75 mListeners.remove(listener); in removeCallback()
85 for (OnSensorPrivacyChangedListener listener : mListeners) { in onSensorPrivacyChanged()
DFlashlightControllerImpl.java63 private final ArrayList<WeakReference<FlashlightListener>> mListeners = new ArrayList<>(1); field in FlashlightControllerImpl
127 synchronized (mListeners) { in addCallback()
132 mListeners.add(new WeakReference<>(l)); in addCallback()
139 synchronized (mListeners) { in removeCallback()
179 synchronized (mListeners) { in dispatchListeners()
180 final int N = mListeners.size(); in dispatchListeners()
183 FlashlightListener l = mListeners.get(i).get(); in dispatchListeners()
203 for (int i = mListeners.size() - 1; i >= 0; i--) { in cleanUpListenersLocked()
204 FlashlightListener found = mListeners.get(i).get(); in cleanUpListenersLocked()
206 mListeners.remove(i); in cleanUpListenersLocked()
/frameworks/base/core/java/android/animation/
DAnimator.java39 ArrayList<AnimatorListener> mListeners = null; field in Animator
263 if (mListeners == null) { in addListener()
264 mListeners = new ArrayList<AnimatorListener>(); in addListener()
266 mListeners.add(listener); in addListener()
276 if (mListeners == null) { in removeListener()
279 mListeners.remove(listener); in removeListener()
280 if (mListeners.size() == 0) { in removeListener()
281 mListeners = null; in removeListener()
292 return mListeners; in getListeners()
330 if (mListeners != null) { in removeAllListeners()
[all …]
/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/packages/SystemUI/src/com/android/systemui/statusbar/
DStatusBarStateControllerImpl.java72 private final ArrayList<RankedListener> mListeners = new ArrayList<>(); field in StatusBarStateControllerImpl
153 synchronized (mListeners) { in setState()
156 for (RankedListener rl : new ArrayList<>(mListeners)) { in setState()
162 for (RankedListener rl : new ArrayList<>(mListeners)) { in setState()
166 for (RankedListener rl : new ArrayList<>(mListeners)) { in setState()
203 synchronized (mListeners) { in setIsDozing()
206 for (RankedListener rl : new ArrayList<>(mListeners)) { in setIsDozing()
248 synchronized (mListeners) { in setDozeAmountInternal()
251 for (RankedListener rl : new ArrayList<>(mListeners)) { in setDozeAmountInternal()
280 synchronized (mListeners) { in addCallback()
[all …]
/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/location/java/android/location/
DAbstractListenerManager.java93 private volatile ArrayMap<Object, Registration<TRequest, TListener>> mListeners = field in AbstractListenerManager
137 boolean initialRequest = mListeners.isEmpty(); in addInternal()
140 mListeners.size() + 1); in addInternal()
141 newListeners.putAll(mListeners); in addInternal()
144 mListeners = newListeners; in addInternal()
166 mListeners); in removeListener()
168 mListeners = newListeners; in removeListener()
175 boolean lastRequest = mListeners.isEmpty(); in removeListener()
207 for (Registration<TRequest, TListener> registration : mListeners.values()) { in execute()
218 if (mListeners.isEmpty()) { in mergeRequests()
[all …]
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/core/java/android/hardware/
DSensorPrivacyManager.java67 private final ArrayMap<OnSensorPrivacyChangedListener, ISensorPrivacyListener> mListeners; field in SensorPrivacyManager
75 mListeners = new ArrayMap<>(); in SensorPrivacyManager()
118 synchronized (mListeners) { in addSensorPrivacyListener()
119 ISensorPrivacyListener iListener = mListeners.get(listener); in addSensorPrivacyListener()
127 mListeners.put(listener, iListener); in addSensorPrivacyListener()
146 synchronized (mListeners) { in removeSensorPrivacyListener()
147 ISensorPrivacyListener iListener = mListeners.get(listener); in removeSensorPrivacyListener()
149 mListeners.remove(iListener); in removeSensorPrivacyListener()
/frameworks/base/services/core/java/com/android/server/twilight/
DTwilightService.java60 private final ArrayMap<TwilightListener, Handler> mListeners = new ArrayMap<>(); field in TwilightService
87 synchronized (mListeners) { in onStart()
88 final boolean wasEmpty = mListeners.isEmpty(); in onStart()
89 mListeners.put(listener, handler); in onStart()
91 if (wasEmpty && !mListeners.isEmpty()) { in onStart()
99 synchronized (mListeners) { in onStart()
100 final boolean wasEmpty = mListeners.isEmpty(); in onStart()
101 mListeners.remove(listener); in onStart()
103 if (!wasEmpty && mListeners.isEmpty()) { in onStart()
111 synchronized (mListeners) { in onStart()
[all …]
/frameworks/base/native/android/
Dthermal.cpp59 std::vector<ListenerCallback> mListeners; member
89 mListeners.clear(); in ~AThermalManager()
101 for (auto listener : mListeners) { in notifyStateChange()
114 for (const auto& cb : mListeners) { in addListener()
120 mListeners.emplace_back(ListenerCallback{callback, data}); in addListener()
144 auto it = std::remove_if(mListeners.begin(), in removeListener()
145 mListeners.end(), in removeListener()
150 if (it == mListeners.end()) { in removeListener()
154 mListeners.erase(it, mListeners.end()); in removeListener()
156 if (!mListeners.empty()) { in removeListener()
/frameworks/opt/telephony/src/java/com/android/internal/telephony/
DConnection.java218 public Set<Listener> mListeners = new CopyOnWriteArraySet<>(); field in Connection
848 mListeners = c.mListeners; in migrateFrom()
871 mListeners.add(listener); in addListener()
880 mListeners.remove(listener); in removeListener()
995 for (Listener l : mListeners) { in setVideoState()
1010 for (Listener l : mListeners) { in setConnectionCapabilities()
1027 for (Listener l : mListeners) { in setCallRadioTech()
1048 for (Listener l : mListeners) { in setAudioQuality()
1076 for (Listener l : mListeners) { in setConnectionExtras()
1163 for (Listener l : mListeners) { in setCallSubstate()
[all …]
/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/tests/wmtests/src/com/android/server/wm/utils/
DFakeDeviceConfigInterface.java36 private ArrayMap<DeviceConfig.OnPropertiesChangedListener, Pair<String, Executor>> mListeners = field in FakeDeviceConfigInterface
50 CountDownLatch latch = new CountDownLatch(mListeners.size()); in putPropertyAndNotify()
51 for (int i = 0; i < mListeners.size(); i++) { in putPropertyAndNotify()
52 if (namespace.equals(mListeners.valueAt(i).first)) { in putPropertyAndNotify()
54 mListeners.valueAt(i).second.execute( in putPropertyAndNotify()
56 mListeners.keyAt(j).onPropertiesChanged(properties); in putPropertyAndNotify()
133 Pair<String, Executor> oldNamespace = mListeners.get(listener); in addOnPropertiesChangedListener()
136 mListeners.put(listener, new Pair<>(namespace, executor)); in addOnPropertiesChangedListener()
139 mListeners.put(listener, new Pair<>(namespace, executor)); in addOnPropertiesChangedListener()
153 mListeners.remove(listener); in removeOnPropertiesChangedListener()
/frameworks/base/packages/PrintRecommendationService/src/com/android/printservice/recommendation/util/
DDiscoveryListenerMultiplexer.java121 private final @NonNull ArrayList<NsdManager.DiscoveryListener> mListeners; field in DiscoveryListenerMultiplexer.MultiListener
129 mListeners = listeners; in MultiListener()
156 synchronized (mListeners) { in onServiceFound()
157 int numListeners = mListeners.size(); in onServiceFound()
159 NsdManager.DiscoveryListener listener = mListeners.get(i); in onServiceFound()
168 synchronized (mListeners) { in onServiceLost()
169 int numListeners = mListeners.size(); in onServiceLost()
171 NsdManager.DiscoveryListener listener = mListeners.get(i); in onServiceLost()
/frameworks/base/telecomm/java/android/telecom/
DConference.java81 private final Set<Listener> mListeners = new CopyOnWriteArraySet<>(); field in Conference
406 for (Listener l : mListeners) { in setDisconnected()
428 for (Listener l : mListeners) { in setConnectionCapabilities()
444 for (Listener l : mListeners) { in setConnectionProperties()
462 for (Listener l : mListeners) { in addConnection()
480 for (Listener l : mListeners) { in removeConnection()
514 for (Listener l : mListeners) { in setRingbackRequested()
532 for (Listener l : mListeners) { in setVideoState()
545 for (Listener l : mListeners) { in setVideoProvider()
551 for (Listener l : mListeners) { in fireOnConferenceableConnectionsChanged()
[all …]
/frameworks/base/core/java/android/view/accessibility/
DCaptioningManager.java51 private final ArrayList<CaptioningChangeListener> mListeners = new ArrayList<>(); field in CaptioningManager
146 synchronized (mListeners) { in addCaptioningChangeListener()
147 if (mListeners.isEmpty()) { in addCaptioningChangeListener()
160 mListeners.add(listener); in addCaptioningChangeListener()
175 synchronized (mListeners) { in removeCaptioningChangeListener()
176 mListeners.remove(listener); in removeCaptioningChangeListener()
178 if (mListeners.isEmpty()) { in removeCaptioningChangeListener()
186 synchronized (mListeners) { in notifyEnabledChanged()
187 for (CaptioningChangeListener listener : mListeners) { in notifyEnabledChanged()
195 synchronized (mListeners) { in notifyUserStyleChanged()
[all …]
/frameworks/base/core/java/com/android/internal/widget/
DMediaNotificationView.java47 private ArrayList<VisibilityChangeListener> mListeners; field in MediaNotificationView
178 if (mListeners != null) { in onVisibilityAggregated()
179 for (int i = 0; i < mListeners.size(); i++) { in onVisibilityAggregated()
180 mListeners.get(i).onAggregatedVisibilityChanged(isVisible); in onVisibilityAggregated()
191 if (mListeners == null) { in addVisibilityListener()
192 mListeners = new ArrayList<>(); in addVisibilityListener()
194 if (!mListeners.contains(listener)) { in addVisibilityListener()
195 mListeners.add(listener); in addVisibilityListener()
205 if (mListeners != null) { in removeVisibilityListener()
206 mListeners.remove(listener); in removeVisibilityListener()
/frameworks/base/packages/SystemUI/src/com/android/systemui/screenrecord/
DRecordingController.java55 private ArrayList<RecordingStateChangeCallback> mListeners = new ArrayList<>(); field in RecordingController
102 for (RecordingStateChangeCallback cb : mListeners) { in startCountdown()
111 for (RecordingStateChangeCallback cb : mListeners) { in startCountdown()
140 for (RecordingStateChangeCallback cb : mListeners) { in cancelCountdown()
184 for (RecordingStateChangeCallback cb : mListeners) { in updateState()
195 mListeners.add(listener); in addCallback()
200 mListeners.remove(listener); in removeCallback()
/frameworks/base/services/core/java/com/android/server/location/
DUserInfoHelper.java75 private final CopyOnWriteArrayList<UserListener> mListeners; field in UserInfoHelper
84 mListeners = new CopyOnWriteArrayList<>(); in UserInfoHelper()
103 mListeners.add(listener); in addListener()
110 mListeners.remove(listener); in removeListener()
118 for (UserListener listener : mListeners) { in dispatchOnUserStarted()
128 for (UserListener listener : mListeners) { in dispatchOnUserStopped()
142 for (UserListener listener : mListeners) { in dispatchOnCurrentUserChanged()
148 for (UserListener listener : mListeners) { in dispatchOnCurrentUserChanged()
DAppForegroundHelper.java60 private final CopyOnWriteArrayList<AppForegroundListener> mListeners; field in AppForegroundHelper
67 mListeners = new CopyOnWriteArrayList<>(); in AppForegroundHelper()
85 mListeners.add(listener); in addListener()
92 mListeners.remove(listener); in removeListener()
99 for (AppForegroundListener listener : mListeners) { in onAppForegroundChanged()

12345