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

Unified Diff: chrome/browser/ui/bluetooth/bluetooth_chooser_desktop.h

Issue 1984923002: Refactor ChooserBubbleController (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address comments Created 4 years, 7 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: chrome/browser/ui/bluetooth/bluetooth_chooser_desktop.h
diff --git a/chrome/browser/ui/bluetooth/bluetooth_chooser_desktop.h b/chrome/browser/ui/bluetooth/bluetooth_chooser_desktop.h
index ccd28172295e7de009860df2dcdf2f078fa40cf3..09ac47de42d8ac70d78be92444b5952af13bd7c1 100644
--- a/chrome/browser/ui/bluetooth/bluetooth_chooser_desktop.h
+++ b/chrome/browser/ui/bluetooth/bluetooth_chooser_desktop.h
@@ -8,7 +8,7 @@
#include "base/macros.h"
#include "content/public/browser/bluetooth_chooser.h"
-class BluetoothChooserBubbleController;
+class BluetoothChooserController;
// Represents a Bluetooth chooser to ask the user to select a Bluetooth
// device from a list of options. This implementation is for desktop.
@@ -16,7 +16,7 @@ class BluetoothChooserBubbleController;
class BluetoothChooserDesktop : public content::BluetoothChooser {
public:
explicit BluetoothChooserDesktop(
- const content::BluetoothChooser::EventHandler& event_handler);
+ BluetoothChooserController* bluetooth_chooser_controller);
~BluetoothChooserDesktop() override;
// BluetoothChooser:
@@ -26,18 +26,9 @@ class BluetoothChooserDesktop : public content::BluetoothChooser {
const base::string16& device_name) override;
void RemoveDevice(const std::string& device_id) override;
- void set_bluetooth_chooser_bubble_controller(
- BluetoothChooserBubbleController* bluetooth_chooser_bubble_controller) {
- bluetooth_chooser_bubble_controller_ = bluetooth_chooser_bubble_controller;
- }
-
- // Use this function to call event_handler_.
- void CallEventHandler(content::BluetoothChooser::Event event,
- const std::string& device_id);
-
private:
- content::BluetoothChooser::EventHandler event_handler_;
- BluetoothChooserBubbleController* bluetooth_chooser_bubble_controller_;
+ // Weak. ChooserBubbleDelegate owns it.
+ BluetoothChooserController* bluetooth_chooser_controller_;
DISALLOW_COPY_AND_ASSIGN(BluetoothChooserDesktop);
};
« no previous file with comments | « chrome/browser/ui/bluetooth/bluetooth_chooser_controller.cc ('k') | chrome/browser/ui/bluetooth/bluetooth_chooser_desktop.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698