| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ |
| 6 #define CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ | 6 #define CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 #include <map> | 9 #include <map> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 77 class SkBitmap; | 77 class SkBitmap; |
| 78 struct PP_NetAddress_Private; | 78 struct PP_NetAddress_Private; |
| 79 struct ViewMsg_Navigate_Params; | 79 struct ViewMsg_Navigate_Params; |
| 80 struct ViewMsg_PostMessage_Params; | 80 struct ViewMsg_PostMessage_Params; |
| 81 struct ViewMsg_StopFinding_Params; | 81 struct ViewMsg_StopFinding_Params; |
| 82 | 82 |
| 83 namespace ui { | 83 namespace ui { |
| 84 struct SelectedFileInfo; | 84 struct SelectedFileInfo; |
| 85 } // namespace ui | 85 } // namespace ui |
| 86 | 86 |
| 87 namespace WebKit { | 87 namespace blink { |
| 88 class WebApplicationCacheHost; | 88 class WebApplicationCacheHost; |
| 89 class WebApplicationCacheHostClient; | 89 class WebApplicationCacheHostClient; |
| 90 class WebDOMMessageEvent; | 90 class WebDOMMessageEvent; |
| 91 class WebDataSource; | 91 class WebDataSource; |
| 92 class WebDateTimeChooserCompletion; | 92 class WebDateTimeChooserCompletion; |
| 93 class WebDragData; | 93 class WebDragData; |
| 94 class WebGeolocationClient; | 94 class WebGeolocationClient; |
| 95 class WebGestureEvent; | 95 class WebGestureEvent; |
| 96 class WebIconURL; | 96 class WebIconURL; |
| 97 class WebImage; | 97 class WebImage; |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 169 class RendererMediaPlayerManager; | 169 class RendererMediaPlayerManager; |
| 170 class WebMediaPlayerProxyAndroid; | 170 class WebMediaPlayerProxyAndroid; |
| 171 #endif | 171 #endif |
| 172 | 172 |
| 173 // | 173 // |
| 174 // RenderView is an object that manages a WebView object, and provides a | 174 // RenderView is an object that manages a WebView object, and provides a |
| 175 // communication interface with an embedding application process | 175 // communication interface with an embedding application process |
| 176 // | 176 // |
| 177 class CONTENT_EXPORT RenderViewImpl | 177 class CONTENT_EXPORT RenderViewImpl |
| 178 : public RenderWidget, | 178 : public RenderWidget, |
| 179 NON_EXPORTED_BASE(public WebKit::WebViewClient), | 179 NON_EXPORTED_BASE(public blink::WebViewClient), |
| 180 NON_EXPORTED_BASE(public WebKit::WebFrameClient), | 180 NON_EXPORTED_BASE(public blink::WebFrameClient), |
| 181 NON_EXPORTED_BASE(public WebKit::WebPageSerializerClient), | 181 NON_EXPORTED_BASE(public blink::WebPageSerializerClient), |
| 182 public RenderView, | 182 public RenderView, |
| 183 NON_EXPORTED_BASE(public WebMediaPlayerDelegate), | 183 NON_EXPORTED_BASE(public WebMediaPlayerDelegate), |
| 184 public base::SupportsWeakPtr<RenderViewImpl> { | 184 public base::SupportsWeakPtr<RenderViewImpl> { |
| 185 public: | 185 public: |
| 186 // Creates a new RenderView. |opener_id| is the routing ID of the RenderView | 186 // Creates a new RenderView. |opener_id| is the routing ID of the RenderView |
| 187 // responsible for creating this RenderView. | 187 // responsible for creating this RenderView. |
| 188 static RenderViewImpl* Create( | 188 static RenderViewImpl* Create( |
| 189 int32 opener_id, | 189 int32 opener_id, |
| 190 const RendererPreferences& renderer_prefs, | 190 const RendererPreferences& renderer_prefs, |
| 191 const WebPreferences& webkit_prefs, | 191 const WebPreferences& webkit_prefs, |
| 192 int32 routing_id, | 192 int32 routing_id, |
| 193 int32 main_frame_routing_id, | 193 int32 main_frame_routing_id, |
| 194 int32 surface_id, | 194 int32 surface_id, |
| 195 int64 session_storage_namespace_id, | 195 int64 session_storage_namespace_id, |
| 196 const string16& frame_name, | 196 const string16& frame_name, |
| 197 bool is_renderer_created, | 197 bool is_renderer_created, |
| 198 bool swapped_out, | 198 bool swapped_out, |
| 199 bool hidden, | 199 bool hidden, |
| 200 int32 next_page_id, | 200 int32 next_page_id, |
| 201 const WebKit::WebScreenInfo& screen_info, | 201 const blink::WebScreenInfo& screen_info, |
| 202 AccessibilityMode accessibility_mode, | 202 AccessibilityMode accessibility_mode, |
| 203 bool allow_partial_swap); | 203 bool allow_partial_swap); |
| 204 | 204 |
| 205 // Used by content_layouttest_support to hook into the creation of | 205 // Used by content_layouttest_support to hook into the creation of |
| 206 // RenderViewImpls. | 206 // RenderViewImpls. |
| 207 static void InstallCreateHook( | 207 static void InstallCreateHook( |
| 208 RenderViewImpl* (*create_render_view_impl)(RenderViewImplParams*)); | 208 RenderViewImpl* (*create_render_view_impl)(RenderViewImplParams*)); |
| 209 | 209 |
| 210 // Returns the RenderViewImpl containing the given WebView. | 210 // Returns the RenderViewImpl containing the given WebView. |
| 211 static RenderViewImpl* FromWebView(WebKit::WebView* webview); | 211 static RenderViewImpl* FromWebView(blink::WebView* webview); |
| 212 | 212 |
| 213 // Returns the RenderViewImpl for the given routing ID. | 213 // Returns the RenderViewImpl for the given routing ID. |
| 214 static RenderViewImpl* FromRoutingID(int routing_id); | 214 static RenderViewImpl* FromRoutingID(int routing_id); |
| 215 | 215 |
| 216 // May return NULL when the view is closing. | 216 // May return NULL when the view is closing. |
| 217 WebKit::WebView* webview() const; | 217 blink::WebView* webview() const; |
| 218 | 218 |
| 219 int history_list_offset() const { return history_list_offset_; } | 219 int history_list_offset() const { return history_list_offset_; } |
| 220 | 220 |
| 221 const WebPreferences& webkit_preferences() const { | 221 const WebPreferences& webkit_preferences() const { |
| 222 return webkit_preferences_; | 222 return webkit_preferences_; |
| 223 } | 223 } |
| 224 | 224 |
| 225 void set_send_content_state_immediately(bool value) { | 225 void set_send_content_state_immediately(bool value) { |
| 226 send_content_state_immediately_ = value; | 226 send_content_state_immediately_ = value; |
| 227 } | 227 } |
| (...skipping 21 matching lines...) Expand all Loading... |
| 249 return stats_collection_observer_.get(); | 249 return stats_collection_observer_.get(); |
| 250 } | 250 } |
| 251 | 251 |
| 252 // Adds the given file chooser request to the file_chooser_completion_ queue | 252 // Adds the given file chooser request to the file_chooser_completion_ queue |
| 253 // (see that var for more) and requests the chooser be displayed if there are | 253 // (see that var for more) and requests the chooser be displayed if there are |
| 254 // no other waiting items in the queue. | 254 // no other waiting items in the queue. |
| 255 // | 255 // |
| 256 // Returns true if the chooser was successfully scheduled. False means we | 256 // Returns true if the chooser was successfully scheduled. False means we |
| 257 // didn't schedule anything. | 257 // didn't schedule anything. |
| 258 bool ScheduleFileChooser(const FileChooserParams& params, | 258 bool ScheduleFileChooser(const FileChooserParams& params, |
| 259 WebKit::WebFileChooserCompletion* completion); | 259 blink::WebFileChooserCompletion* completion); |
| 260 | 260 |
| 261 void LoadNavigationErrorPage( | 261 void LoadNavigationErrorPage( |
| 262 WebKit::WebFrame* frame, | 262 blink::WebFrame* frame, |
| 263 const WebKit::WebURLRequest& failed_request, | 263 const blink::WebURLRequest& failed_request, |
| 264 const WebKit::WebURLError& error, | 264 const blink::WebURLError& error, |
| 265 const std::string& html, | 265 const std::string& html, |
| 266 bool replace); | 266 bool replace); |
| 267 | 267 |
| 268 // Plugin-related functions -------------------------------------------------- | 268 // Plugin-related functions -------------------------------------------------- |
| 269 | 269 |
| 270 #if defined(ENABLE_PLUGINS) | 270 #if defined(ENABLE_PLUGINS) |
| 271 // Indicates that the given instance has been created. | 271 // Indicates that the given instance has been created. |
| 272 void PepperInstanceCreated(PepperPluginInstanceImpl* instance); | 272 void PepperInstanceCreated(PepperPluginInstanceImpl* instance); |
| 273 | 273 |
| 274 // Indicates that the given instance is being destroyed. This is called from | 274 // Indicates that the given instance is being destroyed. This is called from |
| 275 // the destructor, so it's important that the instance is not dereferenced | 275 // the destructor, so it's important that the instance is not dereferenced |
| 276 // from this call. | 276 // from this call. |
| 277 void PepperInstanceDeleted(PepperPluginInstanceImpl* instance); | 277 void PepperInstanceDeleted(PepperPluginInstanceImpl* instance); |
| 278 | 278 |
| 279 // Notifies that |instance| has changed the cursor. | 279 // Notifies that |instance| has changed the cursor. |
| 280 // This will update the cursor appearance if it is currently over the plugin | 280 // This will update the cursor appearance if it is currently over the plugin |
| 281 // instance. | 281 // instance. |
| 282 void PepperDidChangeCursor(PepperPluginInstanceImpl* instance, | 282 void PepperDidChangeCursor(PepperPluginInstanceImpl* instance, |
| 283 const WebKit::WebCursorInfo& cursor); | 283 const blink::WebCursorInfo& cursor); |
| 284 | 284 |
| 285 // Notifies that |instance| has received a mouse event. | 285 // Notifies that |instance| has received a mouse event. |
| 286 void PepperDidReceiveMouseEvent(PepperPluginInstanceImpl* instance); | 286 void PepperDidReceiveMouseEvent(PepperPluginInstanceImpl* instance); |
| 287 | 287 |
| 288 // Notification that the given plugin is focused or unfocused. | 288 // Notification that the given plugin is focused or unfocused. |
| 289 void PepperFocusChanged(PepperPluginInstanceImpl* instance, bool focused); | 289 void PepperFocusChanged(PepperPluginInstanceImpl* instance, bool focused); |
| 290 | 290 |
| 291 // Informs the render view that a PPAPI plugin has changed text input status. | 291 // Informs the render view that a PPAPI plugin has changed text input status. |
| 292 void PepperTextInputTypeChanged(PepperPluginInstanceImpl* instance); | 292 void PepperTextInputTypeChanged(PepperPluginInstanceImpl* instance); |
| 293 void PepperCaretPositionChanged(PepperPluginInstanceImpl* instance); | 293 void PepperCaretPositionChanged(PepperPluginInstanceImpl* instance); |
| (...skipping 16 matching lines...) Expand all Loading... |
| 310 | 310 |
| 311 bool IsPepperAcceptingCompositionEvents() const; | 311 bool IsPepperAcceptingCompositionEvents() const; |
| 312 | 312 |
| 313 // Notification that the given plugin has crashed. | 313 // Notification that the given plugin has crashed. |
| 314 void PluginCrashed(const base::FilePath& plugin_path, | 314 void PluginCrashed(const base::FilePath& plugin_path, |
| 315 base::ProcessId plugin_pid); | 315 base::ProcessId plugin_pid); |
| 316 | 316 |
| 317 // Simulates IME events for testing purpose. | 317 // Simulates IME events for testing purpose. |
| 318 void SimulateImeSetComposition( | 318 void SimulateImeSetComposition( |
| 319 const string16& text, | 319 const string16& text, |
| 320 const std::vector<WebKit::WebCompositionUnderline>& underlines, | 320 const std::vector<blink::WebCompositionUnderline>& underlines, |
| 321 int selection_start, | 321 int selection_start, |
| 322 int selection_end); | 322 int selection_end); |
| 323 void SimulateImeConfirmComposition(const string16& text, | 323 void SimulateImeConfirmComposition(const string16& text, |
| 324 const gfx::Range& replacement_range); | 324 const gfx::Range& replacement_range); |
| 325 | 325 |
| 326 #if defined(OS_MACOSX) || defined(OS_WIN) | 326 #if defined(OS_MACOSX) || defined(OS_WIN) |
| 327 // Informs the render view that the given plugin has gained or lost focus. | 327 // Informs the render view that the given plugin has gained or lost focus. |
| 328 void PluginFocusChanged(bool focused, int plugin_id); | 328 void PluginFocusChanged(bool focused, int plugin_id); |
| 329 #endif | 329 #endif |
| 330 | 330 |
| (...skipping 12 matching lines...) Expand all Loading... |
| 343 // |info|). | 343 // |info|). |
| 344 bool GetPluginInfo(const GURL& url, | 344 bool GetPluginInfo(const GURL& url, |
| 345 const GURL& page_url, | 345 const GURL& page_url, |
| 346 const std::string& mime_type, | 346 const std::string& mime_type, |
| 347 WebPluginInfo* plugin_info, | 347 WebPluginInfo* plugin_info, |
| 348 std::string* actual_mime_type); | 348 std::string* actual_mime_type); |
| 349 | 349 |
| 350 #endif // ENABLE_PLUGINS | 350 #endif // ENABLE_PLUGINS |
| 351 | 351 |
| 352 void TransferActiveWheelFlingAnimation( | 352 void TransferActiveWheelFlingAnimation( |
| 353 const WebKit::WebActiveWheelFlingParameters& params); | 353 const blink::WebActiveWheelFlingParameters& params); |
| 354 | 354 |
| 355 // Returns true if the focused element is editable text from the perspective | 355 // Returns true if the focused element is editable text from the perspective |
| 356 // of IME support (also used for on-screen keyboard). Works correctly inside | 356 // of IME support (also used for on-screen keyboard). Works correctly inside |
| 357 // supported PPAPI plug-ins. | 357 // supported PPAPI plug-ins. |
| 358 bool HasIMETextFocus(); | 358 bool HasIMETextFocus(); |
| 359 | 359 |
| 360 // Callback for use with GetWindowSnapshot. | 360 // Callback for use with GetWindowSnapshot. |
| 361 typedef base::Callback<void( | 361 typedef base::Callback<void( |
| 362 const gfx::Size&, const std::vector<unsigned char>&)> | 362 const gfx::Size&, const std::vector<unsigned char>&)> |
| 363 WindowSnapshotCallback; | 363 WindowSnapshotCallback; |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 395 // Must be called before any players are created. | 395 // Must be called before any players are created. |
| 396 void SetMediaStreamClientForTesting(MediaStreamClient* media_stream_client); | 396 void SetMediaStreamClientForTesting(MediaStreamClient* media_stream_client); |
| 397 | 397 |
| 398 // Determines whether plugins are allowed to enter fullscreen mode. | 398 // Determines whether plugins are allowed to enter fullscreen mode. |
| 399 bool IsPluginFullscreenAllowed(); | 399 bool IsPluginFullscreenAllowed(); |
| 400 | 400 |
| 401 // IPC::Listener implementation ---------------------------------------------- | 401 // IPC::Listener implementation ---------------------------------------------- |
| 402 | 402 |
| 403 virtual bool OnMessageReceived(const IPC::Message& msg) OVERRIDE; | 403 virtual bool OnMessageReceived(const IPC::Message& msg) OVERRIDE; |
| 404 | 404 |
| 405 // WebKit::WebWidgetClient implementation ------------------------------------ | 405 // blink::WebWidgetClient implementation ------------------------------------ |
| 406 | 406 |
| 407 // Most methods are handled by RenderWidget. | 407 // Most methods are handled by RenderWidget. |
| 408 virtual void didFocus(); | 408 virtual void didFocus(); |
| 409 virtual void didBlur(); | 409 virtual void didBlur(); |
| 410 virtual void show(WebKit::WebNavigationPolicy policy); | 410 virtual void show(blink::WebNavigationPolicy policy); |
| 411 virtual void runModal(); | 411 virtual void runModal(); |
| 412 virtual bool enterFullScreen(); | 412 virtual bool enterFullScreen(); |
| 413 virtual void exitFullScreen(); | 413 virtual void exitFullScreen(); |
| 414 virtual bool requestPointerLock(); | 414 virtual bool requestPointerLock(); |
| 415 virtual void requestPointerUnlock(); | 415 virtual void requestPointerUnlock(); |
| 416 virtual bool isPointerLocked(); | 416 virtual bool isPointerLocked(); |
| 417 virtual void didActivateCompositor(int input_handler_identifier); | 417 virtual void didActivateCompositor(int input_handler_identifier); |
| 418 virtual void didHandleGestureEvent(const WebKit::WebGestureEvent& event, | 418 virtual void didHandleGestureEvent(const blink::WebGestureEvent& event, |
| 419 bool event_cancelled) OVERRIDE; | 419 bool event_cancelled) OVERRIDE; |
| 420 virtual void initializeLayerTreeView() OVERRIDE; | 420 virtual void initializeLayerTreeView() OVERRIDE; |
| 421 | 421 |
| 422 // WebKit::WebViewClient implementation -------------------------------------- | 422 // blink::WebViewClient implementation -------------------------------------- |
| 423 | 423 |
| 424 virtual WebKit::WebView* createView( | 424 virtual blink::WebView* createView( |
| 425 WebKit::WebFrame* creator, | 425 blink::WebFrame* creator, |
| 426 const WebKit::WebURLRequest& request, | 426 const blink::WebURLRequest& request, |
| 427 const WebKit::WebWindowFeatures& features, | 427 const blink::WebWindowFeatures& features, |
| 428 const WebKit::WebString& frame_name, | 428 const blink::WebString& frame_name, |
| 429 WebKit::WebNavigationPolicy policy, | 429 blink::WebNavigationPolicy policy, |
| 430 bool suppress_opener); | 430 bool suppress_opener); |
| 431 // DEPRECATED | 431 // DEPRECATED |
| 432 virtual WebKit::WebView* createView( | 432 virtual blink::WebView* createView( |
| 433 WebKit::WebFrame* creator, | 433 blink::WebFrame* creator, |
| 434 const WebKit::WebURLRequest& request, | 434 const blink::WebURLRequest& request, |
| 435 const WebKit::WebWindowFeatures& features, | 435 const blink::WebWindowFeatures& features, |
| 436 const WebKit::WebString& frame_name, | 436 const blink::WebString& frame_name, |
| 437 WebKit::WebNavigationPolicy policy); | 437 blink::WebNavigationPolicy policy); |
| 438 virtual WebKit::WebWidget* createPopupMenu(WebKit::WebPopupType popup_type); | 438 virtual blink::WebWidget* createPopupMenu(blink::WebPopupType popup_type); |
| 439 virtual WebKit::WebExternalPopupMenu* createExternalPopupMenu( | 439 virtual blink::WebExternalPopupMenu* createExternalPopupMenu( |
| 440 const WebKit::WebPopupMenuInfo& popup_menu_info, | 440 const blink::WebPopupMenuInfo& popup_menu_info, |
| 441 WebKit::WebExternalPopupMenuClient* popup_menu_client); | 441 blink::WebExternalPopupMenuClient* popup_menu_client); |
| 442 virtual WebKit::WebStorageNamespace* createSessionStorageNamespace(); | 442 virtual blink::WebStorageNamespace* createSessionStorageNamespace(); |
| 443 virtual bool shouldReportDetailedMessageForSource( | 443 virtual bool shouldReportDetailedMessageForSource( |
| 444 const WebKit::WebString& source); | 444 const blink::WebString& source); |
| 445 virtual void didAddMessageToConsole( | 445 virtual void didAddMessageToConsole( |
| 446 const WebKit::WebConsoleMessage& message, | 446 const blink::WebConsoleMessage& message, |
| 447 const WebKit::WebString& source_name, | 447 const blink::WebString& source_name, |
| 448 unsigned source_line, | 448 unsigned source_line, |
| 449 const WebKit::WebString& stack_trace); | 449 const blink::WebString& stack_trace); |
| 450 virtual void printPage(WebKit::WebFrame* frame); | 450 virtual void printPage(blink::WebFrame* frame); |
| 451 virtual WebKit::WebNotificationPresenter* notificationPresenter(); | 451 virtual blink::WebNotificationPresenter* notificationPresenter(); |
| 452 virtual bool enumerateChosenDirectory( | 452 virtual bool enumerateChosenDirectory( |
| 453 const WebKit::WebString& path, | 453 const blink::WebString& path, |
| 454 WebKit::WebFileChooserCompletion* chooser_completion); | 454 blink::WebFileChooserCompletion* chooser_completion); |
| 455 virtual void initializeHelperPluginWebFrame(WebKit::WebHelperPlugin*); | 455 virtual void initializeHelperPluginWebFrame(blink::WebHelperPlugin*); |
| 456 virtual void didStartLoading(); | 456 virtual void didStartLoading(); |
| 457 virtual void didStopLoading(); | 457 virtual void didStopLoading(); |
| 458 virtual void didChangeLoadProgress(WebKit::WebFrame* frame, | 458 virtual void didChangeLoadProgress(blink::WebFrame* frame, |
| 459 double load_progress); | 459 double load_progress); |
| 460 virtual void didCancelCompositionOnSelectionChange(); | 460 virtual void didCancelCompositionOnSelectionChange(); |
| 461 virtual void didChangeSelection(bool is_selection_empty); | 461 virtual void didChangeSelection(bool is_selection_empty); |
| 462 virtual void didExecuteCommand(const WebKit::WebString& command_name); | 462 virtual void didExecuteCommand(const blink::WebString& command_name); |
| 463 virtual bool handleCurrentKeyboardEvent(); | 463 virtual bool handleCurrentKeyboardEvent(); |
| 464 virtual WebKit::WebColorChooser* createColorChooser( | 464 virtual blink::WebColorChooser* createColorChooser( |
| 465 WebKit::WebColorChooserClient*, const WebKit::WebColor& initial_color); | 465 blink::WebColorChooserClient*, const blink::WebColor& initial_color); |
| 466 virtual bool runFileChooser( | 466 virtual bool runFileChooser( |
| 467 const WebKit::WebFileChooserParams& params, | 467 const blink::WebFileChooserParams& params, |
| 468 WebKit::WebFileChooserCompletion* chooser_completion); | 468 blink::WebFileChooserCompletion* chooser_completion); |
| 469 virtual void runModalAlertDialog(WebKit::WebFrame* frame, | 469 virtual void runModalAlertDialog(blink::WebFrame* frame, |
| 470 const WebKit::WebString& message); | 470 const blink::WebString& message); |
| 471 virtual bool runModalConfirmDialog(WebKit::WebFrame* frame, | 471 virtual bool runModalConfirmDialog(blink::WebFrame* frame, |
| 472 const WebKit::WebString& message); | 472 const blink::WebString& message); |
| 473 virtual bool runModalPromptDialog(WebKit::WebFrame* frame, | 473 virtual bool runModalPromptDialog(blink::WebFrame* frame, |
| 474 const WebKit::WebString& message, | 474 const blink::WebString& message, |
| 475 const WebKit::WebString& default_value, | 475 const blink::WebString& default_value, |
| 476 WebKit::WebString* actual_value); | 476 blink::WebString* actual_value); |
| 477 virtual bool runModalBeforeUnloadDialog(WebKit::WebFrame* frame, | 477 virtual bool runModalBeforeUnloadDialog(blink::WebFrame* frame, |
| 478 bool is_reload, | 478 bool is_reload, |
| 479 const WebKit::WebString& message); | 479 const blink::WebString& message); |
| 480 // DEPRECATED | 480 // DEPRECATED |
| 481 virtual bool runModalBeforeUnloadDialog(WebKit::WebFrame* frame, | 481 virtual bool runModalBeforeUnloadDialog(blink::WebFrame* frame, |
| 482 const WebKit::WebString& message); | 482 const blink::WebString& message); |
| 483 virtual void showContextMenu(WebKit::WebFrame* frame, | 483 virtual void showContextMenu(blink::WebFrame* frame, |
| 484 const WebKit::WebContextMenuData& data); | 484 const blink::WebContextMenuData& data); |
| 485 virtual void clearContextMenu(); | 485 virtual void clearContextMenu(); |
| 486 virtual void setStatusText(const WebKit::WebString& text); | 486 virtual void setStatusText(const blink::WebString& text); |
| 487 virtual void setMouseOverURL(const WebKit::WebURL& url); | 487 virtual void setMouseOverURL(const blink::WebURL& url); |
| 488 virtual void setKeyboardFocusURL(const WebKit::WebURL& url); | 488 virtual void setKeyboardFocusURL(const blink::WebURL& url); |
| 489 virtual void startDragging(WebKit::WebFrame* frame, | 489 virtual void startDragging(blink::WebFrame* frame, |
| 490 const WebKit::WebDragData& data, | 490 const blink::WebDragData& data, |
| 491 WebKit::WebDragOperationsMask mask, | 491 blink::WebDragOperationsMask mask, |
| 492 const WebKit::WebImage& image, | 492 const blink::WebImage& image, |
| 493 const WebKit::WebPoint& imageOffset); | 493 const blink::WebPoint& imageOffset); |
| 494 virtual bool acceptsLoadDrops(); | 494 virtual bool acceptsLoadDrops(); |
| 495 virtual void focusNext(); | 495 virtual void focusNext(); |
| 496 virtual void focusPrevious(); | 496 virtual void focusPrevious(); |
| 497 virtual void focusedNodeChanged(const WebKit::WebNode& node); | 497 virtual void focusedNodeChanged(const blink::WebNode& node); |
| 498 virtual void numberOfWheelEventHandlersChanged(unsigned num_handlers); | 498 virtual void numberOfWheelEventHandlersChanged(unsigned num_handlers); |
| 499 virtual void didUpdateLayout(); | 499 virtual void didUpdateLayout(); |
| 500 #if defined(OS_ANDROID) | 500 #if defined(OS_ANDROID) |
| 501 virtual bool didTapMultipleTargets( | 501 virtual bool didTapMultipleTargets( |
| 502 const WebKit::WebGestureEvent& event, | 502 const blink::WebGestureEvent& event, |
| 503 const WebKit::WebVector<WebKit::WebRect>& target_rects); | 503 const blink::WebVector<blink::WebRect>& target_rects); |
| 504 #endif | 504 #endif |
| 505 virtual void navigateBackForwardSoon(int offset); | 505 virtual void navigateBackForwardSoon(int offset); |
| 506 virtual int historyBackListCount(); | 506 virtual int historyBackListCount(); |
| 507 virtual int historyForwardListCount(); | 507 virtual int historyForwardListCount(); |
| 508 virtual void postAccessibilityEvent( | 508 virtual void postAccessibilityEvent( |
| 509 const WebKit::WebAXObject& obj, WebKit::WebAXEvent event); | 509 const blink::WebAXObject& obj, blink::WebAXEvent event); |
| 510 virtual void didUpdateInspectorSetting(const WebKit::WebString& key, | 510 virtual void didUpdateInspectorSetting(const blink::WebString& key, |
| 511 const WebKit::WebString& value); | 511 const blink::WebString& value); |
| 512 virtual WebKit::WebGeolocationClient* geolocationClient(); | 512 virtual blink::WebGeolocationClient* geolocationClient(); |
| 513 virtual WebKit::WebSpeechInputController* speechInputController( | 513 virtual blink::WebSpeechInputController* speechInputController( |
| 514 WebKit::WebSpeechInputListener* listener); | 514 blink::WebSpeechInputListener* listener); |
| 515 virtual WebKit::WebSpeechRecognizer* speechRecognizer(); | 515 virtual blink::WebSpeechRecognizer* speechRecognizer(); |
| 516 virtual void zoomLimitsChanged(double minimum_level, double maximum_level); | 516 virtual void zoomLimitsChanged(double minimum_level, double maximum_level); |
| 517 virtual void zoomLevelChanged(); | 517 virtual void zoomLevelChanged(); |
| 518 virtual double zoomLevelToZoomFactor(double zoom_level) const; | 518 virtual double zoomLevelToZoomFactor(double zoom_level) const; |
| 519 virtual double zoomFactorToZoomLevel(double factor) const; | 519 virtual double zoomFactorToZoomLevel(double factor) const; |
| 520 virtual void registerProtocolHandler(const WebKit::WebString& scheme, | 520 virtual void registerProtocolHandler(const blink::WebString& scheme, |
| 521 const WebKit::WebString& base_url, | 521 const blink::WebString& base_url, |
| 522 const WebKit::WebString& url, | 522 const blink::WebString& url, |
| 523 const WebKit::WebString& title); | 523 const blink::WebString& title); |
| 524 virtual WebKit::WebPageVisibilityState visibilityState() const; | 524 virtual blink::WebPageVisibilityState visibilityState() const; |
| 525 virtual WebKit::WebUserMediaClient* userMediaClient(); | 525 virtual blink::WebUserMediaClient* userMediaClient(); |
| 526 virtual WebKit::WebMIDIClient* webMIDIClient(); | 526 virtual blink::WebMIDIClient* webMIDIClient(); |
| 527 virtual void draggableRegionsChanged(); | 527 virtual void draggableRegionsChanged(); |
| 528 | 528 |
| 529 #if defined(OS_ANDROID) | 529 #if defined(OS_ANDROID) |
| 530 virtual void scheduleContentIntent(const WebKit::WebURL& intent); | 530 virtual void scheduleContentIntent(const blink::WebURL& intent); |
| 531 virtual void cancelScheduledContentIntents(); | 531 virtual void cancelScheduledContentIntents(); |
| 532 virtual WebKit::WebContentDetectionResult detectContentAround( | 532 virtual blink::WebContentDetectionResult detectContentAround( |
| 533 const WebKit::WebHitTestResult& touch_hit); | 533 const blink::WebHitTestResult& touch_hit); |
| 534 | 534 |
| 535 // Only used on Android since all other platforms implement | 535 // Only used on Android since all other platforms implement |
| 536 // date and time input fields using MULTIPLE_FIELDS_UI | 536 // date and time input fields using MULTIPLE_FIELDS_UI |
| 537 virtual bool openDateTimeChooser(const WebKit::WebDateTimeChooserParams&, | 537 virtual bool openDateTimeChooser(const blink::WebDateTimeChooserParams&, |
| 538 WebKit::WebDateTimeChooserCompletion*); | 538 blink::WebDateTimeChooserCompletion*); |
| 539 virtual void didScrollWithKeyboard(const WebKit::WebSize& delta); | 539 virtual void didScrollWithKeyboard(const blink::WebSize& delta); |
| 540 #endif | 540 #endif |
| 541 | 541 |
| 542 // WebKit::WebFrameClient implementation ------------------------------------- | 542 // blink::WebFrameClient implementation ------------------------------------- |
| 543 | 543 |
| 544 virtual WebKit::WebMediaPlayer* createMediaPlayer( | 544 virtual blink::WebMediaPlayer* createMediaPlayer( |
| 545 WebKit::WebFrame* frame, | 545 blink::WebFrame* frame, |
| 546 const WebKit::WebURL& url, | 546 const blink::WebURL& url, |
| 547 WebKit::WebMediaPlayerClient* client); | 547 blink::WebMediaPlayerClient* client); |
| 548 virtual WebKit::WebCookieJar* cookieJar(WebKit::WebFrame* frame); | 548 virtual blink::WebCookieJar* cookieJar(blink::WebFrame* frame); |
| 549 virtual void didAccessInitialDocument(WebKit::WebFrame* frame); | 549 virtual void didAccessInitialDocument(blink::WebFrame* frame); |
| 550 virtual void didDisownOpener(WebKit::WebFrame* frame); | 550 virtual void didDisownOpener(blink::WebFrame* frame); |
| 551 virtual void frameDetached(WebKit::WebFrame* frame); | 551 virtual void frameDetached(blink::WebFrame* frame); |
| 552 virtual void willClose(WebKit::WebFrame* frame); | 552 virtual void willClose(blink::WebFrame* frame); |
| 553 virtual void didMatchCSS( | 553 virtual void didMatchCSS( |
| 554 WebKit::WebFrame* frame, | 554 blink::WebFrame* frame, |
| 555 const WebKit::WebVector<WebKit::WebString>& newly_matching_selectors, | 555 const blink::WebVector<blink::WebString>& newly_matching_selectors, |
| 556 const WebKit::WebVector<WebKit::WebString>& stopped_matching_selectors); | 556 const blink::WebVector<blink::WebString>& stopped_matching_selectors); |
| 557 | 557 |
| 558 // The WebDataSource::ExtraData* is assumed to be a DocumentState* subclass. | 558 // The WebDataSource::ExtraData* is assumed to be a DocumentState* subclass. |
| 559 virtual WebKit::WebNavigationPolicy decidePolicyForNavigation( | 559 virtual blink::WebNavigationPolicy decidePolicyForNavigation( |
| 560 WebKit::WebFrame* frame, | 560 blink::WebFrame* frame, |
| 561 WebKit::WebDataSource::ExtraData* extraData, | 561 blink::WebDataSource::ExtraData* extraData, |
| 562 const WebKit::WebURLRequest& request, | 562 const blink::WebURLRequest& request, |
| 563 WebKit::WebNavigationType type, | 563 blink::WebNavigationType type, |
| 564 WebKit::WebNavigationPolicy default_policy, | 564 blink::WebNavigationPolicy default_policy, |
| 565 bool is_redirect); | 565 bool is_redirect); |
| 566 // DEPRECATED. | 566 // DEPRECATED. |
| 567 virtual WebKit::WebNavigationPolicy decidePolicyForNavigation( | 567 virtual blink::WebNavigationPolicy decidePolicyForNavigation( |
| 568 WebKit::WebFrame* frame, | 568 blink::WebFrame* frame, |
| 569 const WebKit::WebURLRequest& request, | 569 const blink::WebURLRequest& request, |
| 570 WebKit::WebNavigationType type, | 570 blink::WebNavigationType type, |
| 571 WebKit::WebNavigationPolicy default_policy, | 571 blink::WebNavigationPolicy default_policy, |
| 572 bool is_redirect); | 572 bool is_redirect); |
| 573 virtual void willSendSubmitEvent(WebKit::WebFrame* frame, | 573 virtual void willSendSubmitEvent(blink::WebFrame* frame, |
| 574 const WebKit::WebFormElement& form); | 574 const blink::WebFormElement& form); |
| 575 virtual void willSubmitForm(WebKit::WebFrame* frame, | 575 virtual void willSubmitForm(blink::WebFrame* frame, |
| 576 const WebKit::WebFormElement& form); | 576 const blink::WebFormElement& form); |
| 577 virtual void didCreateDataSource(WebKit::WebFrame* frame, | 577 virtual void didCreateDataSource(blink::WebFrame* frame, |
| 578 WebKit::WebDataSource* datasource); | 578 blink::WebDataSource* datasource); |
| 579 virtual void didStartProvisionalLoad(WebKit::WebFrame* frame); | 579 virtual void didStartProvisionalLoad(blink::WebFrame* frame); |
| 580 virtual void didReceiveServerRedirectForProvisionalLoad( | 580 virtual void didReceiveServerRedirectForProvisionalLoad( |
| 581 WebKit::WebFrame* frame); | 581 blink::WebFrame* frame); |
| 582 virtual void didFailProvisionalLoad(WebKit::WebFrame* frame, | 582 virtual void didFailProvisionalLoad(blink::WebFrame* frame, |
| 583 const WebKit::WebURLError& error); | 583 const blink::WebURLError& error); |
| 584 virtual void didCommitProvisionalLoad(WebKit::WebFrame* frame, | 584 virtual void didCommitProvisionalLoad(blink::WebFrame* frame, |
| 585 bool is_new_navigation); | 585 bool is_new_navigation); |
| 586 virtual void didClearWindowObject(WebKit::WebFrame* frame); | 586 virtual void didClearWindowObject(blink::WebFrame* frame); |
| 587 virtual void didCreateDocumentElement(WebKit::WebFrame* frame); | 587 virtual void didCreateDocumentElement(blink::WebFrame* frame); |
| 588 virtual void didReceiveTitle(WebKit::WebFrame* frame, | 588 virtual void didReceiveTitle(blink::WebFrame* frame, |
| 589 const WebKit::WebString& title, | 589 const blink::WebString& title, |
| 590 WebKit::WebTextDirection direction); | 590 blink::WebTextDirection direction); |
| 591 virtual void didChangeIcon(WebKit::WebFrame*, | 591 virtual void didChangeIcon(blink::WebFrame*, |
| 592 WebKit::WebIconURL::Type); | 592 blink::WebIconURL::Type); |
| 593 virtual void didFinishDocumentLoad(WebKit::WebFrame* frame); | 593 virtual void didFinishDocumentLoad(blink::WebFrame* frame); |
| 594 virtual void didHandleOnloadEvents(WebKit::WebFrame* frame); | 594 virtual void didHandleOnloadEvents(blink::WebFrame* frame); |
| 595 virtual void didFailLoad(WebKit::WebFrame* frame, | 595 virtual void didFailLoad(blink::WebFrame* frame, |
| 596 const WebKit::WebURLError& error); | 596 const blink::WebURLError& error); |
| 597 virtual void didFinishLoad(WebKit::WebFrame* frame); | 597 virtual void didFinishLoad(blink::WebFrame* frame); |
| 598 virtual void didNavigateWithinPage(WebKit::WebFrame* frame, | 598 virtual void didNavigateWithinPage(blink::WebFrame* frame, |
| 599 bool is_new_navigation); | 599 bool is_new_navigation); |
| 600 virtual void didUpdateCurrentHistoryItem(WebKit::WebFrame* frame); | 600 virtual void didUpdateCurrentHistoryItem(blink::WebFrame* frame); |
| 601 virtual void willSendRequest(WebKit::WebFrame* frame, | 601 virtual void willSendRequest(blink::WebFrame* frame, |
| 602 unsigned identifier, | 602 unsigned identifier, |
| 603 WebKit::WebURLRequest& request, | 603 blink::WebURLRequest& request, |
| 604 const WebKit::WebURLResponse& redirect_response); | 604 const blink::WebURLResponse& redirect_response); |
| 605 virtual void didReceiveResponse(WebKit::WebFrame* frame, | 605 virtual void didReceiveResponse(blink::WebFrame* frame, |
| 606 unsigned identifier, | 606 unsigned identifier, |
| 607 const WebKit::WebURLResponse& response); | 607 const blink::WebURLResponse& response); |
| 608 virtual void didFinishResourceLoad(WebKit::WebFrame* frame, | 608 virtual void didFinishResourceLoad(blink::WebFrame* frame, |
| 609 unsigned identifier); | 609 unsigned identifier); |
| 610 virtual void didLoadResourceFromMemoryCache( | 610 virtual void didLoadResourceFromMemoryCache( |
| 611 WebKit::WebFrame* frame, | 611 blink::WebFrame* frame, |
| 612 const WebKit::WebURLRequest& request, | 612 const blink::WebURLRequest& request, |
| 613 const WebKit::WebURLResponse&); | 613 const blink::WebURLResponse&); |
| 614 virtual void didDisplayInsecureContent(WebKit::WebFrame* frame); | 614 virtual void didDisplayInsecureContent(blink::WebFrame* frame); |
| 615 virtual void didRunInsecureContent( | 615 virtual void didRunInsecureContent( |
| 616 WebKit::WebFrame* frame, | 616 blink::WebFrame* frame, |
| 617 const WebKit::WebSecurityOrigin& origin, | 617 const blink::WebSecurityOrigin& origin, |
| 618 const WebKit::WebURL& target); | 618 const blink::WebURL& target); |
| 619 virtual void didExhaustMemoryAvailableForScript(WebKit::WebFrame* frame); | 619 virtual void didExhaustMemoryAvailableForScript(blink::WebFrame* frame); |
| 620 virtual void didCreateScriptContext(WebKit::WebFrame* frame, | 620 virtual void didCreateScriptContext(blink::WebFrame* frame, |
| 621 v8::Handle<v8::Context>, | 621 v8::Handle<v8::Context>, |
| 622 int extension_group, | 622 int extension_group, |
| 623 int world_id); | 623 int world_id); |
| 624 virtual void willReleaseScriptContext(WebKit::WebFrame* frame, | 624 virtual void willReleaseScriptContext(blink::WebFrame* frame, |
| 625 v8::Handle<v8::Context>, | 625 v8::Handle<v8::Context>, |
| 626 int world_id); | 626 int world_id); |
| 627 virtual void didChangeScrollOffset(WebKit::WebFrame* frame); | 627 virtual void didChangeScrollOffset(blink::WebFrame* frame); |
| 628 virtual void willInsertBody(WebKit::WebFrame* frame); | 628 virtual void willInsertBody(blink::WebFrame* frame); |
| 629 virtual void didFirstVisuallyNonEmptyLayout(WebKit::WebFrame*); | 629 virtual void didFirstVisuallyNonEmptyLayout(blink::WebFrame*); |
| 630 virtual void didChangeContentsSize(WebKit::WebFrame* frame, | 630 virtual void didChangeContentsSize(blink::WebFrame* frame, |
| 631 const WebKit::WebSize& size); | 631 const blink::WebSize& size); |
| 632 virtual void reportFindInPageMatchCount(int request_id, | 632 virtual void reportFindInPageMatchCount(int request_id, |
| 633 int count, | 633 int count, |
| 634 bool final_update); | 634 bool final_update); |
| 635 virtual void reportFindInPageSelection(int request_id, | 635 virtual void reportFindInPageSelection(int request_id, |
| 636 int active_match_ordinal, | 636 int active_match_ordinal, |
| 637 const WebKit::WebRect& sel); | 637 const blink::WebRect& sel); |
| 638 virtual void requestStorageQuota( | 638 virtual void requestStorageQuota( |
| 639 WebKit::WebFrame* frame, | 639 blink::WebFrame* frame, |
| 640 WebKit::WebStorageQuotaType type, | 640 blink::WebStorageQuotaType type, |
| 641 unsigned long long requested_size, | 641 unsigned long long requested_size, |
| 642 WebKit::WebStorageQuotaCallbacks* callbacks); | 642 blink::WebStorageQuotaCallbacks* callbacks); |
| 643 virtual void willOpenSocketStream( | 643 virtual void willOpenSocketStream( |
| 644 WebKit::WebSocketStreamHandle* handle); | 644 blink::WebSocketStreamHandle* handle); |
| 645 virtual void willStartUsingPeerConnectionHandler(WebKit::WebFrame* frame, | 645 virtual void willStartUsingPeerConnectionHandler(blink::WebFrame* frame, |
| 646 WebKit::WebRTCPeerConnectionHandler* handler); | 646 blink::WebRTCPeerConnectionHandler* handler); |
| 647 virtual bool willCheckAndDispatchMessageEvent( | 647 virtual bool willCheckAndDispatchMessageEvent( |
| 648 WebKit::WebFrame* sourceFrame, | 648 blink::WebFrame* sourceFrame, |
| 649 WebKit::WebFrame* targetFrame, | 649 blink::WebFrame* targetFrame, |
| 650 WebKit::WebSecurityOrigin targetOrigin, | 650 blink::WebSecurityOrigin targetOrigin, |
| 651 WebKit::WebDOMMessageEvent event); | 651 blink::WebDOMMessageEvent event); |
| 652 virtual WebKit::WebString acceptLanguages(); | 652 virtual blink::WebString acceptLanguages(); |
| 653 virtual WebKit::WebString userAgentOverride( | 653 virtual blink::WebString userAgentOverride( |
| 654 WebKit::WebFrame* frame, | 654 blink::WebFrame* frame, |
| 655 const WebKit::WebURL& url); | 655 const blink::WebURL& url); |
| 656 virtual WebKit::WebString doNotTrackValue(WebKit::WebFrame* frame); | 656 virtual blink::WebString doNotTrackValue(blink::WebFrame* frame); |
| 657 virtual bool allowWebGL(WebKit::WebFrame* frame, bool default_value); | 657 virtual bool allowWebGL(blink::WebFrame* frame, bool default_value); |
| 658 virtual void didLoseWebGLContext( | 658 virtual void didLoseWebGLContext( |
| 659 WebKit::WebFrame* frame, | 659 blink::WebFrame* frame, |
| 660 int arb_robustness_status_code); | 660 int arb_robustness_status_code); |
| 661 | 661 |
| 662 // WebKit::WebPageSerializerClient implementation ---------------------------- | 662 // blink::WebPageSerializerClient implementation ---------------------------- |
| 663 | 663 |
| 664 virtual void didSerializeDataForFrame( | 664 virtual void didSerializeDataForFrame( |
| 665 const WebKit::WebURL& frame_url, | 665 const blink::WebURL& frame_url, |
| 666 const WebKit::WebCString& data, | 666 const blink::WebCString& data, |
| 667 PageSerializationStatus status) OVERRIDE; | 667 PageSerializationStatus status) OVERRIDE; |
| 668 | 668 |
| 669 // RenderView implementation ------------------------------------------------- | 669 // RenderView implementation ------------------------------------------------- |
| 670 | 670 |
| 671 virtual bool Send(IPC::Message* message) OVERRIDE; | 671 virtual bool Send(IPC::Message* message) OVERRIDE; |
| 672 virtual int GetRoutingID() const OVERRIDE; | 672 virtual int GetRoutingID() const OVERRIDE; |
| 673 virtual int GetPageId() const OVERRIDE; | 673 virtual int GetPageId() const OVERRIDE; |
| 674 virtual gfx::Size GetSize() const OVERRIDE; | 674 virtual gfx::Size GetSize() const OVERRIDE; |
| 675 virtual WebPreferences& GetWebkitPreferences() OVERRIDE; | 675 virtual WebPreferences& GetWebkitPreferences() OVERRIDE; |
| 676 virtual void SetWebkitPreferences(const WebPreferences& preferences) OVERRIDE; | 676 virtual void SetWebkitPreferences(const WebPreferences& preferences) OVERRIDE; |
| 677 virtual WebKit::WebView* GetWebView() OVERRIDE; | 677 virtual blink::WebView* GetWebView() OVERRIDE; |
| 678 virtual WebKit::WebNode GetFocusedNode() const OVERRIDE; | 678 virtual blink::WebNode GetFocusedNode() const OVERRIDE; |
| 679 virtual WebKit::WebNode GetContextMenuNode() const OVERRIDE; | 679 virtual blink::WebNode GetContextMenuNode() const OVERRIDE; |
| 680 virtual bool IsEditableNode(const WebKit::WebNode& node) const OVERRIDE; | 680 virtual bool IsEditableNode(const blink::WebNode& node) const OVERRIDE; |
| 681 virtual WebKit::WebPlugin* CreatePlugin( | 681 virtual blink::WebPlugin* CreatePlugin( |
| 682 WebKit::WebFrame* frame, | 682 blink::WebFrame* frame, |
| 683 const WebPluginInfo& info, | 683 const WebPluginInfo& info, |
| 684 const WebKit::WebPluginParams& params) OVERRIDE; | 684 const blink::WebPluginParams& params) OVERRIDE; |
| 685 virtual void EvaluateScript(const string16& frame_xpath, | 685 virtual void EvaluateScript(const string16& frame_xpath, |
| 686 const string16& jscript, | 686 const string16& jscript, |
| 687 int id, | 687 int id, |
| 688 bool notify_result) OVERRIDE; | 688 bool notify_result) OVERRIDE; |
| 689 virtual bool ShouldDisplayScrollbars(int width, int height) const OVERRIDE; | 689 virtual bool ShouldDisplayScrollbars(int width, int height) const OVERRIDE; |
| 690 virtual int GetEnabledBindings() const OVERRIDE; | 690 virtual int GetEnabledBindings() const OVERRIDE; |
| 691 virtual bool GetContentStateImmediately() const OVERRIDE; | 691 virtual bool GetContentStateImmediately() const OVERRIDE; |
| 692 virtual float GetFilteredTimePerFrame() const OVERRIDE; | 692 virtual float GetFilteredTimePerFrame() const OVERRIDE; |
| 693 virtual int ShowContextMenu(ContextMenuClient* client, | 693 virtual int ShowContextMenu(ContextMenuClient* client, |
| 694 const ContextMenuParams& params) OVERRIDE; | 694 const ContextMenuParams& params) OVERRIDE; |
| 695 virtual void CancelContextMenu(int request_id) OVERRIDE; | 695 virtual void CancelContextMenu(int request_id) OVERRIDE; |
| 696 virtual WebKit::WebPageVisibilityState GetVisibilityState() const OVERRIDE; | 696 virtual blink::WebPageVisibilityState GetVisibilityState() const OVERRIDE; |
| 697 virtual void RunModalAlertDialog(WebKit::WebFrame* frame, | 697 virtual void RunModalAlertDialog(blink::WebFrame* frame, |
| 698 const WebKit::WebString& message) OVERRIDE; | 698 const blink::WebString& message) OVERRIDE; |
| 699 virtual void LoadURLExternally( | 699 virtual void LoadURLExternally( |
| 700 WebKit::WebFrame* frame, | 700 blink::WebFrame* frame, |
| 701 const WebKit::WebURLRequest& request, | 701 const blink::WebURLRequest& request, |
| 702 WebKit::WebNavigationPolicy policy) OVERRIDE; | 702 blink::WebNavigationPolicy policy) OVERRIDE; |
| 703 virtual void DidStartLoading() OVERRIDE; | 703 virtual void DidStartLoading() OVERRIDE; |
| 704 virtual void DidStopLoading() OVERRIDE; | 704 virtual void DidStopLoading() OVERRIDE; |
| 705 virtual void Repaint(const gfx::Size& size) OVERRIDE; | 705 virtual void Repaint(const gfx::Size& size) OVERRIDE; |
| 706 virtual void SetEditCommandForNextKeyEvent(const std::string& name, | 706 virtual void SetEditCommandForNextKeyEvent(const std::string& name, |
| 707 const std::string& value) OVERRIDE; | 707 const std::string& value) OVERRIDE; |
| 708 virtual void ClearEditCommands() OVERRIDE; | 708 virtual void ClearEditCommands() OVERRIDE; |
| 709 virtual SSLStatus GetSSLStatusOfFrame(WebKit::WebFrame* frame) const OVERRIDE; | 709 virtual SSLStatus GetSSLStatusOfFrame(blink::WebFrame* frame) const OVERRIDE; |
| 710 virtual const std::string& GetAcceptLanguages() const OVERRIDE; | 710 virtual const std::string& GetAcceptLanguages() const OVERRIDE; |
| 711 #if defined(OS_ANDROID) | 711 #if defined(OS_ANDROID) |
| 712 virtual void UpdateTopControlsState(TopControlsState constraints, | 712 virtual void UpdateTopControlsState(TopControlsState constraints, |
| 713 TopControlsState current, | 713 TopControlsState current, |
| 714 bool animate) OVERRIDE; | 714 bool animate) OVERRIDE; |
| 715 #endif | 715 #endif |
| 716 | 716 |
| 717 // WebMediaPlayerDelegate implementation ----------------------- | 717 // WebMediaPlayerDelegate implementation ----------------------- |
| 718 | 718 |
| 719 virtual void DidPlay(WebKit::WebMediaPlayer* player) OVERRIDE; | 719 virtual void DidPlay(blink::WebMediaPlayer* player) OVERRIDE; |
| 720 virtual void DidPause(WebKit::WebMediaPlayer* player) OVERRIDE; | 720 virtual void DidPause(blink::WebMediaPlayer* player) OVERRIDE; |
| 721 virtual void PlayerGone(WebKit::WebMediaPlayer* player) OVERRIDE; | 721 virtual void PlayerGone(blink::WebMediaPlayer* player) OVERRIDE; |
| 722 | 722 |
| 723 // Please do not add your stuff randomly to the end here. If there is an | 723 // Please do not add your stuff randomly to the end here. If there is an |
| 724 // appropriate section, add it there. If not, there are some random functions | 724 // appropriate section, add it there. If not, there are some random functions |
| 725 // nearer to the top you can add it to. | 725 // nearer to the top you can add it to. |
| 726 | 726 |
| 727 // Cannot use std::set unfortunately since linked_ptr<> does not support | 727 // Cannot use std::set unfortunately since linked_ptr<> does not support |
| 728 // operator<. | 728 // operator<. |
| 729 typedef std::vector<linked_ptr<ImageResourceFetcher> > | 729 typedef std::vector<linked_ptr<ImageResourceFetcher> > |
| 730 ImageResourceFetcherList; | 730 ImageResourceFetcherList; |
| 731 | 731 |
| 732 protected: | 732 protected: |
| 733 // RenderWidget overrides: | 733 // RenderWidget overrides: |
| 734 virtual void Close() OVERRIDE; | 734 virtual void Close() OVERRIDE; |
| 735 virtual void OnResize(const ViewMsg_Resize_Params& params) OVERRIDE; | 735 virtual void OnResize(const ViewMsg_Resize_Params& params) OVERRIDE; |
| 736 virtual void DidInitiatePaint() OVERRIDE; | 736 virtual void DidInitiatePaint() OVERRIDE; |
| 737 virtual void DidFlushPaint() OVERRIDE; | 737 virtual void DidFlushPaint() OVERRIDE; |
| 738 virtual PepperPluginInstanceImpl* GetBitmapForOptimizedPluginPaint( | 738 virtual PepperPluginInstanceImpl* GetBitmapForOptimizedPluginPaint( |
| 739 const gfx::Rect& paint_bounds, | 739 const gfx::Rect& paint_bounds, |
| 740 TransportDIB** dib, | 740 TransportDIB** dib, |
| 741 gfx::Rect* location, | 741 gfx::Rect* location, |
| 742 gfx::Rect* clip, | 742 gfx::Rect* clip, |
| 743 float* scale_factor) OVERRIDE; | 743 float* scale_factor) OVERRIDE; |
| 744 virtual gfx::Vector2d GetScrollOffset() OVERRIDE; | 744 virtual gfx::Vector2d GetScrollOffset() OVERRIDE; |
| 745 virtual void DidHandleKeyEvent() OVERRIDE; | 745 virtual void DidHandleKeyEvent() OVERRIDE; |
| 746 virtual bool WillHandleMouseEvent( | 746 virtual bool WillHandleMouseEvent( |
| 747 const WebKit::WebMouseEvent& event) OVERRIDE; | 747 const blink::WebMouseEvent& event) OVERRIDE; |
| 748 virtual bool WillHandleKeyEvent( | 748 virtual bool WillHandleKeyEvent( |
| 749 const WebKit::WebKeyboardEvent& event) OVERRIDE; | 749 const blink::WebKeyboardEvent& event) OVERRIDE; |
| 750 virtual bool WillHandleGestureEvent( | 750 virtual bool WillHandleGestureEvent( |
| 751 const WebKit::WebGestureEvent& event) OVERRIDE; | 751 const blink::WebGestureEvent& event) OVERRIDE; |
| 752 virtual void DidHandleMouseEvent(const WebKit::WebMouseEvent& event) OVERRIDE; | 752 virtual void DidHandleMouseEvent(const blink::WebMouseEvent& event) OVERRIDE; |
| 753 virtual void DidHandleTouchEvent(const WebKit::WebTouchEvent& event) OVERRIDE; | 753 virtual void DidHandleTouchEvent(const blink::WebTouchEvent& event) OVERRIDE; |
| 754 virtual bool HasTouchEventHandlersAt(const gfx::Point& point) const OVERRIDE; | 754 virtual bool HasTouchEventHandlersAt(const gfx::Point& point) const OVERRIDE; |
| 755 virtual void OnSetFocus(bool enable) OVERRIDE; | 755 virtual void OnSetFocus(bool enable) OVERRIDE; |
| 756 virtual void OnWasHidden() OVERRIDE; | 756 virtual void OnWasHidden() OVERRIDE; |
| 757 virtual void OnWasShown(bool needs_repainting) OVERRIDE; | 757 virtual void OnWasShown(bool needs_repainting) OVERRIDE; |
| 758 virtual GURL GetURLForGraphicsContext3D() OVERRIDE; | 758 virtual GURL GetURLForGraphicsContext3D() OVERRIDE; |
| 759 virtual bool ForceCompositingModeEnabled() OVERRIDE; | 759 virtual bool ForceCompositingModeEnabled() OVERRIDE; |
| 760 virtual void OnImeSetComposition( | 760 virtual void OnImeSetComposition( |
| 761 const string16& text, | 761 const string16& text, |
| 762 const std::vector<WebKit::WebCompositionUnderline>& underlines, | 762 const std::vector<blink::WebCompositionUnderline>& underlines, |
| 763 int selection_start, | 763 int selection_start, |
| 764 int selection_end) OVERRIDE; | 764 int selection_end) OVERRIDE; |
| 765 virtual void OnImeConfirmComposition(const string16& text, | 765 virtual void OnImeConfirmComposition(const string16& text, |
| 766 const gfx::Range& replacement_range, | 766 const gfx::Range& replacement_range, |
| 767 bool keep_selection) OVERRIDE; | 767 bool keep_selection) OVERRIDE; |
| 768 virtual void SetDeviceScaleFactor(float device_scale_factor) OVERRIDE; | 768 virtual void SetDeviceScaleFactor(float device_scale_factor) OVERRIDE; |
| 769 virtual ui::TextInputType GetTextInputType() OVERRIDE; | 769 virtual ui::TextInputType GetTextInputType() OVERRIDE; |
| 770 virtual void GetSelectionBounds(gfx::Rect* start, gfx::Rect* end) OVERRIDE; | 770 virtual void GetSelectionBounds(gfx::Rect* start, gfx::Rect* end) OVERRIDE; |
| 771 #if defined(OS_MACOSX) || defined(OS_WIN) || defined(USE_AURA) | 771 #if defined(OS_MACOSX) || defined(OS_WIN) || defined(USE_AURA) |
| 772 virtual void GetCompositionCharacterBounds( | 772 virtual void GetCompositionCharacterBounds( |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 848 FRIEND_TEST_ALL_PREFIXES(SuppressErrorPageTest, DoesNotSuppress); | 848 FRIEND_TEST_ALL_PREFIXES(SuppressErrorPageTest, DoesNotSuppress); |
| 849 | 849 |
| 850 typedef std::map<GURL, double> HostZoomLevels; | 850 typedef std::map<GURL, double> HostZoomLevels; |
| 851 | 851 |
| 852 enum ErrorPageType { | 852 enum ErrorPageType { |
| 853 DNS_ERROR, | 853 DNS_ERROR, |
| 854 HTTP_404, | 854 HTTP_404, |
| 855 CONNECTION_ERROR, | 855 CONNECTION_ERROR, |
| 856 }; | 856 }; |
| 857 | 857 |
| 858 static WebKit::WebReferrerPolicy GetReferrerPolicyFromRequest( | 858 static blink::WebReferrerPolicy GetReferrerPolicyFromRequest( |
| 859 WebKit::WebFrame* frame, | 859 blink::WebFrame* frame, |
| 860 const WebKit::WebURLRequest& request); | 860 const blink::WebURLRequest& request); |
| 861 | 861 |
| 862 static Referrer GetReferrerFromRequest( | 862 static Referrer GetReferrerFromRequest( |
| 863 WebKit::WebFrame* frame, | 863 blink::WebFrame* frame, |
| 864 const WebKit::WebURLRequest& request); | 864 const blink::WebURLRequest& request); |
| 865 | 865 |
| 866 static webkit_glue::WebURLResponseExtraDataImpl* GetExtraDataFromResponse( | 866 static webkit_glue::WebURLResponseExtraDataImpl* GetExtraDataFromResponse( |
| 867 const WebKit::WebURLResponse& response); | 867 const blink::WebURLResponse& response); |
| 868 | 868 |
| 869 void UpdateURL(WebKit::WebFrame* frame); | 869 void UpdateURL(blink::WebFrame* frame); |
| 870 void UpdateTitle(WebKit::WebFrame* frame, const string16& title, | 870 void UpdateTitle(blink::WebFrame* frame, const string16& title, |
| 871 WebKit::WebTextDirection title_direction); | 871 blink::WebTextDirection title_direction); |
| 872 void UpdateSessionHistory(WebKit::WebFrame* frame); | 872 void UpdateSessionHistory(blink::WebFrame* frame); |
| 873 void SendUpdateState(const WebKit::WebHistoryItem& item); | 873 void SendUpdateState(const blink::WebHistoryItem& item); |
| 874 | 874 |
| 875 // Update current main frame's encoding and send it to browser window. | 875 // Update current main frame's encoding and send it to browser window. |
| 876 // Since we want to let users see the right encoding info from menu | 876 // Since we want to let users see the right encoding info from menu |
| 877 // before finishing loading, we call the UpdateEncoding in | 877 // before finishing loading, we call the UpdateEncoding in |
| 878 // a) function:DidCommitLoadForFrame. When this function is called, | 878 // a) function:DidCommitLoadForFrame. When this function is called, |
| 879 // that means we have got first data. In here we try to get encoding | 879 // that means we have got first data. In here we try to get encoding |
| 880 // of page if it has been specified in http header. | 880 // of page if it has been specified in http header. |
| 881 // b) function:DidReceiveTitle. When this function is called, | 881 // b) function:DidReceiveTitle. When this function is called, |
| 882 // that means we have got specified title. Because in most of webpages, | 882 // that means we have got specified title. Because in most of webpages, |
| 883 // title tags will follow meta tags. In here we try to get encoding of | 883 // title tags will follow meta tags. In here we try to get encoding of |
| 884 // page if it has been specified in meta tag. | 884 // page if it has been specified in meta tag. |
| 885 // c) function:DidFinishDocumentLoadForFrame. When this function is | 885 // c) function:DidFinishDocumentLoadForFrame. When this function is |
| 886 // called, that means we have got whole html page. In here we should | 886 // called, that means we have got whole html page. In here we should |
| 887 // finally get right encoding of page. | 887 // finally get right encoding of page. |
| 888 void UpdateEncoding(WebKit::WebFrame* frame, | 888 void UpdateEncoding(blink::WebFrame* frame, |
| 889 const std::string& encoding_name); | 889 const std::string& encoding_name); |
| 890 | 890 |
| 891 void OpenURL(WebKit::WebFrame* frame, | 891 void OpenURL(blink::WebFrame* frame, |
| 892 const GURL& url, | 892 const GURL& url, |
| 893 const Referrer& referrer, | 893 const Referrer& referrer, |
| 894 WebKit::WebNavigationPolicy policy); | 894 blink::WebNavigationPolicy policy); |
| 895 | 895 |
| 896 bool RunJavaScriptMessage(JavaScriptMessageType type, | 896 bool RunJavaScriptMessage(JavaScriptMessageType type, |
| 897 const string16& message, | 897 const string16& message, |
| 898 const string16& default_value, | 898 const string16& default_value, |
| 899 const GURL& frame_url, | 899 const GURL& frame_url, |
| 900 string16* result); | 900 string16* result); |
| 901 | 901 |
| 902 // Sends a message and runs a nested message loop. | 902 // Sends a message and runs a nested message loop. |
| 903 bool SendAndRunNestedMessageLoop(IPC::SyncMessage* message); | 903 bool SendAndRunNestedMessageLoop(IPC::SyncMessage* message); |
| 904 | 904 |
| 905 // Called when the "pinned to left/right edge" state needs to be updated. | 905 // Called when the "pinned to left/right edge" state needs to be updated. |
| 906 void UpdateScrollState(WebKit::WebFrame* frame); | 906 void UpdateScrollState(blink::WebFrame* frame); |
| 907 | 907 |
| 908 // IPC message handlers ------------------------------------------------------ | 908 // IPC message handlers ------------------------------------------------------ |
| 909 // | 909 // |
| 910 // The documentation for these functions should be in | 910 // The documentation for these functions should be in |
| 911 // content/common/*_messages.h for the message that the function is handling. | 911 // content/common/*_messages.h for the message that the function is handling. |
| 912 | 912 |
| 913 void OnCopy(); | 913 void OnCopy(); |
| 914 void OnCut(); | 914 void OnCut(); |
| 915 void OnDelete(); | 915 void OnDelete(); |
| 916 void OnExecuteEditCommand(const std::string& name, const std::string& value); | 916 void OnExecuteEditCommand(const std::string& name, const std::string& value); |
| (...skipping 21 matching lines...) Expand all Loading... |
| 938 const std::string& css); | 938 const std::string& css); |
| 939 void OnCustomContextMenuAction(const CustomContextMenuContext& custom_context, | 939 void OnCustomContextMenuAction(const CustomContextMenuContext& custom_context, |
| 940 unsigned action); | 940 unsigned action); |
| 941 void OnSetName(const std::string& name); | 941 void OnSetName(const std::string& name); |
| 942 void OnDeterminePageLanguage(); | 942 void OnDeterminePageLanguage(); |
| 943 void OnDisableScrollbarsForSmallWindows( | 943 void OnDisableScrollbarsForSmallWindows( |
| 944 const gfx::Size& disable_scrollbars_size_limit); | 944 const gfx::Size& disable_scrollbars_size_limit); |
| 945 void OnDragSourceEndedOrMoved(const gfx::Point& client_point, | 945 void OnDragSourceEndedOrMoved(const gfx::Point& client_point, |
| 946 const gfx::Point& screen_point, | 946 const gfx::Point& screen_point, |
| 947 bool ended, | 947 bool ended, |
| 948 WebKit::WebDragOperation drag_operation); | 948 blink::WebDragOperation drag_operation); |
| 949 void OnDragSourceSystemDragEnded(); | 949 void OnDragSourceSystemDragEnded(); |
| 950 void OnDragTargetDrop(const gfx::Point& client_pt, | 950 void OnDragTargetDrop(const gfx::Point& client_pt, |
| 951 const gfx::Point& screen_pt, | 951 const gfx::Point& screen_pt, |
| 952 int key_modifiers); | 952 int key_modifiers); |
| 953 void OnDragTargetDragEnter(const DropData& drop_data, | 953 void OnDragTargetDragEnter(const DropData& drop_data, |
| 954 const gfx::Point& client_pt, | 954 const gfx::Point& client_pt, |
| 955 const gfx::Point& screen_pt, | 955 const gfx::Point& screen_pt, |
| 956 WebKit::WebDragOperationsMask operations_allowed, | 956 blink::WebDragOperationsMask operations_allowed, |
| 957 int key_modifiers); | 957 int key_modifiers); |
| 958 void OnDragTargetDragLeave(); | 958 void OnDragTargetDragLeave(); |
| 959 void OnDragTargetDragOver(const gfx::Point& client_pt, | 959 void OnDragTargetDragOver(const gfx::Point& client_pt, |
| 960 const gfx::Point& screen_pt, | 960 const gfx::Point& screen_pt, |
| 961 WebKit::WebDragOperationsMask operations_allowed, | 961 blink::WebDragOperationsMask operations_allowed, |
| 962 int key_modifiers); | 962 int key_modifiers); |
| 963 void OnEnablePreferredSizeChangedMode(); | 963 void OnEnablePreferredSizeChangedMode(); |
| 964 void OnEnableAutoResize(const gfx::Size& min_size, const gfx::Size& max_size); | 964 void OnEnableAutoResize(const gfx::Size& min_size, const gfx::Size& max_size); |
| 965 void OnDisableAutoResize(const gfx::Size& new_size); | 965 void OnDisableAutoResize(const gfx::Size& new_size); |
| 966 void OnEnumerateDirectoryResponse(int id, | 966 void OnEnumerateDirectoryResponse(int id, |
| 967 const std::vector<base::FilePath>& paths); | 967 const std::vector<base::FilePath>& paths); |
| 968 void OnExtendSelectionAndDelete(int before, int after); | 968 void OnExtendSelectionAndDelete(int before, int after); |
| 969 void OnFileChooserResponse( | 969 void OnFileChooserResponse( |
| 970 const std::vector<ui::SelectedFileInfo>& files); | 970 const std::vector<ui::SelectedFileInfo>& files); |
| 971 void OnFind(int request_id, const string16&, const WebKit::WebFindOptions&); | 971 void OnFind(int request_id, const string16&, const blink::WebFindOptions&); |
| 972 void OnGetAllSavableResourceLinksForCurrentPage(const GURL& page_url); | 972 void OnGetAllSavableResourceLinksForCurrentPage(const GURL& page_url); |
| 973 void OnGetSerializedHtmlDataForCurrentPageWithLocalLinks( | 973 void OnGetSerializedHtmlDataForCurrentPageWithLocalLinks( |
| 974 const std::vector<GURL>& links, | 974 const std::vector<GURL>& links, |
| 975 const std::vector<base::FilePath>& local_paths, | 975 const std::vector<base::FilePath>& local_paths, |
| 976 const base::FilePath& local_directory_name); | 976 const base::FilePath& local_directory_name); |
| 977 void OnMediaPlayerActionAt(const gfx::Point& location, | 977 void OnMediaPlayerActionAt(const gfx::Point& location, |
| 978 const WebKit::WebMediaPlayerAction& action); | 978 const blink::WebMediaPlayerAction& action); |
| 979 void OnOrientationChangeEvent(int orientation); | 979 void OnOrientationChangeEvent(int orientation); |
| 980 void OnPluginActionAt(const gfx::Point& location, | 980 void OnPluginActionAt(const gfx::Point& location, |
| 981 const WebKit::WebPluginAction& action); | 981 const blink::WebPluginAction& action); |
| 982 void OnMoveOrResizeStarted(); | 982 void OnMoveOrResizeStarted(); |
| 983 void OnNavigate(const ViewMsg_Navigate_Params& params); | 983 void OnNavigate(const ViewMsg_Navigate_Params& params); |
| 984 void OnPostMessageEvent(const ViewMsg_PostMessage_Params& params); | 984 void OnPostMessageEvent(const ViewMsg_PostMessage_Params& params); |
| 985 void OnReleaseDisambiguationPopupDIB(TransportDIB::Handle dib_handle); | 985 void OnReleaseDisambiguationPopupDIB(TransportDIB::Handle dib_handle); |
| 986 void OnReloadFrame(); | 986 void OnReloadFrame(); |
| 987 void OnResetPageEncodingToDefault(); | 987 void OnResetPageEncodingToDefault(); |
| 988 void OnScriptEvalRequest(const string16& frame_xpath, | 988 void OnScriptEvalRequest(const string16& frame_xpath, |
| 989 const string16& jscript, | 989 const string16& jscript, |
| 990 int id, | 990 int id, |
| 991 bool notify_result); | 991 bool notify_result); |
| 992 void OnSetAccessibilityMode(AccessibilityMode new_mode); | 992 void OnSetAccessibilityMode(AccessibilityMode new_mode); |
| 993 void OnSetActive(bool active); | 993 void OnSetActive(bool active); |
| 994 void OnSetAltErrorPageURL(const GURL& gurl); | 994 void OnSetAltErrorPageURL(const GURL& gurl); |
| 995 void OnSetBackground(const SkBitmap& background); | 995 void OnSetBackground(const SkBitmap& background); |
| 996 void OnSetCompositionFromExistingText( | 996 void OnSetCompositionFromExistingText( |
| 997 int start, int end, | 997 int start, int end, |
| 998 const std::vector<WebKit::WebCompositionUnderline>& underlines); | 998 const std::vector<blink::WebCompositionUnderline>& underlines); |
| 999 void OnExitFullscreen(); | 999 void OnExitFullscreen(); |
| 1000 void OnSetEditableSelectionOffsets(int start, int end); | 1000 void OnSetEditableSelectionOffsets(int start, int end); |
| 1001 void OnSetHistoryLengthAndPrune(int history_length, int32 minimum_page_id); | 1001 void OnSetHistoryLengthAndPrune(int history_length, int32 minimum_page_id); |
| 1002 void OnSetInitialFocus(bool reverse); | 1002 void OnSetInitialFocus(bool reverse); |
| 1003 void OnSetPageEncoding(const std::string& encoding_name); | 1003 void OnSetPageEncoding(const std::string& encoding_name); |
| 1004 void OnSetRendererPrefs(const RendererPreferences& renderer_prefs); | 1004 void OnSetRendererPrefs(const RendererPreferences& renderer_prefs); |
| 1005 void OnSetWebUIProperty(const std::string& name, const std::string& value); | 1005 void OnSetWebUIProperty(const std::string& name, const std::string& value); |
| 1006 void OnSetZoomLevel(double zoom_level); | 1006 void OnSetZoomLevel(double zoom_level); |
| 1007 void OnSetZoomLevelForLoadingURL(const GURL& url, double zoom_level); | 1007 void OnSetZoomLevelForLoadingURL(const GURL& url, double zoom_level); |
| 1008 void OnShouldClose(); | 1008 void OnShouldClose(); |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1041 const gfx::Rect& view_frame); | 1041 const gfx::Rect& view_frame); |
| 1042 #endif | 1042 #endif |
| 1043 | 1043 |
| 1044 // Adding a new message handler? Please add it in alphabetical order above | 1044 // Adding a new message handler? Please add it in alphabetical order above |
| 1045 // and put it in the same position in the .cc file. | 1045 // and put it in the same position in the .cc file. |
| 1046 | 1046 |
| 1047 // Misc private functions ---------------------------------------------------- | 1047 // Misc private functions ---------------------------------------------------- |
| 1048 void ZoomFactorHelper(PageZoom zoom, int zoom_center_x, int zoom_center_y, | 1048 void ZoomFactorHelper(PageZoom zoom, int zoom_center_x, int zoom_center_y, |
| 1049 float scaling_increment); | 1049 float scaling_increment); |
| 1050 | 1050 |
| 1051 void AltErrorPageFinished(WebKit::WebFrame* frame, | 1051 void AltErrorPageFinished(blink::WebFrame* frame, |
| 1052 const WebKit::WebURLRequest& original_request, | 1052 const blink::WebURLRequest& original_request, |
| 1053 const WebKit::WebURLError& original_error, | 1053 const blink::WebURLError& original_error, |
| 1054 const std::string& html); | 1054 const std::string& html); |
| 1055 | 1055 |
| 1056 // Check whether the preferred size has changed. | 1056 // Check whether the preferred size has changed. |
| 1057 void CheckPreferredSize(); | 1057 void CheckPreferredSize(); |
| 1058 | 1058 |
| 1059 // Initializes |media_stream_client_|, returning true if successful. Returns | 1059 // Initializes |media_stream_client_|, returning true if successful. Returns |
| 1060 // false if it wasn't possible to create a MediaStreamClient (e.g., WebRTC is | 1060 // false if it wasn't possible to create a MediaStreamClient (e.g., WebRTC is |
| 1061 // disabled) in which case |media_stream_client_| is NULL. | 1061 // disabled) in which case |media_stream_client_| is NULL. |
| 1062 bool InitializeMediaStreamClient(); | 1062 bool InitializeMediaStreamClient(); |
| 1063 | 1063 |
| 1064 // This callback is triggered when DownloadFavicon completes, either | 1064 // This callback is triggered when DownloadFavicon completes, either |
| 1065 // succesfully or with a failure. See DownloadFavicon for more | 1065 // succesfully or with a failure. See DownloadFavicon for more |
| 1066 // details. | 1066 // details. |
| 1067 void DidDownloadFavicon(ImageResourceFetcher* fetcher, | 1067 void DidDownloadFavicon(ImageResourceFetcher* fetcher, |
| 1068 const SkBitmap& image); | 1068 const SkBitmap& image); |
| 1069 | 1069 |
| 1070 // Requests to download a favicon image. When done, the RenderView is notified | 1070 // Requests to download a favicon image. When done, the RenderView is notified |
| 1071 // by way of DidDownloadFavicon. Returns true if the request was successfully | 1071 // by way of DidDownloadFavicon. Returns true if the request was successfully |
| 1072 // started, false otherwise. id is used to uniquely identify the request and | 1072 // started, false otherwise. id is used to uniquely identify the request and |
| 1073 // passed back to the DidDownloadFavicon method. If the image has multiple | 1073 // passed back to the DidDownloadFavicon method. If the image has multiple |
| 1074 // frames, the frame whose size is image_size is returned. If the image | 1074 // frames, the frame whose size is image_size is returned. If the image |
| 1075 // doesn't have a frame at the specified size, the first is returned. | 1075 // doesn't have a frame at the specified size, the first is returned. |
| 1076 bool DownloadFavicon(int id, const GURL& image_url, int image_size); | 1076 bool DownloadFavicon(int id, const GURL& image_url, int image_size); |
| 1077 | 1077 |
| 1078 GURL GetAlternateErrorPageURL(const GURL& failed_url, | 1078 GURL GetAlternateErrorPageURL(const GURL& failed_url, |
| 1079 ErrorPageType error_type); | 1079 ErrorPageType error_type); |
| 1080 | 1080 |
| 1081 // Locates a sub frame with given xpath | 1081 // Locates a sub frame with given xpath |
| 1082 WebKit::WebFrame* GetChildFrame(const string16& frame_xpath) const; | 1082 blink::WebFrame* GetChildFrame(const string16& frame_xpath) const; |
| 1083 | 1083 |
| 1084 // Returns the URL being loaded by the given frame's request. | 1084 // Returns the URL being loaded by the given frame's request. |
| 1085 GURL GetLoadingUrl(WebKit::WebFrame* frame) const; | 1085 GURL GetLoadingUrl(blink::WebFrame* frame) const; |
| 1086 | 1086 |
| 1087 // Should only be called if this object wraps a PluginDocument. | 1087 // Should only be called if this object wraps a PluginDocument. |
| 1088 WebKit::WebPlugin* GetWebPluginFromPluginDocument(); | 1088 blink::WebPlugin* GetWebPluginFromPluginDocument(); |
| 1089 | 1089 |
| 1090 // Returns true if the |params| navigation is to an entry that has been | 1090 // Returns true if the |params| navigation is to an entry that has been |
| 1091 // cropped due to a recent navigation the browser did not know about. | 1091 // cropped due to a recent navigation the browser did not know about. |
| 1092 bool IsBackForwardToStaleEntry(const ViewMsg_Navigate_Params& params, | 1092 bool IsBackForwardToStaleEntry(const ViewMsg_Navigate_Params& params, |
| 1093 bool is_reload); | 1093 bool is_reload); |
| 1094 | 1094 |
| 1095 bool MaybeLoadAlternateErrorPage(WebKit::WebFrame* frame, | 1095 bool MaybeLoadAlternateErrorPage(blink::WebFrame* frame, |
| 1096 const WebKit::WebURLError& error, | 1096 const blink::WebURLError& error, |
| 1097 bool replace); | 1097 bool replace); |
| 1098 | 1098 |
| 1099 // Make this RenderView show an empty, unscriptable page. | 1099 // Make this RenderView show an empty, unscriptable page. |
| 1100 void NavigateToSwappedOutURL(WebKit::WebFrame* frame); | 1100 void NavigateToSwappedOutURL(blink::WebFrame* frame); |
| 1101 | 1101 |
| 1102 // If we initiated a navigation, this function will populate |document_state| | 1102 // If we initiated a navigation, this function will populate |document_state| |
| 1103 // with the navigation information saved in OnNavigate(). | 1103 // with the navigation information saved in OnNavigate(). |
| 1104 void PopulateDocumentStateFromPending(DocumentState* document_state); | 1104 void PopulateDocumentStateFromPending(DocumentState* document_state); |
| 1105 | 1105 |
| 1106 // Returns a new NavigationState populated with the navigation information | 1106 // Returns a new NavigationState populated with the navigation information |
| 1107 // saved in OnNavigate(). | 1107 // saved in OnNavigate(). |
| 1108 NavigationState* CreateNavigationStateFromPending(); | 1108 NavigationState* CreateNavigationStateFromPending(); |
| 1109 | 1109 |
| 1110 // Processes the command-line flags --enable-viewport, | 1110 // Processes the command-line flags --enable-viewport, |
| 1111 // --enable-fixed-layout[=w,h] and --enable-pinch. | 1111 // --enable-fixed-layout[=w,h] and --enable-pinch. |
| 1112 void ProcessViewLayoutFlags(const CommandLine& command_line); | 1112 void ProcessViewLayoutFlags(const CommandLine& command_line); |
| 1113 | 1113 |
| 1114 #if defined(OS_ANDROID) | 1114 #if defined(OS_ANDROID) |
| 1115 // Launch an Android content intent with the given URL. | 1115 // Launch an Android content intent with the given URL. |
| 1116 void LaunchAndroidContentIntent(const GURL& intent_url, size_t request_id); | 1116 void LaunchAndroidContentIntent(const GURL& intent_url, size_t request_id); |
| 1117 | 1117 |
| 1118 WebKit::WebMediaPlayer* CreateAndroidWebMediaPlayer( | 1118 blink::WebMediaPlayer* CreateAndroidWebMediaPlayer( |
| 1119 WebKit::WebFrame* frame, | 1119 blink::WebFrame* frame, |
| 1120 const WebKit::WebURL& url, | 1120 const blink::WebURL& url, |
| 1121 WebKit::WebMediaPlayerClient* client); | 1121 blink::WebMediaPlayerClient* client); |
| 1122 #endif | 1122 #endif |
| 1123 | 1123 |
| 1124 WebKit::WebMediaPlayer* CreateWebMediaPlayerForMediaStream( | 1124 blink::WebMediaPlayer* CreateWebMediaPlayerForMediaStream( |
| 1125 WebKit::WebFrame* frame, | 1125 blink::WebFrame* frame, |
| 1126 const WebKit::WebURL& url, | 1126 const blink::WebURL& url, |
| 1127 WebKit::WebMediaPlayerClient* client); | 1127 blink::WebMediaPlayerClient* client); |
| 1128 | 1128 |
| 1129 // Sends a reply to the current find operation handling if it was a | 1129 // Sends a reply to the current find operation handling if it was a |
| 1130 // synchronous find request. | 1130 // synchronous find request. |
| 1131 void SendFindReply(int request_id, | 1131 void SendFindReply(int request_id, |
| 1132 int match_count, | 1132 int match_count, |
| 1133 int ordinal, | 1133 int ordinal, |
| 1134 const WebKit::WebRect& selection_rect, | 1134 const blink::WebRect& selection_rect, |
| 1135 bool final_status_update); | 1135 bool final_status_update); |
| 1136 | 1136 |
| 1137 // Returns whether |params.selection_text| should be synchronized to the | 1137 // Returns whether |params.selection_text| should be synchronized to the |
| 1138 // browser before bringing up the context menu. Static for testing. | 1138 // browser before bringing up the context menu. Static for testing. |
| 1139 static bool ShouldUpdateSelectionTextFromContextMenuParams( | 1139 static bool ShouldUpdateSelectionTextFromContextMenuParams( |
| 1140 const string16& selection_text, | 1140 const string16& selection_text, |
| 1141 size_t selection_text_offset, | 1141 size_t selection_text_offset, |
| 1142 const gfx::Range& selection_range, | 1142 const gfx::Range& selection_range, |
| 1143 const ContextMenuParams& params); | 1143 const ContextMenuParams& params); |
| 1144 | 1144 |
| (...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1409 DeviceOrientationDispatcher* device_orientation_dispatcher_; | 1409 DeviceOrientationDispatcher* device_orientation_dispatcher_; |
| 1410 | 1410 |
| 1411 // MediaStream dispatcher attached to this view; lazily initialized. | 1411 // MediaStream dispatcher attached to this view; lazily initialized. |
| 1412 MediaStreamDispatcher* media_stream_dispatcher_; | 1412 MediaStreamDispatcher* media_stream_dispatcher_; |
| 1413 | 1413 |
| 1414 // BrowserPluginManager attached to this view; lazily initialized. | 1414 // BrowserPluginManager attached to this view; lazily initialized. |
| 1415 scoped_refptr<BrowserPluginManager> browser_plugin_manager_; | 1415 scoped_refptr<BrowserPluginManager> browser_plugin_manager_; |
| 1416 | 1416 |
| 1417 // MediaStreamClient attached to this view; lazily initialized. | 1417 // MediaStreamClient attached to this view; lazily initialized. |
| 1418 MediaStreamClient* media_stream_client_; | 1418 MediaStreamClient* media_stream_client_; |
| 1419 WebKit::WebUserMediaClient* web_user_media_client_; | 1419 blink::WebUserMediaClient* web_user_media_client_; |
| 1420 | 1420 |
| 1421 // MIDIClient attached to this view; lazily initialized. | 1421 // MIDIClient attached to this view; lazily initialized. |
| 1422 MIDIDispatcher* midi_dispatcher_; | 1422 MIDIDispatcher* midi_dispatcher_; |
| 1423 | 1423 |
| 1424 DevToolsAgent* devtools_agent_; | 1424 DevToolsAgent* devtools_agent_; |
| 1425 | 1425 |
| 1426 // The current accessibility mode. | 1426 // The current accessibility mode. |
| 1427 AccessibilityMode accessibility_mode_; | 1427 AccessibilityMode accessibility_mode_; |
| 1428 | 1428 |
| 1429 // Only valid if |accessibility_mode_| is anything other than | 1429 // Only valid if |accessibility_mode_| is anything other than |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1490 // Misc ---------------------------------------------------------------------- | 1490 // Misc ---------------------------------------------------------------------- |
| 1491 | 1491 |
| 1492 // The current and pending file chooser completion objects. If the queue is | 1492 // The current and pending file chooser completion objects. If the queue is |
| 1493 // nonempty, the first item represents the currently running file chooser | 1493 // nonempty, the first item represents the currently running file chooser |
| 1494 // callback, and the remaining elements are the other file chooser completion | 1494 // callback, and the remaining elements are the other file chooser completion |
| 1495 // still waiting to be run (in order). | 1495 // still waiting to be run (in order). |
| 1496 struct PendingFileChooser; | 1496 struct PendingFileChooser; |
| 1497 std::deque< linked_ptr<PendingFileChooser> > file_chooser_completions_; | 1497 std::deque< linked_ptr<PendingFileChooser> > file_chooser_completions_; |
| 1498 | 1498 |
| 1499 // The current directory enumeration callback | 1499 // The current directory enumeration callback |
| 1500 std::map<int, WebKit::WebFileChooserCompletion*> enumeration_completions_; | 1500 std::map<int, blink::WebFileChooserCompletion*> enumeration_completions_; |
| 1501 int enumeration_completion_id_; | 1501 int enumeration_completion_id_; |
| 1502 | 1502 |
| 1503 // Reports load progress to the browser. | 1503 // Reports load progress to the browser. |
| 1504 scoped_ptr<LoadProgressTracker> load_progress_tracker_; | 1504 scoped_ptr<LoadProgressTracker> load_progress_tracker_; |
| 1505 | 1505 |
| 1506 // The SessionStorage namespace that we're assigned to has an ID, and that ID | 1506 // The SessionStorage namespace that we're assigned to has an ID, and that ID |
| 1507 // is passed to us upon creation. WebKit asks for this ID upon first use and | 1507 // is passed to us upon creation. WebKit asks for this ID upon first use and |
| 1508 // uses it whenever asking the browser process to allocate new storage areas. | 1508 // uses it whenever asking the browser process to allocate new storage areas. |
| 1509 int64 session_storage_namespace_id_; | 1509 int64 session_storage_namespace_id_; |
| 1510 | 1510 |
| 1511 // Stores edit commands associated to the next key event. | 1511 // Stores edit commands associated to the next key event. |
| 1512 // Shall be cleared as soon as the next key event is processed. | 1512 // Shall be cleared as soon as the next key event is processed. |
| 1513 EditCommands edit_commands_; | 1513 EditCommands edit_commands_; |
| 1514 | 1514 |
| 1515 // The external popup for the currently showing select popup. | 1515 // The external popup for the currently showing select popup. |
| 1516 scoped_ptr<ExternalPopupMenu> external_popup_menu_; | 1516 scoped_ptr<ExternalPopupMenu> external_popup_menu_; |
| 1517 | 1517 |
| 1518 // The node that the context menu was pressed over. | 1518 // The node that the context menu was pressed over. |
| 1519 WebKit::WebNode context_menu_node_; | 1519 blink::WebNode context_menu_node_; |
| 1520 | 1520 |
| 1521 // All the registered observers. We expect this list to be small, so vector | 1521 // All the registered observers. We expect this list to be small, so vector |
| 1522 // is fine. | 1522 // is fine. |
| 1523 ObserverList<RenderViewObserver> observers_; | 1523 ObserverList<RenderViewObserver> observers_; |
| 1524 | 1524 |
| 1525 // Used to inform didChangeSelection() when it is called in the context | 1525 // Used to inform didChangeSelection() when it is called in the context |
| 1526 // of handling a InputMsg_SelectRange IPC. | 1526 // of handling a InputMsg_SelectRange IPC. |
| 1527 bool handling_select_range_; | 1527 bool handling_select_range_; |
| 1528 | 1528 |
| 1529 // Wraps the |webwidget_| as a MouseLockDispatcher::LockTarget interface. | 1529 // Wraps the |webwidget_| as a MouseLockDispatcher::LockTarget interface. |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1566 // use the Observer interface to filter IPC messages and receive frame change | 1566 // use the Observer interface to filter IPC messages and receive frame change |
| 1567 // notifications. | 1567 // notifications. |
| 1568 // --------------------------------------------------------------------------- | 1568 // --------------------------------------------------------------------------- |
| 1569 | 1569 |
| 1570 DISALLOW_COPY_AND_ASSIGN(RenderViewImpl); | 1570 DISALLOW_COPY_AND_ASSIGN(RenderViewImpl); |
| 1571 }; | 1571 }; |
| 1572 | 1572 |
| 1573 } // namespace content | 1573 } // namespace content |
| 1574 | 1574 |
| 1575 #endif // CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ | 1575 #endif // CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ |
| OLD | NEW |