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

Side by Side Diff: chrome/browser/chooser_controller/mock_chooser_controller.h

Issue 2746313002: Remove RenderFrameHost pointer from ChooserController. (Closed)
Patch Set: Fix Android build and juncai@ comment. Created 3 years, 9 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 unified diff | Download patch
OLDNEW
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_CHOOSER_CONTROLLER_MOCK_CHOOSER_CONTROLLER_H_ 5 #ifndef CHROME_BROWSER_CHOOSER_CONTROLLER_MOCK_CHOOSER_CONTROLLER_H_
6 #define CHROME_BROWSER_CHOOSER_CONTROLLER_MOCK_CHOOSER_CONTROLLER_H_ 6 #define CHROME_BROWSER_CHOOSER_CONTROLLER_MOCK_CHOOSER_CONTROLLER_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "chrome/browser/chooser_controller/chooser_controller.h" 11 #include "chrome/browser/chooser_controller/chooser_controller.h"
12 #include "content/public/browser/bluetooth_chooser.h" 12 #include "content/public/browser/bluetooth_chooser.h"
13 #include "testing/gmock/include/gmock/gmock.h" 13 #include "testing/gmock/include/gmock/gmock.h"
14 14
15 class MockChooserController : public ChooserController { 15 class MockChooserController : public ChooserController {
16 public: 16 public:
17 enum ConnectedPairedStatus { 17 enum ConnectedPairedStatus {
18 NONE = 0, 18 NONE = 0,
19 CONNECTED = 1 << 0, 19 CONNECTED = 1 << 0,
20 PAIRED = 1 << 1, 20 PAIRED = 1 << 1,
21 }; 21 };
22 22
23 explicit MockChooserController(content::RenderFrameHost* owner); 23 MockChooserController();
24 ~MockChooserController() override; 24 ~MockChooserController() override;
25 25
26 // ChooserController: 26 // ChooserController:
27 bool ShouldShowIconBeforeText() const override; 27 bool ShouldShowIconBeforeText() const override;
28 base::string16 GetNoOptionsText() const override; 28 base::string16 GetNoOptionsText() const override;
29 base::string16 GetOkButtonLabel() const override; 29 base::string16 GetOkButtonLabel() const override;
30 size_t NumOptions() const override; 30 size_t NumOptions() const override;
31 int GetSignalStrengthLevel(size_t index) const override; 31 int GetSignalStrengthLevel(size_t index) const override;
32 base::string16 GetOption(size_t index) const override; 32 base::string16 GetOption(size_t index) const override;
33 bool IsConnected(size_t index) const override; 33 bool IsConnected(size_t index) const override;
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 int connected_paired_status; 72 int connected_paired_status;
73 }; 73 };
74 74
75 std::vector<OptionInfo> options_; 75 std::vector<OptionInfo> options_;
76 base::string16 status_text_; 76 base::string16 status_text_;
77 77
78 DISALLOW_COPY_AND_ASSIGN(MockChooserController); 78 DISALLOW_COPY_AND_ASSIGN(MockChooserController);
79 }; 79 };
80 80
81 #endif // CHROME_BROWSER_CHOOSER_CONTROLLER_MOCK_CHOOSER_CONTROLLER_H_ 81 #endif // CHROME_BROWSER_CHOOSER_CONTROLLER_MOCK_CHOOSER_CONTROLLER_H_
OLDNEW
« no previous file with comments | « chrome/browser/chooser_controller/chooser_controller.cc ('k') | chrome/browser/chooser_controller/mock_chooser_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698