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_RENDERER_RENDER_VIEW_H_ | 5 #ifndef CHROME_RENDERER_RENDER_VIEW_H_ |
6 #define CHROME_RENDERER_RENDER_VIEW_H_ | 6 #define CHROME_RENDERER_RENDER_VIEW_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 const std::wstring& message); | 120 const std::wstring& message); |
121 virtual bool RunJavaScriptConfirm(WebView* webview, | 121 virtual bool RunJavaScriptConfirm(WebView* webview, |
122 const std::wstring& message); | 122 const std::wstring& message); |
123 virtual bool RunJavaScriptPrompt(WebView* webview, | 123 virtual bool RunJavaScriptPrompt(WebView* webview, |
124 const std::wstring& message, | 124 const std::wstring& message, |
125 const std::wstring& default_value, | 125 const std::wstring& default_value, |
126 std::wstring* result); | 126 std::wstring* result); |
127 virtual bool RunBeforeUnloadConfirm(WebView* webview, | 127 virtual bool RunBeforeUnloadConfirm(WebView* webview, |
128 const std::wstring& message); | 128 const std::wstring& message); |
129 virtual void OnUnloadListenerChanged(WebView* webview, WebFrame* webframe); | 129 virtual void OnUnloadListenerChanged(WebView* webview, WebFrame* webframe); |
| 130 virtual void QueryFormFieldAutofill(const std::wstring& field_name, |
| 131 const std::wstring& text, |
| 132 int64 node_id); |
130 virtual void UpdateTargetURL(WebView* webview, | 133 virtual void UpdateTargetURL(WebView* webview, |
131 const GURL& url); | 134 const GURL& url); |
132 virtual void RunFileChooser(const std::wstring& default_filename, | 135 virtual void RunFileChooser(const std::wstring& default_filename, |
133 WebFileChooserCallback* file_chooser); | 136 WebFileChooserCallback* file_chooser); |
134 virtual void AddMessageToConsole(WebView* webview, | 137 virtual void AddMessageToConsole(WebView* webview, |
135 const std::wstring& message, | 138 const std::wstring& message, |
136 unsigned int line_no, | 139 unsigned int line_no, |
137 const std::wstring& source_id); | 140 const std::wstring& source_id); |
138 | 141 |
139 virtual void DebuggerOutput(const std::wstring& out); | 142 virtual void DebuggerOutput(const std::wstring& out); |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
190 virtual void WindowObjectCleared(WebFrame* webframe); | 193 virtual void WindowObjectCleared(WebFrame* webframe); |
191 virtual WindowOpenDisposition DispositionForNavigationAction( | 194 virtual WindowOpenDisposition DispositionForNavigationAction( |
192 WebView* webview, | 195 WebView* webview, |
193 WebFrame* frame, | 196 WebFrame* frame, |
194 const WebRequest* request, | 197 const WebRequest* request, |
195 WebNavigationType type, | 198 WebNavigationType type, |
196 WindowOpenDisposition disposition, | 199 WindowOpenDisposition disposition, |
197 bool is_redirect); | 200 bool is_redirect); |
198 | 201 |
199 virtual WebView* CreateWebView(WebView* webview, bool user_gesture); | 202 virtual WebView* CreateWebView(WebView* webview, bool user_gesture); |
200 virtual WebWidget* CreatePopupWidget(WebView* webview); | 203 virtual WebWidget* CreatePopupWidget(WebView* webview, |
| 204 bool focus_on_show); |
201 virtual WebPluginDelegate* CreatePluginDelegate( | 205 virtual WebPluginDelegate* CreatePluginDelegate( |
202 WebView* webview, | 206 WebView* webview, |
203 const GURL& url, | 207 const GURL& url, |
204 const std::string& mime_type, | 208 const std::string& mime_type, |
205 const std::string& clsid, | 209 const std::string& clsid, |
206 std::string* actual_mime_type); | 210 std::string* actual_mime_type); |
207 virtual void OnMissingPluginStatus(WebPluginDelegate* delegate, int status); | 211 virtual void OnMissingPluginStatus(WebPluginDelegate* delegate, int status); |
208 virtual void OpenURL(WebView* webview, const GURL& url, | 212 virtual void OpenURL(WebView* webview, const GURL& url, |
209 const GURL& referrer, | 213 const GURL& referrer, |
210 WindowOpenDisposition disposition); | 214 WindowOpenDisposition disposition); |
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
450 // sends ViewMsg_ShouldClose to the browser. | 454 // sends ViewMsg_ShouldClose to the browser. |
451 void OnMsgShouldClose(); | 455 void OnMsgShouldClose(); |
452 | 456 |
453 // Runs the onunload handler and closes the page, replying with ClosePage_ACK | 457 // Runs the onunload handler and closes the page, replying with ClosePage_ACK |
454 // (with the given RPH and request IDs, to help track the request). | 458 // (with the given RPH and request IDs, to help track the request). |
455 void OnClosePage(int new_render_process_host_id, int new_request_id); | 459 void OnClosePage(int new_render_process_host_id, int new_request_id); |
456 | 460 |
457 // Notification about ui theme changes. | 461 // Notification about ui theme changes. |
458 void OnThemeChanged(); | 462 void OnThemeChanged(); |
459 | 463 |
| 464 // Notification that we have received autofill suggestion. |
| 465 void OnReceivedAutofillSuggestions( |
| 466 int64 node_id, |
| 467 int request_id, |
| 468 const std::vector<std::wstring> suggestions, |
| 469 int default_suggestion_index); |
| 470 |
460 #ifdef CHROME_PERSONALIZATION | 471 #ifdef CHROME_PERSONALIZATION |
461 void OnPersonalizationEvent(std::string event_name, std::string event_args); | 472 void OnPersonalizationEvent(std::string event_name, std::string event_args); |
462 #endif | 473 #endif |
463 | 474 |
464 // Handles messages posted from automation. | 475 // Handles messages posted from automation. |
465 void OnMessageFromExternalHost(const std::string& target, | 476 void OnMessageFromExternalHost(const std::string& target, |
466 const std::string& message); | 477 const std::string& message); |
467 | 478 |
468 // Message that we should no longer be part of the current popup window | 479 // Message that we should no longer be part of the current popup window |
469 // grouping, and should form our own grouping. | 480 // grouping, and should form our own grouping. |
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
666 // True if Greasemonkey is enabled in this process. | 677 // True if Greasemonkey is enabled in this process. |
667 bool greasemonkey_enabled_; | 678 bool greasemonkey_enabled_; |
668 | 679 |
669 // Resource message queue. Used to queue up resource IPCs if we need | 680 // Resource message queue. Used to queue up resource IPCs if we need |
670 // to wait for an ACK from the browser before proceeding. | 681 // to wait for an ACK from the browser before proceeding. |
671 std::queue<IPC::Message*> queued_resource_messages_; | 682 std::queue<IPC::Message*> queued_resource_messages_; |
672 | 683 |
673 // Set if we are waiting for an ack for ViewHostMsg_CreateWindow | 684 // Set if we are waiting for an ack for ViewHostMsg_CreateWindow |
674 bool waiting_for_create_window_ack_; | 685 bool waiting_for_create_window_ack_; |
675 | 686 |
| 687 // The id of the last request sent for form field autofill. Used to ignore |
| 688 // out of date responses. |
| 689 int form_field_autofill_request_id_; |
| 690 |
676 // A cached WebHistoryItem used for back/forward navigations initiated by | 691 // A cached WebHistoryItem used for back/forward navigations initiated by |
677 // WebCore (via the window.history.go API). We only have one such navigation | 692 // WebCore (via the window.history.go API). We only have one such navigation |
678 // pending at a time. | 693 // pending at a time. |
679 scoped_refptr<WebHistoryItem> history_navigation_item_; | 694 scoped_refptr<WebHistoryItem> history_navigation_item_; |
680 | 695 |
681 DISALLOW_COPY_AND_ASSIGN(RenderView); | 696 DISALLOW_COPY_AND_ASSIGN(RenderView); |
682 }; | 697 }; |
683 | 698 |
684 #endif // CHROME_RENDERER_RENDER_VIEW_H_ | 699 #endif // CHROME_RENDERER_RENDER_VIEW_H_ |
OLD | NEW |