OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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_JSMESSAGE_BOX_HANDLER_H__ | 5 #ifndef CHROME_BROWSER_JSMESSAGE_BOX_HANDLER_H__ |
6 #define CHROME_BROWSER_JSMESSAGE_BOX_HANDLER_H__ | 6 #define CHROME_BROWSER_JSMESSAGE_BOX_HANDLER_H__ |
7 | 7 |
8 #include "chrome/common/ipc_message.h" | 8 #include "chrome/common/ipc_message.h" |
9 #include "chrome/views/app_modal_dialog_delegate.h" | 9 #include "chrome/views/app_modal_dialog_delegate.h" |
10 #include "chrome/common/notification_service.h" | 10 #include "chrome/common/notification_service.h" |
(...skipping 29 matching lines...) Expand all Loading... |
40 virtual bool Cancel(); | 40 virtual bool Cancel(); |
41 virtual bool Accept(); | 41 virtual bool Accept(); |
42 | 42 |
43 // views::AppModalDialogDelegate | 43 // views::AppModalDialogDelegate |
44 virtual void ShowModalDialog(); | 44 virtual void ShowModalDialog(); |
45 virtual void ActivateModalDialog(); | 45 virtual void ActivateModalDialog(); |
46 | 46 |
47 // views::WindowDelegate Methods: | 47 // views::WindowDelegate Methods: |
48 virtual bool IsModal() const { return true; } | 48 virtual bool IsModal() const { return true; } |
49 virtual views::View* GetContentsView(); | 49 virtual views::View* GetContentsView(); |
| 50 virtual views::View* GetInitiallyFocusedView() const; |
50 | 51 |
51 protected: | 52 protected: |
52 // Use RunJavaScriptMessageBox to use. | 53 // Use RunJavaScriptMessageBox to use. |
53 JavascriptMessageBoxHandler(WebContents* web_contents, | 54 JavascriptMessageBoxHandler(WebContents* web_contents, |
54 int dialog_flags, | 55 int dialog_flags, |
55 const std::wstring& message_text, | 56 const std::wstring& message_text, |
56 const std::wstring& default_prompt_text, | 57 const std::wstring& default_prompt_text, |
57 bool display_suppress_checkbox, | 58 bool display_suppress_checkbox, |
58 IPC::Message* reply_msg); | 59 IPC::Message* reply_msg); |
59 | 60 |
(...skipping 17 matching lines...) Expand all Loading... |
77 int dialog_flags_; | 78 int dialog_flags_; |
78 | 79 |
79 // The dialog if it is currently visible. | 80 // The dialog if it is currently visible. |
80 views::Window* dialog_; | 81 views::Window* dialog_; |
81 | 82 |
82 DISALLOW_EVIL_CONSTRUCTORS(JavascriptMessageBoxHandler); | 83 DISALLOW_EVIL_CONSTRUCTORS(JavascriptMessageBoxHandler); |
83 }; | 84 }; |
84 | 85 |
85 #endif // CHROME_BROWSER_JSMESSAGE_BOX_HANDLER_H__ | 86 #endif // CHROME_BROWSER_JSMESSAGE_BOX_HANDLER_H__ |
86 | 87 |
OLD | NEW |