OLD | NEW |
---|---|
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CHROME_BROWSER_UI_WEBUI_BLUETOOTH_INTERNALS_BLUETOOTH_INTERNALS_UI_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_BLUETOOTH_INTERNALS_BLUETOOTH_INTERNALS_UI_H_ |
6 #define CHROME_BROWSER_UI_WEBUI_BLUETOOTH_INTERNALS_BLUETOOTH_INTERNALS_UI_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_BLUETOOTH_INTERNALS_BLUETOOTH_INTERNALS_UI_H_ |
7 | 7 |
8 #include <memory> | |
9 | |
8 #include "base/macros.h" | 10 #include "base/macros.h" |
9 #include "content/public/browser/web_ui_controller.h" | 11 #include "chrome/browser/ui/webui/bluetooth_internals/bluetooth_internals.mojom. h" |
12 #include "chrome/browser/ui/webui/mojo_web_ui_controller.h" | |
13 #include "chrome/browser/ui/webui/mojo_web_ui_handler.h" | |
14 #include "device/bluetooth/public/interfaces/bluetooth.mojom.h" | |
10 | 15 |
11 // The WebUI for chrome://bluetooth-internals | 16 // WebUI for chrome://bluetooth-internals; Exposes Bluetooth Adapter Mojo |
12 class BluetoothInternalsUI : public content::WebUIController { | 17 // service from device/bluetooth/public/interfaces/bluetooth.mojom. |
18 class BluetoothInternalsUI | |
19 : public mojom::InternalsPageHandler, | |
20 public MojoWebUIController<mojom::InternalsPageHandler>, | |
21 public MojoWebUIHandler { | |
13 public: | 22 public: |
14 explicit BluetoothInternalsUI(content::WebUI* web_ui); | 23 explicit BluetoothInternalsUI(content::WebUI* web_ui); |
15 ~BluetoothInternalsUI() override; | 24 ~BluetoothInternalsUI() override; |
16 | 25 |
17 private: | 26 private: |
27 // MojoWebUIController overrides: | |
28 void BindUIHandler(mojom::InternalsPageHandlerRequest request) override; | |
29 | |
30 // mojom::InternalsPageHandler overrides: | |
ortuno
2016/09/26 01:57:56
The structure you had before was fine. Sorry!
mbrunson
2016/09/28 02:18:22
I'm reverting the entire WebUI to its state before
| |
31 void GetAdapterService(bluetooth::mojom::AdapterRequest request, | |
32 bluetooth::mojom::AdapterClientPtr client) override; | |
33 | |
34 std::unique_ptr<mojo::Binding<mojom::InternalsPageHandler>> binding_ptr_; | |
35 | |
18 DISALLOW_COPY_AND_ASSIGN(BluetoothInternalsUI); | 36 DISALLOW_COPY_AND_ASSIGN(BluetoothInternalsUI); |
19 }; | 37 }; |
20 | 38 |
21 #endif // CHROME_BROWSER_UI_WEBUI_BLUETOOTH_INTERNALS_BLUETOOTH_INTERNALS_UI_H_ | 39 #endif // CHROME_BROWSER_UI_WEBUI_BLUETOOTH_INTERNALS_BLUETOOTH_INTERNALS_UI_H_ |
OLD | NEW |