| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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_UI_VIEWS_SETTINGS_RESET_PROMPT_DIALOG_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_SETTINGS_RESET_PROMPT_DIALOG_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_SETTINGS_RESET_PROMPT_DIALOG_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_SETTINGS_RESET_PROMPT_DIALOG_H_ |
| 7 | 7 |
| 8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 #include "base/strings/string16.h" | 9 #include "base/strings/string16.h" |
| 10 #include "ui/base/ui_base_types.h" | 10 #include "ui/base/ui_base_types.h" |
| (...skipping 21 matching lines...) Expand all Loading... |
| 32 safe_browsing::SettingsResetPromptController* controller); | 32 safe_browsing::SettingsResetPromptController* controller); |
| 33 ~SettingsResetPromptDialog() override; | 33 ~SettingsResetPromptDialog() override; |
| 34 | 34 |
| 35 void Show(Browser* browser); | 35 void Show(Browser* browser); |
| 36 | 36 |
| 37 // views::WidgetDelegate overrides. | 37 // views::WidgetDelegate overrides. |
| 38 ui::ModalType GetModalType() const override; | 38 ui::ModalType GetModalType() const override; |
| 39 bool ShouldShowWindowIcon() const override; | 39 bool ShouldShowWindowIcon() const override; |
| 40 base::string16 GetWindowTitle() const override; | 40 base::string16 GetWindowTitle() const override; |
| 41 | 41 |
| 42 // ui::DialogModel overrides. | |
| 43 bool ShouldDefaultButtonBeBlue() const override; | |
| 44 | |
| 45 // views::DialogDelegate overrides. | 42 // views::DialogDelegate overrides. |
| 46 base::string16 GetDialogButtonLabel(ui::DialogButton button) const override; | 43 base::string16 GetDialogButtonLabel(ui::DialogButton button) const override; |
| 47 bool Accept() override; | 44 bool Accept() override; |
| 48 bool Cancel() override; | 45 bool Cancel() override; |
| 49 // We override |Close()| because we want to distinguish in our metrics between | 46 // We override |Close()| because we want to distinguish in our metrics between |
| 50 // users clicking the cancel button versus dismissing the dialog in other | 47 // users clicking the cancel button versus dismissing the dialog in other |
| 51 // ways. | 48 // ways. |
| 52 bool Close() override; | 49 bool Close() override; |
| 53 | 50 |
| 54 // views::View overrides. | 51 // views::View overrides. |
| 55 gfx::Size CalculatePreferredSize() const override; | 52 gfx::Size CalculatePreferredSize() const override; |
| 56 | 53 |
| 57 private: | 54 private: |
| 58 Browser* browser_; | 55 Browser* browser_; |
| 59 safe_browsing::SettingsResetPromptController* controller_; | 56 safe_browsing::SettingsResetPromptController* controller_; |
| 60 | 57 |
| 61 DISALLOW_COPY_AND_ASSIGN(SettingsResetPromptDialog); | 58 DISALLOW_COPY_AND_ASSIGN(SettingsResetPromptDialog); |
| 62 }; | 59 }; |
| 63 | 60 |
| 64 #endif // CHROME_BROWSER_UI_VIEWS_SETTINGS_RESET_PROMPT_DIALOG_H_ | 61 #endif // CHROME_BROWSER_UI_VIEWS_SETTINGS_RESET_PROMPT_DIALOG_H_ |
| OLD | NEW |