OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_CHROMEOS_LOGIN_LOGIN_HTML_DIALOG_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_LOGIN_HTML_DIALOG_H_ |
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_LOGIN_HTML_DIALOG_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_LOGIN_HTML_DIALOG_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 | 48 |
49 // Overrides default width/height for dialog. | 49 // Overrides default width/height for dialog. |
50 void SetDialogSize(int width, int height); | 50 void SetDialogSize(int width, int height); |
51 | 51 |
52 void set_url(const GURL& url) { url_ = url; } | 52 void set_url(const GURL& url) { url_ = url; } |
53 | 53 |
54 bool is_open() const { return is_open_; } | 54 bool is_open() const { return is_open_; } |
55 | 55 |
56 protected: | 56 protected: |
57 // HtmlDialogUIDelegate implementation. | 57 // HtmlDialogUIDelegate implementation. |
58 virtual bool IsDialogModal() const; | 58 virtual bool IsDialogModal() const OVERRIDE; |
59 virtual std::wstring GetDialogTitle() const; | 59 virtual std::wstring GetDialogTitle() const OVERRIDE; |
60 virtual GURL GetDialogContentURL() const; | 60 virtual GURL GetDialogContentURL() const OVERRIDE; |
61 virtual void GetWebUIMessageHandlers( | 61 virtual void GetWebUIMessageHandlers( |
62 std::vector<WebUIMessageHandler*>* handlers) const; | 62 std::vector<WebUIMessageHandler*>* handlers) const OVERRIDE; |
63 virtual void GetDialogSize(gfx::Size* size) const; | 63 virtual void GetDialogSize(gfx::Size* size) const OVERRIDE; |
64 virtual std::string GetDialogArgs() const; | 64 virtual std::string GetDialogArgs() const OVERRIDE; |
65 virtual void OnDialogClosed(const std::string& json_retval); | 65 virtual void OnDialogClosed(const std::string& json_retval) OVERRIDE; |
66 virtual void OnCloseContents(TabContents* source, bool* out_close_dialog); | 66 virtual void OnCloseContents( |
67 virtual bool ShouldShowDialogTitle() const; | 67 TabContents* source, bool* out_close_dialog) OVERRIDE; |
| 68 virtual bool ShouldShowDialogTitle() const OVERRIDE; |
| 69 virtual bool HandleContextMenu(const ContextMenuParams& params) OVERRIDE; |
68 | 70 |
69 // NotificationObserver implementation. | 71 // NotificationObserver implementation. |
70 virtual void Observe(NotificationType type, | 72 virtual void Observe(NotificationType type, |
71 const NotificationSource& source, | 73 const NotificationSource& source, |
72 const NotificationDetails& details); | 74 const NotificationDetails& details); |
73 | 75 |
74 private: | 76 private: |
75 // Notifications receiver. | 77 // Notifications receiver. |
76 Delegate* delegate_; | 78 Delegate* delegate_; |
77 | 79 |
78 gfx::NativeWindow parent_window_; | 80 gfx::NativeWindow parent_window_; |
79 std::wstring title_; | 81 std::wstring title_; |
80 GURL url_; | 82 GURL url_; |
81 Style style_; | 83 Style style_; |
82 NotificationRegistrar notification_registrar_; | 84 NotificationRegistrar notification_registrar_; |
83 BubbleFrameView* bubble_frame_view_; | 85 BubbleFrameView* bubble_frame_view_; |
84 bool is_open_; | 86 bool is_open_; |
85 | 87 |
86 // Dialog display size. | 88 // Dialog display size. |
87 int width_; | 89 int width_; |
88 int height_; | 90 int height_; |
89 | 91 |
90 DISALLOW_COPY_AND_ASSIGN(LoginHtmlDialog); | 92 DISALLOW_COPY_AND_ASSIGN(LoginHtmlDialog); |
91 }; | 93 }; |
92 | 94 |
93 } // namespace chromeos | 95 } // namespace chromeos |
94 | 96 |
95 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_LOGIN_HTML_DIALOG_H_ | 97 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_LOGIN_HTML_DIALOG_H_ |
OLD | NEW |