| 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 bfd116b5320383a43eb1c89ffa9ef2ec3b96d018..ac73c06fae982d683f1b21e11df1c6adf317becb 100644
|
| --- a/ui/views/window/dialog_client_view.h
|
| +++ b/ui/views/window/dialog_client_view.h
|
| @@ -12,6 +12,9 @@
|
| #include "ui/views/window/client_view.h"
|
|
|
| namespace views {
|
| +namespace test {
|
| +class TestDialogClientView;
|
| +}
|
|
|
| class DialogDelegate;
|
| class LabelButton;
|
| @@ -66,23 +69,18 @@ class VIEWS_EXPORT DialogClientView : public ClientView,
|
|
|
| void set_minimum_size(const gfx::Size& size) { minimum_size_ = size; }
|
|
|
| - protected:
|
| - // For testing.
|
| - explicit DialogClientView(View* contents_view);
|
| + private:
|
| + friend class test::TestDialogClientView;
|
| +
|
| + bool has_dialog_buttons() const { return ok_button_ || cancel_button_; }
|
|
|
| // Returns the DialogDelegate for the window. Virtual for testing.
|
| virtual DialogDelegate* GetDialogDelegate() const;
|
|
|
| - // Create and add the extra view, if supplied by the delegate.
|
| - void CreateExtraView();
|
| -
|
| // View implementation.
|
| void ChildPreferredSizeChanged(View* child) override;
|
| void ChildVisibilityChanged(View* child) override;
|
|
|
| - private:
|
| - bool has_dialog_buttons() const { return ok_button_ || cancel_button_; }
|
| -
|
| // Create a dialog button of the appropriate type.
|
| LabelButton* CreateDialogButton(ui::DialogButton type);
|
|
|
| @@ -102,6 +100,14 @@ class VIEWS_EXPORT DialogClientView : public ClientView,
|
| // padding between them and the contents view.
|
| gfx::Insets GetButtonRowInsets() const;
|
|
|
| + // Installs and configures the LayoutManager. Does not add any views.
|
| + void SetupLayout();
|
| +
|
| + // First removes all child views, creates or deletes any buttons that are
|
| + // required. Then adds the contents view, buttons and ExtraView (if any) to
|
| + // the LayoutManager.
|
| + void SetupViews();
|
| +
|
| // 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();
|
|
|