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_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 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <deque> | 9 #include <deque> |
10 #include <map> | 10 #include <map> |
(...skipping 416 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
427 virtual bool handleCurrentKeyboardEvent(); | 427 virtual bool handleCurrentKeyboardEvent(); |
428 virtual void spellCheck(const WebKit::WebString& text, | 428 virtual void spellCheck(const WebKit::WebString& text, |
429 int& offset, | 429 int& offset, |
430 int& length); | 430 int& length); |
431 virtual WebKit::WebString autoCorrectWord( | 431 virtual WebKit::WebString autoCorrectWord( |
432 const WebKit::WebString& misspelled_word); | 432 const WebKit::WebString& misspelled_word); |
433 virtual void showSpellingUI(bool show); | 433 virtual void showSpellingUI(bool show); |
434 virtual bool isShowingSpellingUI(); | 434 virtual bool isShowingSpellingUI(); |
435 virtual void updateSpellingUIWithMisspelledWord( | 435 virtual void updateSpellingUIWithMisspelledWord( |
436 const WebKit::WebString& word); | 436 const WebKit::WebString& word); |
437 virtual void continuousSpellCheckingEnabledStateChanged(); | |
438 virtual bool runFileChooser( | 437 virtual bool runFileChooser( |
439 const WebKit::WebFileChooserParams& params, | 438 const WebKit::WebFileChooserParams& params, |
440 WebKit::WebFileChooserCompletion* chooser_completion); | 439 WebKit::WebFileChooserCompletion* chooser_completion); |
441 virtual void runModalAlertDialog(WebKit::WebFrame* frame, | 440 virtual void runModalAlertDialog(WebKit::WebFrame* frame, |
442 const WebKit::WebString& message); | 441 const WebKit::WebString& message); |
443 virtual bool runModalConfirmDialog(WebKit::WebFrame* frame, | 442 virtual bool runModalConfirmDialog(WebKit::WebFrame* frame, |
444 const WebKit::WebString& message); | 443 const WebKit::WebString& message); |
445 virtual bool runModalPromptDialog(WebKit::WebFrame* frame, | 444 virtual bool runModalPromptDialog(WebKit::WebFrame* frame, |
446 const WebKit::WebString& message, | 445 const WebKit::WebString& message, |
447 const WebKit::WebString& default_value, | 446 const WebKit::WebString& default_value, |
(...skipping 605 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1053 | 1052 |
1054 GURL GetAlternateErrorPageURL(const GURL& failed_url, | 1053 GURL GetAlternateErrorPageURL(const GURL& failed_url, |
1055 ErrorPageType error_type); | 1054 ErrorPageType error_type); |
1056 | 1055 |
1057 std::string GetAltHTMLForTemplate(const DictionaryValue& error_strings, | 1056 std::string GetAltHTMLForTemplate(const DictionaryValue& error_strings, |
1058 int template_resource_id) const; | 1057 int template_resource_id) const; |
1059 | 1058 |
1060 // Locates a sub frame with given xpath | 1059 // Locates a sub frame with given xpath |
1061 WebKit::WebFrame* GetChildFrame(const std::wstring& frame_xpath) const; | 1060 WebKit::WebFrame* GetChildFrame(const std::wstring& frame_xpath) const; |
1062 | 1061 |
1063 // Gets the focused node. If no such node exists then the node will be isNull. | |
1064 WebKit::WebNode GetFocusedNode() const; | |
1065 | |
1066 DOMUIBindings* GetDOMUIBindings(); | 1062 DOMUIBindings* GetDOMUIBindings(); |
1067 | 1063 |
1068 ExternalHostBindings* GetExternalHostBindings(); | 1064 ExternalHostBindings* GetExternalHostBindings(); |
1069 | 1065 |
1070 // Should only be called if this object wraps a PluginDocument. | 1066 // Should only be called if this object wraps a PluginDocument. |
1071 WebKit::WebPlugin* GetWebPluginFromPluginDocument(); | 1067 WebKit::WebPlugin* GetWebPluginFromPluginDocument(); |
1072 | 1068 |
1073 // Decodes a data: URL image or returns an empty image in case of failure. | 1069 // Decodes a data: URL image or returns an empty image in case of failure. |
1074 SkBitmap ImageFromDataUrl(const GURL&) const; | 1070 SkBitmap ImageFromDataUrl(const GURL&) const; |
1075 | 1071 |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1119 #if defined(OS_LINUX) | 1115 #if defined(OS_LINUX) |
1120 void UpdateFontRenderingFromRendererPrefs(); | 1116 void UpdateFontRenderingFromRendererPrefs(); |
1121 #else | 1117 #else |
1122 void UpdateFontRenderingFromRendererPrefs() {} | 1118 void UpdateFontRenderingFromRendererPrefs() {} |
1123 #endif | 1119 #endif |
1124 | 1120 |
1125 // Update the target url and tell the browser that the target URL has changed. | 1121 // Update the target url and tell the browser that the target URL has changed. |
1126 // If |url| is empty, show |fallback_url|. | 1122 // If |url| is empty, show |fallback_url|. |
1127 void UpdateTargetURL(const GURL& url, const GURL& fallback_url); | 1123 void UpdateTargetURL(const GURL& url, const GURL& fallback_url); |
1128 | 1124 |
1129 // Updates the state of the toggle spell check command in the browser process. | |
1130 void UpdateToggleSpellCheckCommandState(); | |
1131 | |
1132 // Helper to add an error message to the root frame's console. | 1125 // Helper to add an error message to the root frame's console. |
1133 void AddErrorToRootConsole(const string16& message); | 1126 void AddErrorToRootConsole(const string16& message); |
1134 | 1127 |
1135 // --------------------------------------------------------------------------- | 1128 // --------------------------------------------------------------------------- |
1136 // ADDING NEW FUNCTIONS? Please keep private functions alphabetized and put | 1129 // ADDING NEW FUNCTIONS? Please keep private functions alphabetized and put |
1137 // it in the same order in the .cc file as it was in the header. | 1130 // it in the same order in the .cc file as it was in the header. |
1138 // --------------------------------------------------------------------------- | 1131 // --------------------------------------------------------------------------- |
1139 | 1132 |
1140 // Settings ------------------------------------------------------------------ | 1133 // Settings ------------------------------------------------------------------ |
1141 | 1134 |
(...skipping 348 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1490 // bunch of stuff, you should probably create a helper class and put your | 1483 // bunch of stuff, you should probably create a helper class and put your |
1491 // data and methods on that to avoid bloating RenderView more. You can use | 1484 // data and methods on that to avoid bloating RenderView more. You can use |
1492 // the Observer interface to filter IPC messages and receive frame change | 1485 // the Observer interface to filter IPC messages and receive frame change |
1493 // notifications. | 1486 // notifications. |
1494 // --------------------------------------------------------------------------- | 1487 // --------------------------------------------------------------------------- |
1495 | 1488 |
1496 DISALLOW_COPY_AND_ASSIGN(RenderView); | 1489 DISALLOW_COPY_AND_ASSIGN(RenderView); |
1497 }; | 1490 }; |
1498 | 1491 |
1499 #endif // CHROME_RENDERER_RENDER_VIEW_H_ | 1492 #endif // CHROME_RENDERER_RENDER_VIEW_H_ |
OLD | NEW |