| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_H_ | 5 #ifndef CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_H_ |
| 6 #define CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_H_ | 6 #define CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| 11 | 11 |
| 12 #include "base/process_util.h" | 12 #include "base/process_util.h" |
| 13 #include "base/scoped_ptr.h" | 13 #include "base/scoped_ptr.h" |
| 14 #include "chrome/browser/renderer_host/render_widget_host.h" | 14 #include "chrome/browser/renderer_host/render_widget_host.h" |
| 15 #include "chrome/browser/ui/find_bar/find_bar_controller.h" | 15 #include "chrome/browser/ui/find_bar/find_bar_controller.h" |
| 16 #include "chrome/common/content_settings_types.h" | 16 #include "chrome/common/content_settings_types.h" |
| 17 #include "chrome/common/extensions/extension.h" |
| 17 #include "chrome/common/page_zoom.h" | 18 #include "chrome/common/page_zoom.h" |
| 18 #include "chrome/common/translate_errors.h" | 19 #include "chrome/common/translate_errors.h" |
| 19 #include "chrome/common/view_types.h" | 20 #include "chrome/common/view_types.h" |
| 20 #include "chrome/common/window_container_type.h" | 21 #include "chrome/common/window_container_type.h" |
| 21 #include "net/base/load_states.h" | 22 #include "net/base/load_states.h" |
| 22 #include "third_party/WebKit/Source/WebKit/chromium/public/WebConsoleMessage.h" | 23 #include "third_party/WebKit/Source/WebKit/chromium/public/WebConsoleMessage.h" |
| 23 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDragOperation.h" | 24 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDragOperation.h" |
| 24 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPopupType.h" | 25 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPopupType.h" |
| 25 #include "third_party/WebKit/Source/WebKit/chromium/public/WebTextDirection.h" | 26 #include "third_party/WebKit/Source/WebKit/chromium/public/WebTextDirection.h" |
| 26 #include "webkit/glue/webaccessibility.h" | 27 #include "webkit/glue/webaccessibility.h" |
| (...skipping 330 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 357 // Returns a bitwise OR of bindings types that have been enabled for this | 358 // Returns a bitwise OR of bindings types that have been enabled for this |
| 358 // RenderView. See BindingsPolicy for details. | 359 // RenderView. See BindingsPolicy for details. |
| 359 int enabled_bindings() const { return enabled_bindings_; } | 360 int enabled_bindings() const { return enabled_bindings_; } |
| 360 | 361 |
| 361 // See variable comment. | 362 // See variable comment. |
| 362 bool is_extension_process() const { return is_extension_process_; } | 363 bool is_extension_process() const { return is_extension_process_; } |
| 363 void set_is_extension_process(bool is_extension_process) { | 364 void set_is_extension_process(bool is_extension_process) { |
| 364 is_extension_process_ = is_extension_process; | 365 is_extension_process_ = is_extension_process; |
| 365 } | 366 } |
| 366 | 367 |
| 368 // See variable comment. |
| 369 const Extension* installed_app() { return installed_app_; } |
| 370 void set_installed_app(const Extension* app) { |
| 371 installed_app_ = app; |
| 372 } |
| 373 |
| 367 // Sets a property with the given name and value on the DOM UI binding object. | 374 // Sets a property with the given name and value on the DOM UI binding object. |
| 368 // Must call AllowDOMUIBindings() on this renderer first. | 375 // Must call AllowDOMUIBindings() on this renderer first. |
| 369 void SetDOMUIProperty(const std::string& name, const std::string& value); | 376 void SetDOMUIProperty(const std::string& name, const std::string& value); |
| 370 | 377 |
| 371 // Tells the renderer view to focus the first (last if reverse is true) node. | 378 // Tells the renderer view to focus the first (last if reverse is true) node. |
| 372 void SetInitialFocus(bool reverse); | 379 void SetInitialFocus(bool reverse); |
| 373 | 380 |
| 374 // Clears the node that is currently focused (if any). | 381 // Clears the node that is currently focused (if any). |
| 375 void ClearFocusedNode(); | 382 void ClearFocusedNode(); |
| 376 | 383 |
| (...skipping 398 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 775 // True if the render view can be shut down suddenly. | 782 // True if the render view can be shut down suddenly. |
| 776 bool sudden_termination_allowed_; | 783 bool sudden_termination_allowed_; |
| 777 | 784 |
| 778 // The session storage namespace to be used by the associated render view. | 785 // The session storage namespace to be used by the associated render view. |
| 779 scoped_refptr<SessionStorageNamespace> session_storage_namespace_; | 786 scoped_refptr<SessionStorageNamespace> session_storage_namespace_; |
| 780 | 787 |
| 781 // Whether this render view will get extension api bindings. This controls | 788 // Whether this render view will get extension api bindings. This controls |
| 782 // what process type we use. | 789 // what process type we use. |
| 783 bool is_extension_process_; | 790 bool is_extension_process_; |
| 784 | 791 |
| 792 // The Extension object if this is a hosted or packaged app, NULL otherwise. |
| 793 // This can affect the request context used by the renderer. |
| 794 scoped_refptr<const Extension> installed_app_; |
| 795 |
| 785 // Whether the accessibility tree should be saved, for unit testing. | 796 // Whether the accessibility tree should be saved, for unit testing. |
| 786 bool save_accessibility_tree_for_testing_; | 797 bool save_accessibility_tree_for_testing_; |
| 787 | 798 |
| 788 // The most recently received accessibility tree - for unit testing only. | 799 // The most recently received accessibility tree - for unit testing only. |
| 789 webkit_glue::WebAccessibility accessibility_tree_; | 800 webkit_glue::WebAccessibility accessibility_tree_; |
| 790 | 801 |
| 791 // The termination status of the last render view that terminated. | 802 // The termination status of the last render view that terminated. |
| 792 base::TerminationStatus render_view_termination_status_; | 803 base::TerminationStatus render_view_termination_status_; |
| 793 | 804 |
| 794 DISALLOW_COPY_AND_ASSIGN(RenderViewHost); | 805 DISALLOW_COPY_AND_ASSIGN(RenderViewHost); |
| 795 }; | 806 }; |
| 796 | 807 |
| 797 #endif // CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_H_ | 808 #endif // CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_H_ |
| OLD | NEW |