summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--chrome/browser/usb/usb_service.cc25
-rw-r--r--chrome/browser/usb/usb_service.h5
2 files changed, 0 insertions, 30 deletions
diff --git a/chrome/browser/usb/usb_service.cc b/chrome/browser/usb/usb_service.cc
index c4f2ae9..080b035 100644
--- a/chrome/browser/usb/usb_service.cc
+++ b/chrome/browser/usb/usb_service.cc
@@ -63,31 +63,6 @@ void UsbService::Cleanup() {
event_handler_ = NULL;
}
-// TODO(gdk): Remove this method. It is a lesser-functional version of
-// FindDevices, and essentially duplicates much of the work it does, due to the
-// device-handle oritented restructuring.
-UsbDevice* UsbService::FindDevice(const uint16 vendor_id,
- const uint16 product_id) {
- DCHECK(event_handler_) << "FindDevice called after event handler stopped.";
- UsbDevice* device = NULL;
-
- DeviceVector enumerated_devices;
- EnumerateDevices(&enumerated_devices);
- if (enumerated_devices.empty())
- return NULL;
-
- for (unsigned int i = 0; i < enumerated_devices.size(); ++i) {
- PlatformUsbDevice current_device = enumerated_devices[i].device();
- if (DeviceMatches(current_device, vendor_id, product_id)) {
- device = LookupOrCreateDevice(current_device);
- if (device)
- break;
- }
- }
-
- return device;
-}
-
bool UsbService::FindDevices(const uint16 vendor_id,
const uint16 product_id,
vector<scoped_refptr<UsbDevice> >* devices) {
diff --git a/chrome/browser/usb/usb_service.h b/chrome/browser/usb/usb_service.h
index 648f3bda..02d8427 100644
--- a/chrome/browser/usb/usb_service.h
+++ b/chrome/browser/usb/usb_service.h
@@ -31,11 +31,6 @@ class UsbService : public ProfileKeyedService {
// event handling thread and disposes of open devices.
void Cleanup();
- // Find the (topologically) first USB device identified by vendor_id and
- // product_id. The created device is associated with this service, so that
- // it can be used to close the device later.
- UsbDevice* FindDevice(const uint16 vendor_id, const uint16 product_id);
-
// Find all of the devices attached to the system that are identified by
// |vendor_id| and |product_id|, inserting them into |devices|. Clears
// |devices| before use.