OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 <map> | 8 #include <map> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
233 WebKit::WebFrame* frame, const WebKit::WebString& message); | 233 WebKit::WebFrame* frame, const WebKit::WebString& message); |
234 virtual bool runModalPromptDialog( | 234 virtual bool runModalPromptDialog( |
235 WebKit::WebFrame* frame, const WebKit::WebString& message, | 235 WebKit::WebFrame* frame, const WebKit::WebString& message, |
236 const WebKit::WebString& default_value, WebKit::WebString* actual_value); | 236 const WebKit::WebString& default_value, WebKit::WebString* actual_value); |
237 virtual bool runModalBeforeUnloadDialog( | 237 virtual bool runModalBeforeUnloadDialog( |
238 WebKit::WebFrame* frame, const WebKit::WebString& message); | 238 WebKit::WebFrame* frame, const WebKit::WebString& message); |
239 virtual void showContextMenu( | 239 virtual void showContextMenu( |
240 WebKit::WebFrame* frame, const WebKit::WebContextMenuData& data); | 240 WebKit::WebFrame* frame, const WebKit::WebContextMenuData& data); |
241 virtual void setStatusText(const WebKit::WebString& text); | 241 virtual void setStatusText(const WebKit::WebString& text); |
242 virtual void setMouseOverURL(const WebKit::WebURL& url); | 242 virtual void setMouseOverURL(const WebKit::WebURL& url); |
| 243 virtual void setKeyboardFocusURL(const WebKit::WebURL& url); |
243 virtual void setToolTipText( | 244 virtual void setToolTipText( |
244 const WebKit::WebString& text, WebKit::WebTextDirection hint); | 245 const WebKit::WebString& text, WebKit::WebTextDirection hint); |
245 virtual void startDragging( | 246 virtual void startDragging( |
246 const WebKit::WebPoint& from, const WebKit::WebDragData& data, | 247 const WebKit::WebPoint& from, const WebKit::WebDragData& data, |
247 WebKit::WebDragOperationsMask mask); | 248 WebKit::WebDragOperationsMask mask); |
248 virtual bool acceptsLoadDrops(); | 249 virtual bool acceptsLoadDrops(); |
249 virtual void focusNext(); | 250 virtual void focusNext(); |
250 virtual void focusPrevious(); | 251 virtual void focusPrevious(); |
251 virtual void navigateBackForwardSoon(int offset); | 252 virtual void navigateBackForwardSoon(int offset); |
252 virtual int historyBackListCount(); | 253 virtual int historyBackListCount(); |
(...skipping 473 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
726 #else | 727 #else |
727 void UpdateFontRenderingFromRendererPrefs() { } | 728 void UpdateFontRenderingFromRendererPrefs() { } |
728 #endif | 729 #endif |
729 | 730 |
730 // Inject toolstrip CSS for extension moles and toolstrips. | 731 // Inject toolstrip CSS for extension moles and toolstrips. |
731 void InjectToolstripCSS(); | 732 void InjectToolstripCSS(); |
732 | 733 |
733 // Initializes the document_tag_ member if necessary. | 734 // Initializes the document_tag_ member if necessary. |
734 void EnsureDocumentTag(); | 735 void EnsureDocumentTag(); |
735 | 736 |
| 737 // Update the target url and tell the browser that the target URL has changed. |
| 738 // If |url| is empty, show |fallback_url|. |
| 739 void UpdateTargetURL(const GURL& url, const GURL& fallback_url); |
| 740 |
736 // Bitwise-ORed set of extra bindings that have been enabled. See | 741 // Bitwise-ORed set of extra bindings that have been enabled. See |
737 // BindingsPolicy for details. | 742 // BindingsPolicy for details. |
738 int enabled_bindings_; | 743 int enabled_bindings_; |
739 | 744 |
740 // DOM Automation Controller CppBoundClass. | 745 // DOM Automation Controller CppBoundClass. |
741 DomAutomationController dom_automation_controller_; | 746 DomAutomationController dom_automation_controller_; |
742 | 747 |
743 // Chrome page<->browser messaging CppBoundClass. | 748 // Chrome page<->browser messaging CppBoundClass. |
744 DOMUIBindings dom_ui_bindings_; | 749 DOMUIBindings dom_ui_bindings_; |
745 | 750 |
746 // External host exposed through automation controller. | 751 // External host exposed through automation controller. |
747 ExternalHostBindings external_host_bindings_; | 752 ExternalHostBindings external_host_bindings_; |
748 | 753 |
749 // The last gotten main frame's encoding. | 754 // The last gotten main frame's encoding. |
750 std::string last_encoding_name_; | 755 std::string last_encoding_name_; |
751 | 756 |
752 // The URL we think the user's mouse is hovering over. We use this to | 757 // The URL we show the user in the status bar. We use this to |
753 // determine if we want to send a new one (we do not need to send | 758 // determine if we want to send a new one (we do not need to send |
754 // duplicates). | 759 // duplicates). It will be equal to either |mouse_over_url_| or |focus_url_|, |
| 760 // depending on which was updated last. |
755 GURL target_url_; | 761 GURL target_url_; |
| 762 // The URL the user's mouse is hovering over. |
| 763 GURL mouse_over_url_; |
| 764 // The URL that has keyboard focus. |
| 765 GURL focus_url_; |
756 | 766 |
757 // The state of our target_url transmissions. When we receive a request to | 767 // The state of our target_url transmissions. When we receive a request to |
758 // send a URL to the browser, we set this to TARGET_INFLIGHT until an ACK | 768 // send a URL to the browser, we set this to TARGET_INFLIGHT until an ACK |
759 // comes back - if a new request comes in before the ACK, we store the new | 769 // comes back - if a new request comes in before the ACK, we store the new |
760 // URL in pending_target_url_ and set the status to TARGET_PENDING. If an | 770 // URL in pending_target_url_ and set the status to TARGET_PENDING. If an |
761 // ACK comes back and we are in TARGET_PENDING, we send the stored URL and | 771 // ACK comes back and we are in TARGET_PENDING, we send the stored URL and |
762 // revert to TARGET_INFLIGHT. | 772 // revert to TARGET_INFLIGHT. |
763 // | 773 // |
764 // We don't need a queue of URLs to send, as only the latest is useful. | 774 // We don't need a queue of URLs to send, as only the latest is useful. |
765 enum { | 775 enum { |
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
983 // ImageResourceFetchers schedule via DownloadImage. | 993 // ImageResourceFetchers schedule via DownloadImage. |
984 typedef std::set<webkit_glue::ImageResourceFetcher*> ImageResourceFetcherSet; | 994 typedef std::set<webkit_glue::ImageResourceFetcher*> ImageResourceFetcherSet; |
985 ImageResourceFetcherSet image_fetchers_; | 995 ImageResourceFetcherSet image_fetchers_; |
986 | 996 |
987 typedef std::map<WebKit::WebView*, RenderView*> ViewMap; | 997 typedef std::map<WebKit::WebView*, RenderView*> ViewMap; |
988 | 998 |
989 DISALLOW_COPY_AND_ASSIGN(RenderView); | 999 DISALLOW_COPY_AND_ASSIGN(RenderView); |
990 }; | 1000 }; |
991 | 1001 |
992 #endif // CHROME_RENDERER_RENDER_VIEW_H_ | 1002 #endif // CHROME_RENDERER_RENDER_VIEW_H_ |
OLD | NEW |