| 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 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 class PluginContentOriginWhitelist; | 66 class PluginContentOriginWhitelist; |
| 67 class PowerSaveBlocker; | 67 class PowerSaveBlocker; |
| 68 class RenderViewHost; | 68 class RenderViewHost; |
| 69 class RenderViewHostDelegateView; | 69 class RenderViewHostDelegateView; |
| 70 class RenderWidgetHostImpl; | 70 class RenderWidgetHostImpl; |
| 71 class RenderWidgetHostInputEventRouter; | 71 class RenderWidgetHostInputEventRouter; |
| 72 class SavePackage; | 72 class SavePackage; |
| 73 class ScreenOrientationDispatcherHost; | 73 class ScreenOrientationDispatcherHost; |
| 74 class SiteInstance; | 74 class SiteInstance; |
| 75 class TestWebContents; | 75 class TestWebContents; |
| 76 class TextInputManager; |
| 76 class WakeLockServiceContext; | 77 class WakeLockServiceContext; |
| 77 class WebContentsAudioMuter; | 78 class WebContentsAudioMuter; |
| 78 class WebContentsDelegate; | 79 class WebContentsDelegate; |
| 79 class WebContentsImpl; | 80 class WebContentsImpl; |
| 80 class WebContentsView; | 81 class WebContentsView; |
| 81 class WebContentsViewDelegate; | 82 class WebContentsViewDelegate; |
| 82 struct AXEventNotificationDetails; | 83 struct AXEventNotificationDetails; |
| 83 struct ColorSuggestion; | 84 struct ColorSuggestion; |
| 84 struct FaviconURL; | 85 struct FaviconURL; |
| 85 struct LoadNotificationDetails; | 86 struct LoadNotificationDetails; |
| (...skipping 537 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 623 RenderWidgetHostImpl* render_widget_host) const override; | 624 RenderWidgetHostImpl* render_widget_host) const override; |
| 624 blink::WebDisplayMode GetDisplayMode( | 625 blink::WebDisplayMode GetDisplayMode( |
| 625 RenderWidgetHostImpl* render_widget_host) const override; | 626 RenderWidgetHostImpl* render_widget_host) const override; |
| 626 void LostCapture(RenderWidgetHostImpl* render_widget_host) override; | 627 void LostCapture(RenderWidgetHostImpl* render_widget_host) override; |
| 627 void LostMouseLock(RenderWidgetHostImpl* render_widget_host) override; | 628 void LostMouseLock(RenderWidgetHostImpl* render_widget_host) override; |
| 628 void ForwardCompositorProto(RenderWidgetHostImpl* render_widget_host, | 629 void ForwardCompositorProto(RenderWidgetHostImpl* render_widget_host, |
| 629 const std::vector<uint8_t>& proto) override; | 630 const std::vector<uint8_t>& proto) override; |
| 630 void OnRenderFrameProxyVisibilityChanged(bool visible) override; | 631 void OnRenderFrameProxyVisibilityChanged(bool visible) override; |
| 631 void SendScreenRects() override; | 632 void SendScreenRects() override; |
| 632 void OnFirstPaintAfterLoad(RenderWidgetHostImpl* render_widget_host) override; | 633 void OnFirstPaintAfterLoad(RenderWidgetHostImpl* render_widget_host) override; |
| 634 TextInputManager* GetTextInputManager() override; |
| 633 | 635 |
| 634 // RenderFrameHostManager::Delegate ------------------------------------------ | 636 // RenderFrameHostManager::Delegate ------------------------------------------ |
| 635 | 637 |
| 636 bool CreateRenderViewForRenderManager( | 638 bool CreateRenderViewForRenderManager( |
| 637 RenderViewHost* render_view_host, | 639 RenderViewHost* render_view_host, |
| 638 int opener_frame_routing_id, | 640 int opener_frame_routing_id, |
| 639 int proxy_routing_id, | 641 int proxy_routing_id, |
| 640 const FrameReplicationState& replicated_frame_state) override; | 642 const FrameReplicationState& replicated_frame_state) override; |
| 641 void CreateRenderWidgetHostViewForRenderManager( | 643 void CreateRenderWidgetHostViewForRenderManager( |
| 642 RenderViewHost* render_view_host) override; | 644 RenderViewHost* render_view_host) override; |
| (...skipping 733 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1376 | 1378 |
| 1377 // Manages media players, CDMs, and power save blockers for media. | 1379 // Manages media players, CDMs, and power save blockers for media. |
| 1378 std::unique_ptr<MediaWebContentsObserver> media_web_contents_observer_; | 1380 std::unique_ptr<MediaWebContentsObserver> media_web_contents_observer_; |
| 1379 | 1381 |
| 1380 std::unique_ptr<RenderWidgetHostInputEventRouter> rwh_input_event_router_; | 1382 std::unique_ptr<RenderWidgetHostInputEventRouter> rwh_input_event_router_; |
| 1381 | 1383 |
| 1382 PageImportanceSignals page_importance_signals_; | 1384 PageImportanceSignals page_importance_signals_; |
| 1383 | 1385 |
| 1384 bool page_scale_factor_is_one_; | 1386 bool page_scale_factor_is_one_; |
| 1385 | 1387 |
| 1388 // TextInputManager tracks the IME-related state for all the |
| 1389 // RenderWidgetHostViews on this WebContents. Only exists on the outermost |
| 1390 // WebContents and is automatically destroyed when a WebContents becomes an |
| 1391 // inner WebContents by attaching to an outer WebContents. Then the |
| 1392 // IME-related state for RenderWidgetHosts on the inner WebContents is tracked |
| 1393 // by the TextInputManager in the outer WebContents. |
| 1394 std::unique_ptr<TextInputManager> text_input_manager_; |
| 1395 |
| 1386 base::WeakPtrFactory<WebContentsImpl> loading_weak_factory_; | 1396 base::WeakPtrFactory<WebContentsImpl> loading_weak_factory_; |
| 1387 base::WeakPtrFactory<WebContentsImpl> weak_factory_; | 1397 base::WeakPtrFactory<WebContentsImpl> weak_factory_; |
| 1388 | 1398 |
| 1389 DISALLOW_COPY_AND_ASSIGN(WebContentsImpl); | 1399 DISALLOW_COPY_AND_ASSIGN(WebContentsImpl); |
| 1390 }; | 1400 }; |
| 1391 | 1401 |
| 1392 // Dangerous methods which should never be made part of the public API, so we | 1402 // Dangerous methods which should never be made part of the public API, so we |
| 1393 // grant their use only to an explicit friend list (c++ attorney/client idiom). | 1403 // grant their use only to an explicit friend list (c++ attorney/client idiom). |
| 1394 class CONTENT_EXPORT WebContentsImpl::FriendZone { | 1404 class CONTENT_EXPORT WebContentsImpl::FriendZone { |
| 1395 private: | 1405 private: |
| 1396 friend class TestNavigationObserver; | 1406 friend class TestNavigationObserver; |
| 1397 friend class WebContentsAddedObserver; | 1407 friend class WebContentsAddedObserver; |
| 1398 friend class ContentBrowserSanityChecker; | 1408 friend class ContentBrowserSanityChecker; |
| 1399 | 1409 |
| 1400 FriendZone(); // Not instantiable. | 1410 FriendZone(); // Not instantiable. |
| 1401 | 1411 |
| 1402 // Adds/removes a callback called on creation of each new WebContents. | 1412 // Adds/removes a callback called on creation of each new WebContents. |
| 1403 static void AddCreatedCallbackForTesting(const CreatedCallback& callback); | 1413 static void AddCreatedCallbackForTesting(const CreatedCallback& callback); |
| 1404 static void RemoveCreatedCallbackForTesting(const CreatedCallback& callback); | 1414 static void RemoveCreatedCallbackForTesting(const CreatedCallback& callback); |
| 1405 | 1415 |
| 1406 DISALLOW_COPY_AND_ASSIGN(FriendZone); | 1416 DISALLOW_COPY_AND_ASSIGN(FriendZone); |
| 1407 }; | 1417 }; |
| 1408 | 1418 |
| 1409 } // namespace content | 1419 } // namespace content |
| 1410 | 1420 |
| 1411 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 1421 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
| OLD | NEW |