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

Side by Side Diff: chrome/browser/ui/views/website_settings/chooser_bubble_ui_view.h

Issue 2748443005: Rename website_settings UI folders to permission_bubble. (Closed)
Patch Set: Rebase. 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
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_UI_VIEWS_WEBSITE_SETTINGS_CHOOSER_BUBBLE_UI_VIEW_H_
6 #define CHROME_BROWSER_UI_VIEWS_WEBSITE_SETTINGS_CHOOSER_BUBBLE_UI_VIEW_H_
7
8 #include <memory>
9
10 #include "base/macros.h"
11 #include "components/bubble/bubble_ui.h"
12 #include "ui/views/bubble/bubble_border.h"
13
14 namespace views {
15 class View;
16 }
17
18 class Browser;
19 class ChooserController;
20 class ChooserBubbleUiViewDelegate;
21
22 // ChooserBubbleUiView implements a chooser-based permission model,
23 // it uses table view to show a list of items (such as usb devices, etc.)
24 // for user to grant permission. It can be used by the WebUSB or WebBluetooth
25 // APIs. It is owned by the BubbleController, which is owned by the
26 // BubbleManager.
27 class ChooserBubbleUiView : public BubbleUi {
28 public:
29 ChooserBubbleUiView(Browser* browser,
30 std::unique_ptr<ChooserController> chooser_controller);
31 ~ChooserBubbleUiView() override;
32
33 // BubbleUi:
34 void Show(BubbleReference bubble_reference) override;
35 void Close() override;
36 void UpdateAnchorPosition() override;
37
38 private:
39 views::View* GetAnchorView();
40 views::BubbleBorder::Arrow GetAnchorArrow();
41
42 Browser* browser_; // Weak.
43 // Weak. Owned by its parent view.
44 ChooserBubbleUiViewDelegate* chooser_bubble_ui_view_delegate_;
45
46 DISALLOW_COPY_AND_ASSIGN(ChooserBubbleUiView);
47 };
48
49 #endif // CHROME_BROWSER_UI_VIEWS_WEBSITE_SETTINGS_CHOOSER_BUBBLE_UI_VIEW_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698