| 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_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
| 6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <functional> | 10 #include <functional> |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 #include "content/public/common/three_d_api_types.h" | 44 #include "content/public/common/three_d_api_types.h" |
| 45 #include "net/base/load_states.h" | 45 #include "net/base/load_states.h" |
| 46 #include "net/http/http_response_headers.h" | 46 #include "net/http/http_response_headers.h" |
| 47 #include "third_party/WebKit/public/platform/WebDragOperation.h" | 47 #include "third_party/WebKit/public/platform/WebDragOperation.h" |
| 48 #include "ui/base/page_transition_types.h" | 48 #include "ui/base/page_transition_types.h" |
| 49 #include "ui/gfx/geometry/rect_f.h" | 49 #include "ui/gfx/geometry/rect_f.h" |
| 50 #include "ui/gfx/geometry/size.h" | 50 #include "ui/gfx/geometry/size.h" |
| 51 | 51 |
| 52 struct ViewHostMsg_DateTimeDialogValue_Params; | 52 struct ViewHostMsg_DateTimeDialogValue_Params; |
| 53 | 53 |
| 54 namespace shell { |
| 55 class InterfaceProvider; |
| 56 } |
| 57 |
| 54 namespace content { | 58 namespace content { |
| 55 class BrowserPluginEmbedder; | 59 class BrowserPluginEmbedder; |
| 56 class BrowserPluginGuest; | 60 class BrowserPluginGuest; |
| 57 class DateTimeChooserAndroid; | 61 class DateTimeChooserAndroid; |
| 58 class DownloadItem; | 62 class DownloadItem; |
| 59 class FindRequestManager; | 63 class FindRequestManager; |
| 60 class InterstitialPageImpl; | 64 class InterstitialPageImpl; |
| 61 class JavaScriptDialogManager; | 65 class JavaScriptDialogManager; |
| 62 class LoaderIOThreadNotifier; | 66 class LoaderIOThreadNotifier; |
| 63 class ManifestManagerHost; | 67 class ManifestManagerHost; |
| (...skipping 344 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 408 void OnMediaSessionStateChanged(); | 412 void OnMediaSessionStateChanged(); |
| 409 void ResumeMediaSession() override; | 413 void ResumeMediaSession() override; |
| 410 void SuspendMediaSession() override; | 414 void SuspendMediaSession() override; |
| 411 void StopMediaSession() override; | 415 void StopMediaSession() override; |
| 412 | 416 |
| 413 #if defined(OS_ANDROID) | 417 #if defined(OS_ANDROID) |
| 414 base::android::ScopedJavaLocalRef<jobject> GetJavaWebContents() override; | 418 base::android::ScopedJavaLocalRef<jobject> GetJavaWebContents() override; |
| 415 virtual WebContentsAndroid* GetWebContentsAndroid(); | 419 virtual WebContentsAndroid* GetWebContentsAndroid(); |
| 416 void ActivateNearestFindResult(float x, float y) override; | 420 void ActivateNearestFindResult(float x, float y) override; |
| 417 void RequestFindMatchRects(int current_version) override; | 421 void RequestFindMatchRects(int current_version) override; |
| 422 shell::InterfaceProvider* GetJavaInterfaces() override; |
| 418 #elif defined(OS_MACOSX) | 423 #elif defined(OS_MACOSX) |
| 419 void SetAllowOtherViews(bool allow) override; | 424 void SetAllowOtherViews(bool allow) override; |
| 420 bool GetAllowOtherViews() override; | 425 bool GetAllowOtherViews() override; |
| 421 #endif | 426 #endif |
| 422 | 427 |
| 423 // Returns true if this is a secure page which has displayed content | 428 // Returns true if this is a secure page which has displayed content |
| 424 // loaded over insecure HTTP. | 429 // loaded over insecure HTTP. |
| 425 bool DisplayedInsecureContent() const; | 430 bool DisplayedInsecureContent() const; |
| 426 | 431 |
| 427 // Returns true if this page has displayed content loaded over HTTPS | 432 // Returns true if this page has displayed content loaded over HTTPS |
| (...skipping 1013 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1441 // WebContents and is automatically destroyed when a WebContents becomes an | 1446 // WebContents and is automatically destroyed when a WebContents becomes an |
| 1442 // inner WebContents by attaching to an outer WebContents. Then the | 1447 // inner WebContents by attaching to an outer WebContents. Then the |
| 1443 // IME-related state for RenderWidgetHosts on the inner WebContents is tracked | 1448 // IME-related state for RenderWidgetHosts on the inner WebContents is tracked |
| 1444 // by the TextInputManager in the outer WebContents. | 1449 // by the TextInputManager in the outer WebContents. |
| 1445 std::unique_ptr<TextInputManager> text_input_manager_; | 1450 std::unique_ptr<TextInputManager> text_input_manager_; |
| 1446 | 1451 |
| 1447 // Stores the RenderWidgetHost that currently holds a mouse lock or nullptr if | 1452 // Stores the RenderWidgetHost that currently holds a mouse lock or nullptr if |
| 1448 // there's no RenderWidgetHost holding a lock. | 1453 // there's no RenderWidgetHost holding a lock. |
| 1449 RenderWidgetHostImpl* mouse_lock_widget_; | 1454 RenderWidgetHostImpl* mouse_lock_widget_; |
| 1450 | 1455 |
| 1456 #if defined(OS_ANDROID) |
| 1457 std::unique_ptr<shell::InterfaceProvider> java_interfaces_; |
| 1458 #endif |
| 1459 |
| 1451 base::WeakPtrFactory<WebContentsImpl> loading_weak_factory_; | 1460 base::WeakPtrFactory<WebContentsImpl> loading_weak_factory_; |
| 1452 base::WeakPtrFactory<WebContentsImpl> weak_factory_; | 1461 base::WeakPtrFactory<WebContentsImpl> weak_factory_; |
| 1453 | 1462 |
| 1454 DISALLOW_COPY_AND_ASSIGN(WebContentsImpl); | 1463 DISALLOW_COPY_AND_ASSIGN(WebContentsImpl); |
| 1455 }; | 1464 }; |
| 1456 | 1465 |
| 1457 // Dangerous methods which should never be made part of the public API, so we | 1466 // Dangerous methods which should never be made part of the public API, so we |
| 1458 // grant their use only to an explicit friend list (c++ attorney/client idiom). | 1467 // grant their use only to an explicit friend list (c++ attorney/client idiom). |
| 1459 class CONTENT_EXPORT WebContentsImpl::FriendZone { | 1468 class CONTENT_EXPORT WebContentsImpl::FriendZone { |
| 1460 private: | 1469 private: |
| 1461 friend class TestNavigationObserver; | 1470 friend class TestNavigationObserver; |
| 1462 friend class WebContentsAddedObserver; | 1471 friend class WebContentsAddedObserver; |
| 1463 friend class ContentBrowserSanityChecker; | 1472 friend class ContentBrowserSanityChecker; |
| 1464 | 1473 |
| 1465 FriendZone(); // Not instantiable. | 1474 FriendZone(); // Not instantiable. |
| 1466 | 1475 |
| 1467 // Adds/removes a callback called on creation of each new WebContents. | 1476 // Adds/removes a callback called on creation of each new WebContents. |
| 1468 static void AddCreatedCallbackForTesting(const CreatedCallback& callback); | 1477 static void AddCreatedCallbackForTesting(const CreatedCallback& callback); |
| 1469 static void RemoveCreatedCallbackForTesting(const CreatedCallback& callback); | 1478 static void RemoveCreatedCallbackForTesting(const CreatedCallback& callback); |
| 1470 | 1479 |
| 1471 DISALLOW_COPY_AND_ASSIGN(FriendZone); | 1480 DISALLOW_COPY_AND_ASSIGN(FriendZone); |
| 1472 }; | 1481 }; |
| 1473 | 1482 |
| 1474 } // namespace content | 1483 } // namespace content |
| 1475 | 1484 |
| 1476 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 1485 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
| OLD | NEW |