Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1163)

Unified Diff: third_party/WebKit/public/platform/modules/webusb/WebUSBClient.h

Issue 1850023002: Consume Mojo services directly in Blink's WebUSB implementation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Don't do assignments in if statements. Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/public/platform/modules/webusb/WebUSBClient.h
diff --git a/third_party/WebKit/public/platform/modules/webusb/WebUSBClient.h b/third_party/WebKit/public/platform/modules/webusb/WebUSBClient.h
deleted file mode 100644
index 2dee386511abc93580b31e63a27116ccb48dffd8..0000000000000000000000000000000000000000
--- a/third_party/WebKit/public/platform/modules/webusb/WebUSBClient.h
+++ /dev/null
@@ -1,52 +0,0 @@
-// Copyright 2015 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef WebUSBClient_h
-#define WebUSBClient_h
-
-#include "public/platform/WebCallbacks.h"
-#include "public/platform/WebVector.h"
-
-namespace blink {
-
-class WebUSBDevice;
-struct WebUSBDeviceRequestOptions;
-struct WebUSBError;
-
-using WebUSBClientGetDevicesCallbacks = WebCallbacks<std::unique_ptr<WebVector<WebUSBDevice*>>, const WebUSBError&>;
-using WebUSBClientRequestDeviceCallbacks = WebCallbacks<std::unique_ptr<WebUSBDevice>, const WebUSBError&>;
-
-class WebUSBClient {
-public:
- class Observer {
- public:
- virtual ~Observer() { }
-
- // Called when a device is connected to the system.
- virtual void onDeviceConnected(std::unique_ptr<WebUSBDevice>) = 0;
-
- // Called when a device is disconnected from the system.
- virtual void onDeviceDisconnected(std::unique_ptr<WebUSBDevice>) = 0;
- };
-
- virtual ~WebUSBClient() { }
-
- // Enumerates available devices.
- // Ownership of the WebUSBClientGetDevicesCallbacks is transferred to the client.
- virtual void getDevices(WebUSBClientGetDevicesCallbacks*) = 0;
-
- // Requests access to a device.
- // Ownership of the WebUSBClientRequestDeviceCallbacks is transferred to the client.
- virtual void requestDevice(const WebUSBDeviceRequestOptions&, WebUSBClientRequestDeviceCallbacks*) = 0;
-
- // Adds an observer of device changes to the WebUSBClient.
- virtual void addObserver(Observer*) = 0;
-
- // Removes an observer of device changes from the WebUSBClient.
- virtual void removeObserver(Observer*) = 0;
-};
-
-} // namespace blink
-
-#endif // WebUSBClient_h

Powered by Google App Engine
This is Rietveld 408576698