Home
last modified time | relevance | path

Searched refs:mWakeLock (Results 1 – 25 of 27) sorted by relevance

12

/packages/services/Telecomm/src/com/android/server/telecom/
DTelecomWakeLock.java30 private PowerManager.WakeLock mWakeLock; field in TelecomWakeLock.WakeLockAdapter
33 mWakeLock = wakeLock; in WakeLockAdapter()
37 mWakeLock.acquire(); in acquire()
41 return mWakeLock.isHeld(); in isHeld()
45 mWakeLock.release(flags); in release()
49 mWakeLock.setReferenceCounted(isReferencedCounted); in setReferenceCounted()
59 private WakeLockAdapter mWakeLock; field in TelecomWakeLock
65 mWakeLock = getWakeLockFromPowerManager(); in TelecomWakeLock()
74 mWakeLock = wakeLockAdapter; in TelecomWakeLock()
88 return mWakeLock != null && mWakeLock.isHeld(); in isHeld()
[all …]
/packages/apps/Messaging/src/com/android/messaging/util/
DWakeLockHelper.java41 private PowerManager.WakeLock mWakeLock; field in WakeLockHelper
53 if (mWakeLock == null) { in acquire()
59 mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, mWakeLockId); in acquire()
65 mWakeLock.acquire(); in acquire()
74 return (respectWakeLock && mWakeLock.isHeld()); in isHeld()
92 + " opcode: " + opcode + " sWakeLock: " + mWakeLock + " isHeld: " in ensure()
93 + ((mWakeLock == null) ? "(null)" : mWakeLock.isHeld())); in ensure()
110 mWakeLock.release(); in release()
113 + intent.getAction() + " opcode: " + opcode + " sWakeLock: " + mWakeLock in release()
114 + " isHeld: " + ((mWakeLock == null) ? "(null)" : mWakeLock.isHeld())); in release()
DNotificationPlayer.java243 private PowerManager.WakeLock mWakeLock; field in NotificationPlayer
340 if (mWakeLock != null || mThread != null) { in setUsesWakeLock()
343 throw new RuntimeException("assertion failed mWakeLock=" + mWakeLock in setUsesWakeLock()
348 mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, mTag); in setUsesWakeLock()
352 if (mWakeLock != null) { in acquireWakeLock()
353 mWakeLock.acquire(); in acquireWakeLock()
358 if (mWakeLock != null) { in releaseWakeLock()
359 mWakeLock.release(); in releaseWakeLock()
/packages/modules/CellBroadcastService/src/com/android/cellbroadcastservice/
DWakeLockStateMachine.java49 private final PowerManager.WakeLock mWakeLock; field in WakeLockStateMachine
80 mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, debugTag); in WakeLockStateMachine()
82 mWakeLock.acquire(); in WakeLockStateMachine()
91 if (mWakeLock.isHeld()) { in releaseWakeLock()
92 mWakeLock.release(); in releaseWakeLock()
95 if (mWakeLock.isHeld()) { in releaseWakeLock()
110 while (mWakeLock.isHeld()) { in onQuitting()
111 mWakeLock.release(); in onQuitting()
157 mWakeLock.acquire(); in exit()
/packages/providers/CalendarProvider/src/com/android/providers/calendar/
DCalendarReceiver.java45 private PowerManager.WakeLock mWakeLock; field in CalendarReceiver
59 if (mWakeLock == null) { in onReceive()
61 mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "CalendarReceiver_Provider"); in onReceive()
62 mWakeLock.setReferenceCounted(true); in onReceive()
64 mWakeLock.acquire(); in onReceive()
73 mWakeLock.release(); in onReceive()
/packages/modules/IPsec/src/java/com/android/internal/net/ipsec/ike/
DIkeLocalRequestScheduler.java152 private WakeLock mWakeLock; field in IkeLocalRequestScheduler.LocalRequest
181 if (mWakeLock != null && mWakeLock.isHeld()) { in acquireWakeLock()
186 mWakeLock = in acquireWakeLock()
190 mWakeLock.setReferenceCounted(false); in acquireWakeLock()
191 mWakeLock.acquire(); in acquireWakeLock()
196 if (mWakeLock != null) { in releaseWakeLock()
197 mWakeLock.release(); in releaseWakeLock()
198 mWakeLock = null; in releaseWakeLock()
/packages/apps/Contacts/tests/src/com/android/contacts/test/
DIntegrationTestUtils.java47 @GuardedBy("mLock") private PowerManager.WakeLock mWakeLock; field in IntegrationTestUtils
108 Preconditions.checkState(mWakeLock == null, "mWakeLock was already held");
109 mWakeLock = ((PowerManager) context.getSystemService(Context.POWER_SERVICE))
112 mWakeLock.acquire();
126 if (mWakeLock != null) {
127 mWakeLock.release();
128 mWakeLock = null;
/packages/modules/Bluetooth/android/app/src/com/android/bluetooth/sap/
DSapService.java84 private PowerManager.WakeLock mWakeLock = null; field in SapService
260 if (mWakeLock != null) { in closeService()
263 mWakeLock.release(); in closeService()
264 mWakeLock = null; in closeService()
280 if (mWakeLock == null) { in startSapServerSession()
282 mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "StartingSapTransaction"); in startSapServerSession()
283 mWakeLock.setReferenceCounted(false); in startSapServerSession()
284 mWakeLock.acquire(); in startSapServerSession()
319 if (mWakeLock != null) { in stopSapServerSession()
320 mWakeLock.release(); in stopSapServerSession()
[all …]
/packages/apps/DocumentsUI/src/com/android/documentsui/services/
DFileOperationService.java137 private PowerManager.WakeLock mWakeLock; // the wake lock, if held. field in FileOperationService
237 if (mWakeLock == null) { in handleOperation()
238 mWakeLock = mPowerManager.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, TAG); in handleOperation()
263 mWakeLock.acquire(); in handleOperation()
324 mWakeLock.release(); in deleteJob()
325 if (!mWakeLock.isHeld()) { in deleteJob()
326 mWakeLock = null; in deleteJob()
345 assert(mWakeLock == null); in shutdown()
361 return mWakeLock != null && mWakeLock.isHeld(); in holdsWakeLock()
/packages/apps/Gallery2/src/com/android/gallery3d/ui/
DWakeLockHoldingProgressListener.java28 private PowerManager.WakeLock mWakeLock; field in WakeLockHoldingProgressListener
38 mWakeLock = pm.newWakeLock(PowerManager.SCREEN_DIM_WAKE_LOCK, label); in WakeLockHoldingProgressListener()
43 mWakeLock.release(); in onProgressComplete()
48 mWakeLock.acquire(); in onProgressStart()
/packages/modules/Bluetooth/android/app/src/com/android/bluetooth/pbap/
DBluetoothPbapService.java152 private PowerManager.WakeLock mWakeLock; field in BluetoothPbapService
321 if (mWakeLock != null) { in closeService()
322 mWakeLock.release(); in closeService()
323 mWakeLock = null; in closeService()
473 if (mWakeLock == null) { in handleMessage()
475 mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, in handleMessage()
477 mWakeLock.setReferenceCounted(false); in handleMessage()
478 mWakeLock.acquire(); in handleMessage()
487 if (mWakeLock != null) { in handleMessage()
488 mWakeLock.release(); in handleMessage()
[all …]
/packages/apps/Test/connectivity/PMC/src/com/android/pmc/
DWifiConnScanReceiver.java24 private PowerManager.WakeLock mWakeLock; field in WifiConnScanReceiver
50 mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "WIFITEST"); in onReceive()
52 mWakeLock.acquire(); in onReceive()
118 mWakeLock.release(); in onCancelled()
135 mWakeLock.release(); in onPostExecute()
DWifiGScanReceiver.java27 private PowerManager.WakeLock mWakeLock; field in WifiGScanReceiver
57 mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "WIFITEST"); in onReceive()
59 mWakeLock.acquire(); in onReceive()
124 mWakeLock.release(); in onCancelled()
140 mWakeLock.release(); in onPostExecute()
DPMCMainActivity.java81 private PowerManager.WakeLock mWakeLock; field in PMCMainActivity
340 if (mWakeLock == null) { in turnScreenOn()
342 mWakeLock = pm.newWakeLock( in turnScreenOn()
345 if (mWakeLock != null && !mWakeLock.isHeld()) { in turnScreenOn()
347 mWakeLock.acquire(); in turnScreenOn()
352 if (mWakeLock != null && mWakeLock.isHeld()) { in turnScreenOff()
354 mWakeLock.release(); in turnScreenOff()
DWifiDownloadReceiver.java29 private PowerManager.WakeLock mWakeLock; field in WifiDownloadReceiver
58 mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "WIFITEST"); in onReceive()
60 mWakeLock.acquire(); in onReceive()
141 mWakeLock.release(); in onCancelled()
158 mWakeLock.release(); in onPostExecute()
DIperfClient.java42 private PowerManager.WakeLock mWakeLock; field in IperfClient
84 mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "WIFITEST"); in startClient()
86 mWakeLock.acquire(); in startClient()
109 mWakeLock.release(); in stopClient()
/packages/modules/Bluetooth/android/app/src/com/android/bluetooth/map/
DBluetoothMapService.java116 private PowerManager.WakeLock mWakeLock = null; field in BluetoothMapService
193 if (mWakeLock != null) { in closeService()
194 mWakeLock.release(); in closeService()
198 mWakeLock = null; in closeService()
251 if (mWakeLock == null) { in startObexServerSessions()
253 mWakeLock = in startObexServerSessions()
255 mWakeLock.setReferenceCounted(false); in startObexServerSessions()
256 mWakeLock.acquire(); in startObexServerSessions()
347 if (mWakeLock != null && lastMasInst) { in stopObexServerSessions()
350 mWakeLock.release(); in stopObexServerSessions()
[all …]
/packages/apps/Camera2/src/com/android/camera/processing/
DProcessingService.java90 private WakeLock mWakeLock; field in ProcessingService
109 mWakeLock = powerManager.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, TAG.toString()); in onCreate()
110 mWakeLock.acquire(); in onCreate()
127 if (mWakeLock.isHeld()) { in onDestroy()
128 mWakeLock.release(); in onDestroy()
/packages/apps/Gallery2/src/com/android/gallery3d/ingest/data/
DImportTask.java56 private PowerManager.WakeLock mWakeLock; field in ImportTask
64 mWakeLock = pm.newWakeLock(PowerManager.SCREEN_DIM_WAKE_LOCK, WAKELOCK_LABEL); in ImportTask()
73 mWakeLock.acquire(); in run()
102 mWakeLock.release(); in run()
/packages/apps/Gallery2/src/com/android/gallery3d/app/
DMovieActivity.java66 private PowerManager.WakeLock mWakeLock = null; field in MovieActivity
224 mWakeLock = pm.newWakeLock(PowerManager.SCREEN_BRIGHT_WAKE_LOCK,"Gallery_WAKE_LOCK"); in onStart()
225 mWakeLock.acquire(); in onStart()
235 mWakeLock.release(); in onStop()
/packages/apps/Contacts/src/com/android/contacts/vcard/
DImportVCardActivity.java180 private PowerManager.WakeLock mWakeLock; field in ImportVCardActivity.VCardCacheThread
194 mWakeLock = powerManager.newWakeLock( in VCardCacheThread()
202 if (mWakeLock != null && mWakeLock.isHeld()) { in finalize()
204 mWakeLock.release(); in finalize()
216 mWakeLock.acquire(); in run()
292 mWakeLock.release(); in run()
/packages/modules/Bluetooth/android/app/src/com/android/bluetooth/opp/
DBluetoothOppObexClientSession.java163 private WakeLock mWakeLock; field in BluetoothOppObexClientSession.ClientThread
179 mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, TAG); in ClientThread()
195 mWakeLock.acquire(); in run()
227 if (mWakeLock.isHeld()) { in run()
231 mWakeLock.release(); in run()
/packages/modules/GeoTZ/locationtzprovider/src/main/java/com/android/timezone/location/provider/
DEnvironmentImpl.java140 @NonNull private final PowerManager.WakeLock mWakeLock; field in EnvironmentImpl
151 mWakeLock = powerManager.newWakeLock(PARTIAL_WAKE_LOCK, LOG_TAG + ":wakelock"); in EnvironmentImpl()
471 mWakeLock.acquire(WAKELOCK_ACQUIRE_MILLIS);
476 mWakeLock.release();
/packages/modules/Connectivity/service-t/src/com/android/server/net/
DNetworkStatsService.java292 private final PowerManager.WakeLock mWakeLock; field in NetworkStatsService
586 mWakeLock = Objects.requireNonNull(wakeLock, "missing WakeLock"); in NetworkStatsService()
2024 mWakeLock.acquire();
2028 mWakeLock.release();
2044 mWakeLock.acquire();
2048 mWakeLock.release();
2080 mWakeLock.acquire();
2085 mWakeLock.release();
2326 mWakeLock.acquire();
2331 mWakeLock.release();
/packages/providers/TelephonyProvider/src/com/android/providers/telephony/
DTelephonyBackupAgent.java645 private PowerManager.WakeLock mWakeLock; field in TelephonyBackupAgent.DeferredSmsMmsRestoreService
651 mWakeLock.acquire(); in onHandleIntent()
687 mWakeLock.release(); in onHandleIntent()
710 mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, TAG); in onCreate()

12