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

Side by Side Diff: chrome/browser/ui/views/chooser_content_view.h

Issue 2029863002: Refactor ChooserBubbleUiViewDelegate (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: updated test code Created 4 years, 6 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 2016 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_CHOOSER_CONTENT_VIEW_H_
6 #define CHROME_BROWSER_UI_VIEWS_CHOOSER_CONTENT_VIEW_H_
7
8 #include <memory>
9
10 #include "base/macros.h"
11 #include "base/strings/string16.h"
12 #include "ui/base/ui_base_types.h"
13
14 class ChooserController;
15 class ChooserTableModel;
16
17 namespace ui {
18 class TableModel;
19 }
20
21 namespace views {
22 class StyledLabel;
23 class StyledLabelListener;
24 class TableView;
25 class TableViewObserver;
26 }
27
28 // A bubble or dialog view for choosing among several options in a table.
29 // Used for WebUSB/WebBluetooth device selection for Chrome and extensions.
30 class ChooserContentView {
31 public:
32 ChooserContentView(views::TableViewObserver* observer,
33 ChooserController* chooser_controller);
34 ~ChooserContentView();
msw 2016/06/08 00:58:45 nit: "= default;"?
juncai 2016/06/09 01:59:21 Changed ChooserContentView to be a subclass of vie
35
36 base::string16 GetDialogButtonLabel(ui::DialogButton button) const;
37 bool IsDialogButtonEnabled(ui::DialogButton button) const;
38 // The returned view is owned by its parent view.
msw 2016/06/08 00:58:45 nit: remove this comment or say "Ownership of the
juncai 2016/06/09 01:59:21 Done.
39 views::StyledLabel* CreateFootnoteView(
40 views::StyledLabelListener* listener) const;
41
42 views::TableView* table_view() const { return table_view_; }
43
44 private:
45 // |table_view_| is not owned by this class, it is owned by its parent view.
msw 2016/06/08 00:58:45 nit: remove this comment; that's standard behavior
juncai 2016/06/09 01:59:21 Done.
46 views::TableView* table_view_;
47 std::unique_ptr<ChooserTableModel> chooser_table_model_;
48 DISALLOW_COPY_AND_ASSIGN(ChooserContentView);
msw 2016/06/08 00:58:45 nit: add a blank line above
juncai 2016/06/09 01:59:21 Done.
49 };
50
51 #endif // CHROME_BROWSER_UI_VIEWS_CHOOSER_CONTENT_VIEW_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/views/chooser_content_view.cc » ('j') | chrome/browser/ui/views/chooser_content_view.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698