Home
last modified time | relevance | path

Searched refs:mDevice (Results 1 – 25 of 99) sorted by relevance

1234

/frameworks/base/services/tests/mockingservicestests/src/com/android/server/power/batterysaver/
DBatterySaverStateMachineTest.java62 private Device mDevice; field in BatterySaverStateMachineTest
117 mDevice.getLowPowerModeTriggerLevel(), in pushGlobalSettings()
152 mDevice.putGlobalSetting(key, value); in putGlobalSetting()
157 return mDevice.getGlobalSetting(key, defValue); in getGlobalSetting()
188 doAnswer((inv) -> mDevice.batterySaverEnabled = inv.getArgument(0)) in setUp()
193 .thenAnswer((inv) -> mDevice.batterySaverEnabled); in setUp()
195 .thenAnswer((inv) -> mDevice.batterySaverEnabled); in setUp()
208 mDevice = new Device(); in initDevice()
214 mDevice.pushBatteryStatus(); in initDevice()
220 assertEquals(0, mDevice.getLowPowerModeTriggerLevel()); in testNoAutoBatterySaver()
[all …]
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/
DCachedBluetoothDevice.java64 BluetoothDevice mDevice; field in CachedBluetoothDevice
102 mDevice = device; in CachedBluetoothDevice()
115 sb.append("Address:").append(mDevice); in describe()
125 Log.d(TAG, "onProfileStateChanged: profile " + profile + ", device=" + mDevice in onProfileStateChanged()
139 profile.setEnabled(mDevice, true); in onProfileStateChanged()
145 && ((PanProfile) profile).isLocalRoleNap(mDevice)) { in onProfileStateChanged()
152 profile.setEnabled(mDevice, false); in onProfileStateChanged()
154 && ((PanProfile) profile).isLocalRoleNap(mDevice) in onProfileStateChanged()
168 mLocalAdapter.disconnectAllEnabledProfiles(mDevice); in disconnect()
176 PbapProfile.setEnabled(mDevice, false); in disconnect()
[all …]
/frameworks/av/media/libaudiohal/impl/
DDeviceHalHidl.cpp91 : ConversionHelperHidl("Device"), mDevice(device), in DeviceHalHidl()
96 if (mDevice != 0) { in ~DeviceHalHidl()
98 mDevice.clear(); in ~DeviceHalHidl()
101 mDevice->close(); in ~DeviceHalHidl()
112 if (mDevice == 0) return NO_INIT; in initCheck()
113 return processReturn("initCheck", mDevice->initCheck()); in initCheck()
117 if (mDevice == 0) return NO_INIT; in setVoiceVolume()
123 if (mDevice == 0) return NO_INIT; in setMasterVolume()
124 return processReturn("setMasterVolume", mDevice->setMasterVolume(volume)); in setMasterVolume()
128 if (mDevice == 0) return NO_INIT; in getMasterVolume()
[all …]
/frameworks/base/packages/SettingsLib/tests/robotests/src/com/android/settingslib/bluetooth/
DA2dpProfileTest.java57 private BluetoothDevice mDevice; field in A2dpProfileTest
72 when(mBluetoothA2dp.getActiveDevice()).thenReturn(mDevice); in setUp()
77 when(mBluetoothA2dp.isOptionalCodecsSupported(mDevice)).thenReturn( in supportsHighQualityAudio()
79 assertThat(mProfile.supportsHighQualityAudio(mDevice)).isTrue(); in supportsHighQualityAudio()
81 when(mBluetoothA2dp.isOptionalCodecsSupported(mDevice)).thenReturn( in supportsHighQualityAudio()
83 assertThat(mProfile.supportsHighQualityAudio(mDevice)).isFalse(); in supportsHighQualityAudio()
85 when(mBluetoothA2dp.isOptionalCodecsSupported(mDevice)).thenReturn( in supportsHighQualityAudio()
87 assertThat(mProfile.supportsHighQualityAudio(mDevice)).isFalse(); in supportsHighQualityAudio()
92 when(mBluetoothA2dp.isOptionalCodecsEnabled(mDevice)).thenReturn( in isHighQualityAudioEnabled()
94 assertThat(mProfile.isHighQualityAudioEnabled(mDevice)).isTrue(); in isHighQualityAudioEnabled()
[all …]
DCachedBluetoothDeviceTest.java65 private BluetoothDevice mDevice; field in CachedBluetoothDeviceTest
78 when(mDevice.getAddress()).thenReturn(DEVICE_ADDRESS); in setUp()
83 mCachedDevice = spy(new CachedBluetoothDevice(mContext, mProfileManager, mDevice)); in setUp()
91 when(mDevice.getBondState()).thenReturn(BluetoothDevice.BOND_BONDING); in getConnectionSummary_testProfilesInactive_returnPairing()
465 when(mDevice.getBondState()).thenReturn(BluetoothDevice.BOND_BONDING); in getConnectionSummary_testMultipleProfilesInactive_returnPairing()
477 when(mDevice.getBondState()).thenReturn(BluetoothDevice.BOND_BONDED); in getConnectionSummary_trueWirelessActiveDeviceWithBattery_returnActiveWithBattery()
479 when(mDevice.getMetadata(BluetoothDevice.METADATA_IS_UNTETHERED_HEADSET)).thenReturn( in getConnectionSummary_trueWirelessActiveDeviceWithBattery_returnActiveWithBattery()
481 when(mDevice.getMetadata(BluetoothDevice.METADATA_UNTETHERED_LEFT_BATTERY)).thenReturn( in getConnectionSummary_trueWirelessActiveDeviceWithBattery_returnActiveWithBattery()
483 when(mDevice.getMetadata(BluetoothDevice.METADATA_UNTETHERED_RIGHT_BATTERY)).thenReturn( in getConnectionSummary_trueWirelessActiveDeviceWithBattery_returnActiveWithBattery()
495 when(mDevice.getBondState()).thenReturn(BluetoothDevice.BOND_BONDED); in getConnectionSummary_trueWirelessDeviceWithBattery_returnActiveWithBattery()
[all …]
/frameworks/base/packages/SettingsLib/tests/robotests/src/com/android/settingslib/media/
DBluetoothMediaDeviceTest.java41 private CachedBluetoothDevice mDevice; field in BluetoothMediaDeviceTest
51 when(mDevice.isActiveDevice(BluetoothProfile.A2DP)).thenReturn(true); in setUp()
52 when(mDevice.isActiveDevice(BluetoothProfile.HEARING_AID)).thenReturn(true); in setUp()
54 mBluetoothMediaDevice = new BluetoothMediaDevice(mContext, mDevice); in setUp()
59 when(mDevice.setActive()).thenReturn(true); in connect_setActiveSuccess_isConnectedReturnTrue()
66 when(mDevice.setActive()).thenReturn(false); in connect_setActiveFail_isConnectedReturnFalse()
73 when(mDevice.getBondState()).thenReturn(BluetoothDevice.BOND_BONDED); in isCachedBluetoothDeviceConnected_deviceConnected_returnTrue()
74 when(mDevice.isConnected()).thenReturn(true); in isCachedBluetoothDeviceConnected_deviceConnected_returnTrue()
81 when(mDevice.getBondState()).thenReturn(BluetoothDevice.BOND_BONDED); in isCachedBluetoothDeviceConnected_deviceNotConnected_returnFalse()
82 when(mDevice.isConnected()).thenReturn(false); in isCachedBluetoothDeviceConnected_deviceNotConnected_returnFalse()
DMediaManagerTest.java43 private MediaDevice mDevice; field in MediaManagerTest
53 when(mDevice.getId()).thenReturn(TEST_ID); in setUp()
72 mMediaManager.dispatchDeviceAdded(mDevice); in dispatchDeviceAdded_registerCallback_shouldDispatchCallback()
74 verify(mCallback).onDeviceAdded(mDevice); in dispatchDeviceAdded_registerCallback_shouldDispatchCallback()
81 mMediaManager.dispatchDeviceRemoved(mDevice); in dispatchDeviceRemoved_registerCallback_shouldDispatchCallback()
83 verify(mCallback).onDeviceRemoved(mDevice); in dispatchDeviceRemoved_registerCallback_shouldDispatchCallback()
124 mMediaManager.mMediaDevices.add(mDevice); in findMediaDevice_idExist_shouldReturnMediaDevice()
128 assertThat(device.getId()).isEqualTo(mDevice.getId()); in findMediaDevice_idExist_shouldReturnMediaDevice()
133 mMediaManager.mMediaDevices.add(mDevice); in findMediaDevice_idNotExist_shouldReturnNull()
/frameworks/base/core/java/android/bluetooth/
DBluetoothGatt.java53 private BluetoothDevice mDevice; field in BluetoothGatt
192 mService.clientConnect(mClientIf, mDevice.getAddress(),
210 if (!address.equals(mDevice.getAddress())) {
235 if (!address.equals(mDevice.getAddress())) {
261 if (!address.equals(mDevice.getAddress())) {
305 if (!address.equals(mDevice.getAddress())) {
311 s.setDevice(mDevice);
323 BluetoothGattService includedService = getService(mDevice,
357 if (!address.equals(mDevice.getAddress())) {
381 BluetoothGattCharacteristic characteristic = getCharacteristicById(mDevice,
[all …]
/frameworks/base/packages/Shell/tests/src/com/android/shell/
DUiBot.java41 private final UiDevice mDevice; field in UiBot
46 mDevice = UiDevice.getInstance(instrumentation); in UiBot()
57 boolean opened = mDevice.openNotification(); in getNotification()
59 boolean gotIt = mDevice.wait(Until.hasObject(By.pkg(SYSTEMUI_PACKAGE)), mTimeout); in getNotification()
88 boolean gotIt = mDevice.wait(Until.hasObject(By.text(text)), mTimeout); in getObject()
99 boolean gotIt = mDevice.wait(Until.hasObject(By.res(id)), mTimeout); in getObjectById()
110 UiObject uiObject = mDevice.findObject(new UiSelector().text(text)); in getVisibleObject()
121 UiObject uiObject = mDevice.findObject(new UiSelector().resourceId(id)); in getVisibleObjectById()
132 boolean hasIt = mDevice.hasObject(By.res(id)); in assertNotVisibleById()
170 mDevice.pressBack(); in pressBack()
[all …]
/frameworks/base/libs/hwui/renderthread/
DVulkanManager.cpp58 #define GET_DEV_PROC(F) m##F = (PFN_vk##F)vkGetDeviceProcAddr(mDevice, "vk" #F)
62 mDestroyCommandPool(mDevice, mCommandPool, nullptr); in destroy()
66 if (mDevice != VK_NULL_HANDLE) { in destroy()
67 mDeviceWaitIdle(mDevice); in destroy()
68 mDestroyDevice(mDevice, nullptr); in destroy()
77 mDevice = VK_NULL_HANDLE; in destroy()
318 LOG_ALWAYS_FATAL_IF(mCreateDevice(mPhysicalDevice, &deviceInfo, nullptr, &mDevice)); in setupDevice()
346 if (mDevice != VK_NULL_HANDLE) { in initialize()
357 mGetDeviceQueue(mDevice, mGraphicsQueueIndex, 0, &mGraphicsQueue); in initialize()
368 mCreateCommandPool(mDevice, &commandPoolInfo, nullptr, &mCommandPool); in initialize()
[all …]
/frameworks/base/tests/SystemMemoryTest/host/src/com/android/tests/sysmem/host/
DCujs.java24 private Device mDevice; field in Cujs
27 this.mDevice = device; in Cujs()
37 int pid = mDevice.getProcessPid("system_server"); in run()
38 mDevice.executeShellCommand("kill -10 " + pid); in run()
44 mDevice.executeShellCommand(command); in run()
DDevice.java27 private ITestDevice mDevice; field in Device
30 mDevice = device; in Device()
38 return mDevice.executeShellCommand(command); in executeShellCommand()
49 mDevice.enableAdbRoot(); in enableAdbRoot()
60 String pid = mDevice.getProcessPid(name); in getProcessPid()
DMetrics.java35 private Device mDevice; field in Metrics
49 this.mDevice = device; in Metrics()
80 mDevice.enableAdbRoot(); in sample()
82 int pid = mDevice.getProcessPid("system_server"); in sample()
85 String showmap = mDevice.executeShellCommand("showmap " + pid); in sample()
113 String debuggerd = mDevice.executeShellCommand("debuggerd -j " + pid); in sample()
/frameworks/base/core/java/android/bluetooth/le/
DScanResult.java75 private BluetoothDevice mDevice; field in ScanResult
107 mDevice = device; in ScanResult()
136 mDevice = device; in ScanResult()
154 if (mDevice != null) { in writeToParcel()
156 mDevice.writeToParcel(dest, flags); in writeToParcel()
178 mDevice = BluetoothDevice.CREATOR.createFromParcel(in); in readFromParcel()
202 return mDevice; in getDevice()
305 return Objects.hash(mDevice, mRssi, mScanRecord, mTimestampNanos, in hashCode()
320 return Objects.equals(mDevice, other.mDevice) && (mRssi == other.mRssi) in equals()
333 return "ScanResult{" + "device=" + mDevice + ", scanRecord=" in toString()
/frameworks/base/packages/SystemUI/src/com/android/systemui/usb/
DUsbConfirmActivity.java52 private UsbDevice mDevice; field in UsbConfirmActivity
63 mDevice = (UsbDevice) intent.getParcelableExtra(UsbManager.EXTRA_DEVICE); in onCreate()
72 if (mDevice == null) { in onCreate()
78 mDevice.getProductName()); in onCreate()
79 mDisconnectedReceiver = new UsbDisconnectedReceiver(this, mDevice); in onCreate()
91 if (mDevice == null) { in onCreate()
96 mDevice.getProductName())); in onCreate()
125 if (mDevice != null) { in onClick()
127 intent.putExtra(UsbManager.EXTRA_DEVICE, mDevice); in onClick()
130 service.grantDevicePermission(mDevice, uid); in onClick()
[all …]
DUsbResolverActivity.java49 private UsbDevice mDevice; field in UsbResolverActivity
88 mDevice = (UsbDevice)target.getParcelableExtra(UsbManager.EXTRA_DEVICE); in onCreate()
89 if (mDevice != null) { in onCreate()
90 mDisconnectedReceiver = new UsbDisconnectedReceiver(this, mDevice); in onCreate()
112 if (mDevice != null) { in onCreate()
113 mOtherProfileIntent.putExtra(UsbManager.EXTRA_DEVICE, mDevice); in onCreate()
127 if (mDevice == null) { in onCreate()
158 if (mDevice != null) { in onTargetSelected()
160 service.grantDevicePermission(mDevice, uid); in onTargetSelected()
163 service.setDevicePackage(mDevice, ri.activityInfo.packageName, userId); in onTargetSelected()
[all …]
DUsbPermissionActivity.java53 private UsbDevice mDevice; field in UsbPermissionActivity
66 mDevice = (UsbDevice)intent.getParcelableExtra(UsbManager.EXTRA_DEVICE); in onCreate()
86 if (mDevice == null) { in onCreate()
92 mDevice.getProductName()); in onCreate()
93 mDisconnectedReceiver = new UsbDisconnectedReceiver(this, mDevice); in onCreate()
100 if (canBeDefault && (mDevice != null || mAccessory != null)) { in onCreate()
106 if (mDevice == null) { in onCreate()
111 mDevice.getProductName())); in onCreate()
131 if (mDevice != null) { in onDestroy()
132 intent.putExtra(UsbManager.EXTRA_DEVICE, mDevice); in onDestroy()
[all …]
/frameworks/native/services/surfaceflinger/
DDisplayDevice.h261 mDevice(device),
265 const ui::Transform& getTransform() const override { return mDevice->getTransform(); } in getTransform()
266 Rect getBounds() const override { return mDevice->getBounds(); } in getBounds()
267 int getHeight() const override { return mDevice->getHeight(); } in getHeight()
268 int getWidth() const override { return mDevice->getWidth(); } in getWidth()
269 bool isSecure() const override { return mAllowSecureLayers && mDevice->isSecure(); } in isSecure()
270 const sp<const DisplayDevice> getDisplayDevice() const override { return mDevice; } in getDisplayDevice()
275 if (mDevice->needsFiltering()) { in needsFiltering()
293 return mDevice->getScissor(); in getSourceCrop()
301 const Rect& viewport = mDevice->getViewport(); in getSourceCrop()
[all …]
/frameworks/base/services/core/java/com/android/server/hdmi/
DDelayedMessageBuffer.java30 private final HdmiCecLocalDevice mDevice; field in DelayedMessageBuffer
33 mDevice = device; in DelayedMessageBuffer()
91 mDevice.onMessage(message); in processAllMessages()
116 && !mDevice.isInputReady(HdmiDeviceInfo.idForCecDevice(address))) { in processMessagesForDevice()
120 mDevice.onMessage(message); in processMessagesForDevice()
142 mDevice.onMessage(message); in processActiveSource()
/frameworks/ex/camera2/public/src/com/android/ex/camera2/blocking/
DBlockingCameraManager.java181 private CameraDevice mDevice = null; field in BlockingCameraManager.OpenListener
200 assertEquals(null, mDevice); in assertInitialState()
216 mDevice = camera; in onOpened()
241 mDevice = camera; in onDisconnected()
267 mDevice = camera; in onError()
307 if (!mSuccess && mDevice != null) { in blockUntilOpen()
308 mDevice.close(); in blockUntilOpen()
312 return mDevice; in blockUntilOpen()
/frameworks/base/wifi/java/android/net/wifi/p2p/nsd/
DWifiP2pServiceResponse.java60 protected WifiP2pDevice mDevice; field in WifiP2pServiceResponse
123 mDevice = device; in WifiP2pServiceResponse()
176 return mDevice; in getSrcDevice()
182 this.mDevice = dev; in setSrcDevice()
290 sbuf.append(" srcAddr:").append(mDevice.deviceAddress); in toString()
308 equals(req.mDevice.deviceAddress, mDevice.deviceAddress) && in equals()
327 result = 31 * result + (mDevice.deviceAddress == null ? in hashCode()
328 0 : mDevice.deviceAddress.hashCode()); in hashCode()
343 dest.writeParcelable(mDevice, flags); in writeToParcel()
/frameworks/native/libs/binder/
DMemoryHeapBase.cpp39 mDevice(nullptr), mNeedUnmap(false), mOffset(0) in MemoryHeapBase()
45 mDevice(nullptr), mNeedUnmap(false), mOffset(0) in MemoryHeapBase()
62 mDevice(nullptr), mNeedUnmap(false), mOffset(0) in MemoryHeapBase()
74 mDevice = device; in MemoryHeapBase()
81 mDevice(nullptr), mNeedUnmap(false), mOffset(0) in MemoryHeapBase()
97 mDevice = device; in init()
176 return mDevice; in getDevice()
/frameworks/base/core/tests/notificationtests/src/android/app/
DNotificationStressTest.java63 private UiDevice mDevice = null; field in NotificationStressTest
69 mDevice = UiDevice.getInstance(getInstrumentation()); in setUp()
73 mDevice.setOrientationNatural(); in setUp()
79 mDevice.unfreezeRotation(); in tearDown()
81 mDevice.waitForIdle(); in tearDown()
96 mDevice.openNotification(); in testNotificationsWithShadeStress()
/frameworks/native/include/binder/
DMemoryHeapBase.h77 if (mDevice == nullptr) in setDevice()
78 mDevice = device; in setDevice()
79 return mDevice ? NO_ERROR : ALREADY_EXISTS; in setDevice()
95 const char* mDevice; variable
/frameworks/native/libs/binder/include/binder/
DMemoryHeapBase.h77 if (mDevice == nullptr) in setDevice()
78 mDevice = device; in setDevice()
79 return mDevice ? NO_ERROR : ALREADY_EXISTS; in setDevice()
95 const char* mDevice; variable

1234