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 { | 54 namespace service_manager { |
55 class InterfaceProvider; | 55 class InterfaceProvider; |
56 } | 56 } |
57 | 57 |
58 namespace content { | 58 namespace content { |
59 class BrowserPluginEmbedder; | 59 class BrowserPluginEmbedder; |
60 class BrowserPluginGuest; | 60 class BrowserPluginGuest; |
61 class DateTimeChooserAndroid; | 61 class DateTimeChooserAndroid; |
62 class DownloadItem; | 62 class DownloadItem; |
63 class FindRequestManager; | 63 class FindRequestManager; |
64 class InterstitialPageImpl; | 64 class InterstitialPageImpl; |
(...skipping 351 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
416 void SuspendMediaSession() override; | 416 void SuspendMediaSession() override; |
417 void StopMediaSession() override; | 417 void StopMediaSession() override; |
418 void OnPasswordInputShownOnHttp() override; | 418 void OnPasswordInputShownOnHttp() override; |
419 void OnCreditCardInputShownOnHttp() override; | 419 void OnCreditCardInputShownOnHttp() override; |
420 | 420 |
421 #if defined(OS_ANDROID) | 421 #if defined(OS_ANDROID) |
422 base::android::ScopedJavaLocalRef<jobject> GetJavaWebContents() override; | 422 base::android::ScopedJavaLocalRef<jobject> GetJavaWebContents() override; |
423 virtual WebContentsAndroid* GetWebContentsAndroid(); | 423 virtual WebContentsAndroid* GetWebContentsAndroid(); |
424 void ActivateNearestFindResult(float x, float y) override; | 424 void ActivateNearestFindResult(float x, float y) override; |
425 void RequestFindMatchRects(int current_version) override; | 425 void RequestFindMatchRects(int current_version) override; |
426 shell::InterfaceProvider* GetJavaInterfaces() override; | 426 service_manager::InterfaceProvider* GetJavaInterfaces() override; |
427 #elif defined(OS_MACOSX) | 427 #elif defined(OS_MACOSX) |
428 void SetAllowOtherViews(bool allow) override; | 428 void SetAllowOtherViews(bool allow) override; |
429 bool GetAllowOtherViews() override; | 429 bool GetAllowOtherViews() override; |
430 #endif | 430 #endif |
431 | 431 |
432 // This method is called when the MediaSession state has changed, and will | 432 // This method is called when the MediaSession state has changed, and will |
433 // notify the WebContents observers. | 433 // notify the WebContents observers. |
434 void OnMediaSessionStateChanged(); | 434 void OnMediaSessionStateChanged(); |
435 // This method is called when the MediaSession metadata has changed, and will | 435 // This method is called when the MediaSession metadata has changed, and will |
436 // notify the WebContents observers. | 436 // notify the WebContents observers. |
(...skipping 984 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1421 // inner WebContents by attaching to an outer WebContents. Then the | 1421 // inner WebContents by attaching to an outer WebContents. Then the |
1422 // IME-related state for RenderWidgetHosts on the inner WebContents is tracked | 1422 // IME-related state for RenderWidgetHosts on the inner WebContents is tracked |
1423 // by the TextInputManager in the outer WebContents. | 1423 // by the TextInputManager in the outer WebContents. |
1424 std::unique_ptr<TextInputManager> text_input_manager_; | 1424 std::unique_ptr<TextInputManager> text_input_manager_; |
1425 | 1425 |
1426 // Stores the RenderWidgetHost that currently holds a mouse lock or nullptr if | 1426 // Stores the RenderWidgetHost that currently holds a mouse lock or nullptr if |
1427 // there's no RenderWidgetHost holding a lock. | 1427 // there's no RenderWidgetHost holding a lock. |
1428 RenderWidgetHostImpl* mouse_lock_widget_; | 1428 RenderWidgetHostImpl* mouse_lock_widget_; |
1429 | 1429 |
1430 #if defined(OS_ANDROID) | 1430 #if defined(OS_ANDROID) |
1431 std::unique_ptr<shell::InterfaceProvider> java_interfaces_; | 1431 std::unique_ptr<service_manager::InterfaceProvider> java_interfaces_; |
1432 #endif | 1432 #endif |
1433 | 1433 |
1434 base::WeakPtrFactory<WebContentsImpl> loading_weak_factory_; | 1434 base::WeakPtrFactory<WebContentsImpl> loading_weak_factory_; |
1435 base::WeakPtrFactory<WebContentsImpl> weak_factory_; | 1435 base::WeakPtrFactory<WebContentsImpl> weak_factory_; |
1436 | 1436 |
1437 DISALLOW_COPY_AND_ASSIGN(WebContentsImpl); | 1437 DISALLOW_COPY_AND_ASSIGN(WebContentsImpl); |
1438 }; | 1438 }; |
1439 | 1439 |
1440 // Dangerous methods which should never be made part of the public API, so we | 1440 // Dangerous methods which should never be made part of the public API, so we |
1441 // grant their use only to an explicit friend list (c++ attorney/client idiom). | 1441 // grant their use only to an explicit friend list (c++ attorney/client idiom). |
1442 class CONTENT_EXPORT WebContentsImpl::FriendZone { | 1442 class CONTENT_EXPORT WebContentsImpl::FriendZone { |
1443 private: | 1443 private: |
1444 friend class TestNavigationObserver; | 1444 friend class TestNavigationObserver; |
1445 friend class WebContentsAddedObserver; | 1445 friend class WebContentsAddedObserver; |
1446 friend class ContentBrowserSanityChecker; | 1446 friend class ContentBrowserSanityChecker; |
1447 | 1447 |
1448 FriendZone(); // Not instantiable. | 1448 FriendZone(); // Not instantiable. |
1449 | 1449 |
1450 // Adds/removes a callback called on creation of each new WebContents. | 1450 // Adds/removes a callback called on creation of each new WebContents. |
1451 static void AddCreatedCallbackForTesting(const CreatedCallback& callback); | 1451 static void AddCreatedCallbackForTesting(const CreatedCallback& callback); |
1452 static void RemoveCreatedCallbackForTesting(const CreatedCallback& callback); | 1452 static void RemoveCreatedCallbackForTesting(const CreatedCallback& callback); |
1453 | 1453 |
1454 DISALLOW_COPY_AND_ASSIGN(FriendZone); | 1454 DISALLOW_COPY_AND_ASSIGN(FriendZone); |
1455 }; | 1455 }; |
1456 | 1456 |
1457 } // namespace content | 1457 } // namespace content |
1458 | 1458 |
1459 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 1459 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
OLD | NEW |