Home
last modified time | relevance | path

Searched refs:device (Results 1 – 25 of 747) sorted by relevance

12345678910>>...30

/frameworks/native/services/inputflinger/
DEventHub.cpp306 Device* device = mClosingDevices; in ~EventHub() local
307 mClosingDevices = device->next; in ~EventHub()
308 delete device; in ~EventHub()
321 Device* device = getDeviceLocked(deviceId); in getDeviceIdentifier() local
322 if (device == nullptr) return InputDeviceIdentifier(); in getDeviceIdentifier()
323 return device->identifier; in getDeviceIdentifier()
328 Device* device = getDeviceLocked(deviceId); in getDeviceClasses() local
329 if (device == nullptr) return 0; in getDeviceClasses()
330 return device->classes; in getDeviceClasses()
335 Device* device = getDeviceLocked(deviceId); in getDeviceControllerNumber() local
[all …]
/frameworks/av/services/audiopolicy/enginedefault/src/
DEngine.cpp145 uint32_t device = AUDIO_DEVICE_NONE; in getDeviceForStrategyInt() local
152 device = availableOutputDevicesType & AUDIO_DEVICE_OUT_SPEAKER; in getDeviceForStrategyInt()
157 device = getDeviceForStrategyInt( in getDeviceForStrategyInt()
168 device = getDeviceForStrategyInt(STRATEGY_MEDIA, in getDeviceForStrategyInt()
175 && (device & AUDIO_DEVICE_OUT_SPEAKER) in getDeviceForStrategyInt()
177 device |= AUDIO_DEVICE_OUT_SPEAKER_SAFE; in getDeviceForStrategyInt()
178 device &= ~AUDIO_DEVICE_OUT_SPEAKER; in getDeviceForStrategyInt()
186 device = getDeviceForStrategyInt( in getDeviceForStrategyInt()
225 device = availableOutputDevicesType & AUDIO_DEVICE_OUT_BLUETOOTH_SCO_CARKIT; in getDeviceForStrategyInt()
226 if (device) break; in getDeviceForStrategyInt()
[all …]
/frameworks/base/tests/FlickerTests/src/com/android/server/wm/flicker/
DCommonTransitions.java53 private static void setRotation(UiDevice device, int rotation) { in setRotation() argument
57 device.setOrientationLeft(); in setRotation()
61 device.setOrientationRight(); in setRotation()
66 device.setOrientationNatural(); in setRotation()
75 private static void clickEditTextWidget(UiDevice device, IAppHelper testApp) { in clickEditTextWidget() argument
76 UiObject2 editText = device.findObject(By.res(testApp.getPackage(), "plain_text_input")); in clickEditTextWidget()
81 private static void clickEnterPipButton(UiDevice device, IAppHelper testApp) { in clickEnterPipButton() argument
82 UiObject2 enterPipButton = device.findObject(By.res(testApp.getPackage(), "enter_pip")); in clickEnterPipButton()
88 device) { in openAppWarm() argument
93 .runBefore(device::pressHome) in openAppWarm()
[all …]
/frameworks/base/core/tests/bluetoothtests/src/android/bluetooth/
DBluetoothStressTest.java147 BluetoothDevice device = mAdapter.getRemoteDevice(BluetoothTestRunner.sDeviceAddress); in testPair() local
149 mTestUtils.unpair(mAdapter, device); in testPair()
153 mTestUtils.pair(mAdapter, device, BluetoothTestRunner.sDevicePairPasskey, in testPair()
155 mTestUtils.unpair(mAdapter, device); in testPair()
170 BluetoothDevice device = mAdapter.getRemoteDevice(BluetoothTestRunner.sDeviceAddress); in testAcceptPair() local
172 mTestUtils.unpair(mAdapter, device); in testAcceptPair()
176 mTestUtils.acceptPair(mAdapter, device, BluetoothTestRunner.sDevicePairPasskey, in testAcceptPair()
178 mTestUtils.unpair(mAdapter, device); in testAcceptPair()
194 BluetoothDevice device = mAdapter.getRemoteDevice(BluetoothTestRunner.sDeviceAddress); in testConnectA2dp() local
196 mTestUtils.unpair(mAdapter, device); in testConnectA2dp()
[all …]
/frameworks/base/tests/FlickerTests/lib/src/com/android/server/wm/flicker/
DAutomationUtils.java57 UiDevice device = UiDevice.getInstance(InstrumentationRegistry in wakeUpAndGoToHomeScreen() local
60 device.wakeUp(); in wakeUpAndGoToHomeScreen()
64 device.pressHome(); in wakeUpAndGoToHomeScreen()
84 public static boolean isQuickstepEnabled(UiDevice device) { in isQuickstepEnabled() argument
85 return device.findObject(By.res(SYSTEMUI_PACKAGE, "recent_apps")) == null; in isQuickstepEnabled()
88 public static void openQuickstep(UiDevice device) { in openQuickstep() argument
89 if (isQuickstepEnabled(device)) { in openQuickstep()
90 int height = device.getDisplayHeight(); in openQuickstep()
91 UiObject2 navBar = device.findObject(By.res(SYSTEMUI_PACKAGE, "navigation_bar_frame")); in openQuickstep()
104 device.swipe( in openQuickstep()
[all …]
/frameworks/base/core/java/android/companion/
DBluetoothDeviceFilterUtils.java54 static boolean matches(ScanFilter filter, BluetoothDevice device) { in matches() argument
55 boolean result = matchesAddress(filter.getDeviceAddress(), device) in matches()
56 && matchesServiceUuid(filter.getServiceUuid(), filter.getServiceUuidMask(), device); in matches()
57 if (DEBUG) debugLogMatchResult(result, device, filter); in matches()
61 static boolean matchesAddress(String deviceAddress, BluetoothDevice device) { in matchesAddress() argument
63 || (device != null && deviceAddress.equals(device.getAddress())); in matchesAddress()
64 if (DEBUG) debugLogMatchResult(result, device, deviceAddress); in matchesAddress()
69 List<ParcelUuid> serviceUuidMasks, BluetoothDevice device) { in matchesServiceUuids() argument
73 if (!matchesServiceUuid(uuid, uuidMask, device)) { in matchesServiceUuids()
81 BluetoothDevice device) { in matchesServiceUuid() argument
[all …]
/frameworks/base/packages/MtpDocumentsProvider/src/com/android/mtp/
DMtpManager.java94 final MtpDevice device = new MtpDevice(rawDevice); in openDevice() local
100 if (!device.open(connection)) { in openDevice()
107 device.getStorageIds(), in openDevice()
110 mDevices.put(deviceId, device); in openDevice()
121 for (UsbDevice device : mManager.getDeviceList().values()) { in getDevices()
122 if (!isMtpDevice(device)) { in getDevices()
125 devices.add(createDeviceRecord(device)); in getDevices()
131 final MtpDevice device = getDevice(deviceId); in getObjectInfo() local
132 synchronized (device) { in getObjectInfo()
134 device.getObjectInfo(objectHandle), in getObjectInfo()
[all …]
/frameworks/av/services/audiopolicy/common/include/
DVolume.h85 static audio_devices_t getDeviceForVolume(audio_devices_t device) in getDeviceForVolume() argument
87 if (device == AUDIO_DEVICE_NONE) { in getDeviceForVolume()
90 device = AUDIO_DEVICE_OUT_SPEAKER; in getDeviceForVolume()
91 } else if (popcount(device) > 1) { in getDeviceForVolume()
98 if (device & AUDIO_DEVICE_OUT_SPEAKER) { in getDeviceForVolume()
99 device = AUDIO_DEVICE_OUT_SPEAKER; in getDeviceForVolume()
100 } else if (device & AUDIO_DEVICE_OUT_SPEAKER_SAFE) { in getDeviceForVolume()
101 device = AUDIO_DEVICE_OUT_SPEAKER_SAFE; in getDeviceForVolume()
102 } else if (device & AUDIO_DEVICE_OUT_HDMI_ARC) { in getDeviceForVolume()
103 device = AUDIO_DEVICE_OUT_HDMI_ARC; in getDeviceForVolume()
[all …]
/frameworks/base/tests/UsbHostExternalManagmentTest/UsbHostExternalManagmentTestApp/src/com/android/hardware/usb/externalmanagementtest/
DUsbDeviceStateController.java38 void onDeviceResetComplete(UsbDevice device); in onDeviceResetComplete() argument
102 public void startDeviceReset(UsbDevice device) { in startDeviceReset() argument
103 mHandler.requestDeviceReset(device); in startDeviceReset()
110 private void doHandleDeviceReset(UsbDevice device) { in doHandleDeviceReset() argument
111 boolean isInAoap = AoapInterface.isDeviceInAoapMode(device); in doHandleDeviceReset()
114 completedDevice = resetUsbDeviceAndConfirmModeChange(device); in doHandleDeviceReset()
116 UsbDeviceConnection conn = openConnection(device); in doHandleDeviceReset()
118 throw new RuntimeException("cannot open conneciton for device: " + device); in doHandleDeviceReset()
122 throw new RuntimeException("resetDevice failed for devie: " + device); in doHandleDeviceReset()
124 completedDevice = device; in doHandleDeviceReset()
[all …]
/frameworks/base/core/java/android/bluetooth/
DBluetoothHidHost.java266 public boolean connect(BluetoothDevice device) { in connect() argument
267 if (DBG) log("connect(" + device + ")"); in connect()
269 if (service != null && isEnabled() && isValidDevice(device)) { in connect()
271 return service.connect(device); in connect()
306 public boolean disconnect(BluetoothDevice device) { in disconnect() argument
307 if (DBG) log("disconnect(" + device + ")"); in disconnect()
309 if (service != null && isEnabled() && isValidDevice(device)) { in disconnect()
311 return service.disconnect(device); in disconnect()
363 public int getConnectionState(BluetoothDevice device) { in getConnectionState() argument
364 if (VDBG) log("getState(" + device + ")"); in getConnectionState()
[all …]
DBluetoothHeadsetClient.java411 public boolean connect(BluetoothDevice device) { in connect() argument
412 if (DBG) log("connect(" + device + ")"); in connect()
415 if (service != null && isEnabled() && isValidDevice(device)) { in connect()
417 return service.connect(device); in connect()
435 public boolean disconnect(BluetoothDevice device) { in disconnect() argument
436 if (DBG) log("disconnect(" + device + ")"); in disconnect()
439 if (service != null && isEnabled() && isValidDevice(device)) { in disconnect()
441 return service.disconnect(device); in disconnect()
504 public int getConnectionState(BluetoothDevice device) { in getConnectionState() argument
505 if (VDBG) log("getConnectionState(" + device + ")"); in getConnectionState()
[all …]
DBluetoothA2dp.java257 public boolean connect(BluetoothDevice device) { in connect() argument
258 if (DBG) log("connect(" + device + ")"); in connect()
261 if (service != null && isEnabled() && isValidDevice(device)) { in connect()
262 return service.connect(device); in connect()
298 public boolean disconnect(BluetoothDevice device) { in disconnect() argument
299 if (DBG) log("disconnect(" + device + ")"); in disconnect()
302 if (service != null && isEnabled() && isValidDevice(device)) { in disconnect()
303 return service.disconnect(device); in disconnect()
355 public @BtProfileState int getConnectionState(BluetoothDevice device) { in getConnectionState() argument
356 if (VDBG) log("getState(" + device + ")"); in getConnectionState()
[all …]
DBluetoothMapClient.java121 public boolean isConnected(BluetoothDevice device) { in isConnected() argument
122 if (VDBG) Log.d(TAG, "isConnected(" + device + ")"); in isConnected()
126 return service.isConnected(device); in isConnected()
141 public boolean connect(BluetoothDevice device) { in connect() argument
142 if (DBG) Log.d(TAG, "connect(" + device + ")" + "for MAPS MCE"); in connect()
146 return service.connect(device); in connect()
163 public boolean disconnect(BluetoothDevice device) { in disconnect() argument
164 if (DBG) Log.d(TAG, "disconnect(" + device + ")"); in disconnect()
166 if (service != null && isEnabled() && isValidDevice(device)) { in disconnect()
168 return service.disconnect(device); in disconnect()
[all …]
/frameworks/base/wifi/tests/src/android/net/wifi/p2p/
DWifiP2pDeviceTest.java76 WifiP2pDevice device = new WifiP2pDevice(); in testCopyConstructorWithDefaultValues() local
77 WifiP2pDevice copy = new WifiP2pDevice(device); in testCopyConstructorWithDefaultValues()
78 compareWifiP2pDevices(device, copy); in testCopyConstructorWithDefaultValues()
86 WifiP2pDevice device = new WifiP2pDevice(); in testCopyConstructorWithUpdatedValues() local
87 device.deviceName = "deviceName"; in testCopyConstructorWithUpdatedValues()
88 device.deviceAddress = "11:22:33:44:55:66"; in testCopyConstructorWithUpdatedValues()
89 device.primaryDeviceType = "primaryDeviceType"; in testCopyConstructorWithUpdatedValues()
90 device.secondaryDeviceType = "secondaryDeviceType"; in testCopyConstructorWithUpdatedValues()
91 device.wpsConfigMethodsSupported = 0x0008; in testCopyConstructorWithUpdatedValues()
92 device.deviceCapability = 1; in testCopyConstructorWithUpdatedValues()
[all …]
/frameworks/base/tools/preload2/src/com/android/preload/
DClientUtils.java45 public Client findClient(IDevice device, String processName, int processPid) { in findClient() argument
46 return findClient(device, processName, processPid, defaultTimeout); in findClient()
59 public Client findClient(IDevice device, String processName, int processPid, int timeout) { in findClient() argument
60 WaitForClient wfc = new WaitForClient(device, processName, processPid, timeout); in findClient()
67 public Client[] findAllClients(IDevice device) { in findAllClients() argument
68 return findAllClients(device, defaultTimeout); in findAllClients()
79 public Client[] findAllClients(IDevice device, int timeout) { in findAllClients() argument
80 if (device.hasClients()) { in findAllClients()
81 return device.getClients(); in findAllClients()
83 WaitForClients wfc = new WaitForClients(device, timeout); in findAllClients()
[all …]
DDeviceUtils.java65 public static void doShell(IDevice device, String cmdline, long timeout, TimeUnit unit) { in doShell() argument
66 doShell(device, cmdline, new NullShellOutputReceiver(), timeout, unit); in doShell()
72 public static String doShellReturnString(IDevice device, String cmdline, long timeout, in doShellReturnString() argument
75 doShell(device, cmdline, rec, timeout, unit); in doShellReturnString()
82 public static void doShell(IDevice device, String cmdline, IShellOutputReceiver receiver, in doShell() argument
85 device.executeShellCommand(cmdline, receiver, timeout, unit); in doShell()
94 public static void doAMStart(IDevice device, String name, String activity) { in doAMStart() argument
95 doShell(device, "am start -n " + name + " /." + activity, 30, TimeUnit.SECONDS); in doAMStart()
119 public static String getBuildType(IDevice device) { in getBuildType() argument
121 Future<String> buildType = device.getSystemProperty("ro.build.type"); in getBuildType()
[all …]
/frameworks/base/core/java/android/hardware/usb/
DDeviceFilter.java72 public DeviceFilter(UsbDevice device) { in DeviceFilter() argument
73 mVendorId = device.getVendorId(); in DeviceFilter()
74 mProductId = device.getProductId(); in DeviceFilter()
75 mClass = device.getDeviceClass(); in DeviceFilter()
76 mSubclass = device.getDeviceSubclass(); in DeviceFilter()
77 mProtocol = device.getDeviceProtocol(); in DeviceFilter()
78 mManufacturerName = device.getManufacturerName(); in DeviceFilter()
79 mProductName = device.getProductName(); in DeviceFilter()
80 mSerialNumber = device.getSerialNumber(); in DeviceFilter()
173 public boolean matches(UsbDevice device) { in matches() argument
[all …]
/frameworks/native/vulkan/vkjson/
Dvkjson_instance.cc72 VkJsonDevice device; in VkJsonGetDevice() local
93 device.extensions.resize(extension_count); in VkJsonGetDevice()
95 physical_device, nullptr, &extension_count, device.extensions.data()); in VkJsonGetDevice()
101 device.layers.resize(layer_count); in VkJsonGetDevice()
103 device.layers.data()); in VkJsonGetDevice()
113 if (HasExtension("VK_KHR_driver_properties", device.extensions)) { in VkJsonGetDevice()
114 device.ext_driver_properties.reported = true; in VkJsonGetDevice()
115 device.ext_driver_properties.driver_properties_khr.sType = in VkJsonGetDevice()
117 device.ext_driver_properties.driver_properties_khr.pNext = in VkJsonGetDevice()
120 &device.ext_driver_properties.driver_properties_khr; in VkJsonGetDevice()
[all …]
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/
DA2dpProfile.java67 CachedBluetoothDevice device = mDeviceManager.findDevice(nextDevice); in onServiceConnected() local
69 if (device == null) { in onServiceConnected()
71 device = mDeviceManager.addDevice(nextDevice); in onServiceConnected()
73 device.onProfileStateChanged(A2dpProfile.this, BluetoothProfile.STATE_CONNECTED); in onServiceConnected()
74 device.refresh(); in onServiceConnected()
150 public boolean connect(BluetoothDevice device) { in connect() argument
152 return mService.connect(device); in connect()
155 public boolean disconnect(BluetoothDevice device) { in disconnect() argument
158 if (mService.getPriority(device) > BluetoothProfile.PRIORITY_ON){ in disconnect()
159 mService.setPriority(device, BluetoothProfile.PRIORITY_ON); in disconnect()
[all …]
DHearingAidProfile.java59 CachedBluetoothDevice device = mDeviceManager.findDevice(nextDevice); in onServiceConnected() local
61 if (device == null) { in onServiceConnected()
65 device = mDeviceManager.addDevice(nextDevice); in onServiceConnected()
67 device.onProfileStateChanged(HearingAidProfile.this, in onServiceConnected()
69 device.refresh(); in onServiceConnected()
148 public boolean connect(BluetoothDevice device) { in connect() argument
150 return mService.connect(device); in connect()
153 public boolean disconnect(BluetoothDevice device) { in disconnect() argument
156 if (mService.getPriority(device) > BluetoothProfile.PRIORITY_ON){ in disconnect()
157 mService.setPriority(device, BluetoothProfile.PRIORITY_ON); in disconnect()
[all …]
DHeadsetProfile.java66 CachedBluetoothDevice device = mDeviceManager.findDevice(nextDevice); in onServiceConnected() local
68 if (device == null) { in onServiceConnected()
70 device = mDeviceManager.addDevice(nextDevice); in onServiceConnected()
72 device.onProfileStateChanged(HeadsetProfile.this, in onServiceConnected()
74 device.refresh(); in onServiceConnected()
111 public boolean connect(BluetoothDevice device) { in connect() argument
115 return mService.connect(device); in connect()
118 public boolean disconnect(BluetoothDevice device) { in disconnect() argument
123 if (mService.getPriority(device) > BluetoothProfile.PRIORITY_ON) { in disconnect()
124 mService.setPriority(device, BluetoothProfile.PRIORITY_ON); in disconnect()
[all …]
/frameworks/base/wifi/java/android/net/wifi/p2p/
DWifiP2pDeviceList.java54 for (WifiP2pDevice device : devices) { in WifiP2pDeviceList()
55 if (device.deviceAddress != null) { in WifiP2pDeviceList()
56 mDevices.put(device.deviceAddress, new WifiP2pDevice(device)); in WifiP2pDeviceList()
61 private void validateDevice(WifiP2pDevice device) { in validateDevice() argument
62 if (device == null) throw new IllegalArgumentException("Null device"); in validateDevice()
63 if (TextUtils.isEmpty(device.deviceAddress)) { in validateDevice()
88 public void update(WifiP2pDevice device) { in update() argument
89 updateSupplicantDetails(device); in update()
90 mDevices.get(device.deviceAddress).status = device.status; in update()
94 public void updateSupplicantDetails(WifiP2pDevice device) { in updateSupplicantDetails() argument
[all …]
/frameworks/native/vulkan/libvulkan/
Dapi_gen.cpp82 VKAPI_ATTR VkResult disabledCreateSwapchainKHR(VkDevice device, const VkSwapchainCreateInfoKHR*, co… in disabledCreateSwapchainKHR() argument
83 …driver::Logger(device).Err(device, "VK_KHR_swapchain not enabled. Exported vkCreateSwapchainKHR no… in disabledCreateSwapchainKHR()
87 VKAPI_ATTR void disabledDestroySwapchainKHR(VkDevice device, VkSwapchainKHR, const VkAllocationCall… in disabledDestroySwapchainKHR() argument
88 …driver::Logger(device).Err(device, "VK_KHR_swapchain not enabled. Exported vkDestroySwapchainKHR n… in disabledDestroySwapchainKHR()
91 VKAPI_ATTR VkResult disabledGetSwapchainImagesKHR(VkDevice device, VkSwapchainKHR, uint32_t*, VkIma… in disabledGetSwapchainImagesKHR() argument
92 …driver::Logger(device).Err(device, "VK_KHR_swapchain not enabled. Exported vkGetSwapchainImagesKHR… in disabledGetSwapchainImagesKHR()
96 VKAPI_ATTR VkResult disabledAcquireNextImageKHR(VkDevice device, VkSwapchainKHR, uint64_t, VkSemaph… in disabledAcquireNextImageKHR() argument
97 …driver::Logger(device).Err(device, "VK_KHR_swapchain not enabled. Exported vkAcquireNextImageKHR n… in disabledAcquireNextImageKHR()
106 VKAPI_ATTR VkResult disabledGetDeviceGroupPresentCapabilitiesKHR(VkDevice device, VkDeviceGroupPres… in disabledGetDeviceGroupPresentCapabilitiesKHR() argument
107 …driver::Logger(device).Err(device, "VK_KHR_swapchain not enabled. Exported vkGetDeviceGroupPresent… in disabledGetDeviceGroupPresentCapabilitiesKHR()
[all …]
Ddriver_gen.cpp34 VKAPI_ATTR VkResult checkedCreateSwapchainKHR(VkDevice device, const VkSwapchainCreateInfoKHR* pCre… in checkedCreateSwapchainKHR() argument
35 if (GetData(device).hook_extensions[ProcHook::KHR_swapchain]) { in checkedCreateSwapchainKHR()
36 return CreateSwapchainKHR(device, pCreateInfo, pAllocator, pSwapchain); in checkedCreateSwapchainKHR()
38 … Logger(device).Err(device, "VK_KHR_swapchain not enabled. vkCreateSwapchainKHR not executed."); in checkedCreateSwapchainKHR()
43 VKAPI_ATTR void checkedDestroySwapchainKHR(VkDevice device, VkSwapchainKHR swapchain, const VkAlloc… in checkedDestroySwapchainKHR() argument
44 if (GetData(device).hook_extensions[ProcHook::KHR_swapchain]) { in checkedDestroySwapchainKHR()
45 DestroySwapchainKHR(device, swapchain, pAllocator); in checkedDestroySwapchainKHR()
47 … Logger(device).Err(device, "VK_KHR_swapchain not enabled. vkDestroySwapchainKHR not executed."); in checkedDestroySwapchainKHR()
51 VKAPI_ATTR VkResult checkedGetSwapchainImagesKHR(VkDevice device, VkSwapchainKHR swapchain, uint32_… in checkedGetSwapchainImagesKHR() argument
52 if (GetData(device).hook_extensions[ProcHook::KHR_swapchain]) { in checkedGetSwapchainImagesKHR()
[all …]
/frameworks/base/core/jni/
Dandroid_hardware_UsbDeviceConnection.cpp57 struct usb_device* device = usb_device_new(deviceNameStr, fd); in android_hardware_UsbDeviceConnection_open() local
58 if (device) { in android_hardware_UsbDeviceConnection_open()
59 env->SetLongField(thiz, field_context, (jlong)device); in android_hardware_UsbDeviceConnection_open()
66 return (device != NULL) ? JNI_TRUE : JNI_FALSE; in android_hardware_UsbDeviceConnection_open()
73 struct usb_device* device = get_device_from_object(env, thiz); in android_hardware_UsbDeviceConnection_close() local
74 if (device) { in android_hardware_UsbDeviceConnection_close()
75 usb_device_close(device); in android_hardware_UsbDeviceConnection_close()
83 struct usb_device* device = get_device_from_object(env, thiz); in android_hardware_UsbDeviceConnection_get_fd() local
84 if (!device) { in android_hardware_UsbDeviceConnection_get_fd()
88 return usb_device_get_fd(device); in android_hardware_UsbDeviceConnection_get_fd()
[all …]

12345678910>>...30