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

Unified Diff: ui/views/window/dialog_client_view.h

Issue 2654323002: harmony: convert device chooser (Closed)
Patch Set: nits Created 3 years, 10 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
« no previous file with comments | « chrome/browser/ui/views/extensions/chooser_dialog_view.cc ('k') | ui/views/window/dialog_client_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/window/dialog_client_view.h
diff --git a/ui/views/window/dialog_client_view.h b/ui/views/window/dialog_client_view.h
index 1d2b3de3b92d455dd4d486c9552c7fdec7125eb2..907f378bb69cbb871f83febb679c153ccb4c9859 100644
--- a/ui/views/window/dialog_client_view.h
+++ b/ui/views/window/dialog_client_view.h
@@ -64,6 +64,8 @@ class VIEWS_EXPORT DialogClientView : public ClientView,
button_row_insets_ = insets;
}
+ void set_minimum_size(const gfx::Size& size) { minimum_size_ = size; }
+
protected:
// For testing.
explicit DialogClientView(View* contents_view);
@@ -103,25 +105,29 @@ class VIEWS_EXPORT DialogClientView : public ClientView,
// buttons/extra view.
int GetButtonsAndExtraViewRowTopPadding() const;
- // How much to inset the button row.
- gfx::Insets button_row_insets_;
-
// Sets up the focus chain for the child views. This is required since the
// delegate may choose to add/remove views at any time.
void SetupFocusChain();
+ // How much to inset the button row.
+ gfx::Insets button_row_insets_;
+
+ // The minimum size of this dialog, regardless of the size of its content
+ // view. If this is equal to gfx::Size(), no minimum size is imposed.
sky 2017/02/08 17:10:52 optional: I would remove the last sentence as an e
+ gfx::Size minimum_size_ = gfx::Size();
sky 2017/02/08 17:10:52 Remove the = here. The empty constructor is the sa
+
// The dialog buttons.
- LabelButton* ok_button_;
- LabelButton* cancel_button_;
+ LabelButton* ok_button_ = nullptr;
+ LabelButton* cancel_button_ = nullptr;
// The extra view shown in the row of buttons; may be NULL.
- View* extra_view_;
+ View* extra_view_ = nullptr;
// True if we've notified the delegate the window is closing and the delegate
// allowed the close. In some situations it's possible to get two closes (see
// http://crbug.com/71940). This is used to avoid notifying the delegate
// twice, which can have bad consequences.
- bool delegate_allowed_close_;
+ bool delegate_allowed_close_ = false;
DISALLOW_COPY_AND_ASSIGN(DialogClientView);
};
« no previous file with comments | « chrome/browser/ui/views/extensions/chooser_dialog_view.cc ('k') | ui/views/window/dialog_client_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698