| 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_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_AURA_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_AURA_H_ |
| 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_AURA_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_AURA_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 323 protected: | 323 protected: |
| 324 ~RenderWidgetHostViewAura() override; | 324 ~RenderWidgetHostViewAura() override; |
| 325 | 325 |
| 326 // Exposed for tests. | 326 // Exposed for tests. |
| 327 aura::Window* window() { return window_; } | 327 aura::Window* window() { return window_; } |
| 328 | 328 |
| 329 DelegatedFrameHost* GetDelegatedFrameHost() const { | 329 DelegatedFrameHost* GetDelegatedFrameHost() const { |
| 330 return delegated_frame_host_.get(); | 330 return delegated_frame_host_.get(); |
| 331 } | 331 } |
| 332 | 332 |
| 333 // Returns the top level window that is hosting the renderwidget. |
| 334 virtual aura::Window* GetToplevelWindow(); |
| 335 |
| 333 private: | 336 private: |
| 334 friend class DelegatedFrameHostClientAura; | 337 friend class DelegatedFrameHostClientAura; |
| 335 friend class InputMethodAuraTestBase; | 338 friend class InputMethodAuraTestBase; |
| 336 friend class RenderWidgetHostViewAuraTest; | 339 friend class RenderWidgetHostViewAuraTest; |
| 337 friend class RenderWidgetHostViewAuraCopyRequestTest; | 340 friend class RenderWidgetHostViewAuraCopyRequestTest; |
| 338 friend class TestInputMethodObserver; | 341 friend class TestInputMethodObserver; |
| 339 FRIEND_TEST_ALL_PREFIXES(InputMethodResultAuraTest, | 342 FRIEND_TEST_ALL_PREFIXES(InputMethodResultAuraTest, |
| 340 FinishImeCompositionSession); | 343 FinishImeCompositionSession); |
| 341 FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostViewAuraTest, | 344 FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostViewAuraTest, |
| 342 PopupRetainsCaptureAfterMouseRelease); | 345 PopupRetainsCaptureAfterMouseRelease); |
| (...skipping 18 matching lines...) Expand all Loading... |
| 361 FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostViewAuraTest, | 364 FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostViewAuraTest, |
| 362 UpdateCursorIfOverSelf); | 365 UpdateCursorIfOverSelf); |
| 363 FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostViewAuraTest, | 366 FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostViewAuraTest, |
| 364 VisibleViewportTest); | 367 VisibleViewportTest); |
| 365 FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostViewAuraTest, | 368 FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostViewAuraTest, |
| 366 OverscrollResetsOnBlur); | 369 OverscrollResetsOnBlur); |
| 367 FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostViewAuraTest, | 370 FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostViewAuraTest, |
| 368 FinishCompositionByMouse); | 371 FinishCompositionByMouse); |
| 369 FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostViewAuraTest, | 372 FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostViewAuraTest, |
| 370 ForwardsBeginFrameAcks); | 373 ForwardsBeginFrameAcks); |
| 374 FRIEND_TEST_ALL_PREFIXES(RenderWidgetHostViewAuraTest, |
| 375 VirtualKeyboardFocusEnsureCaretInRect); |
| 371 FRIEND_TEST_ALL_PREFIXES(WebContentsViewAuraTest, | 376 FRIEND_TEST_ALL_PREFIXES(WebContentsViewAuraTest, |
| 372 WebContentsViewReparent); | 377 WebContentsViewReparent); |
| 373 | 378 |
| 374 class WindowObserver; | 379 class WindowObserver; |
| 375 friend class WindowObserver; | 380 friend class WindowObserver; |
| 376 | 381 |
| 377 class WindowAncestorObserver; | 382 class WindowAncestorObserver; |
| 378 friend class WindowAncestorObserver; | 383 friend class WindowAncestorObserver; |
| 379 | 384 |
| 380 void CreateAuraWindow(ui::wm::WindowType type); | 385 void CreateAuraWindow(ui::wm::WindowType type); |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 434 | 439 |
| 435 void OnBeginFrame(const cc::BeginFrameArgs& args); | 440 void OnBeginFrame(const cc::BeginFrameArgs& args); |
| 436 | 441 |
| 437 // Detaches |this| from the input method object. | 442 // Detaches |this| from the input method object. |
| 438 void DetachFromInputMethod(); | 443 void DetachFromInputMethod(); |
| 439 | 444 |
| 440 // Dismisses a Web Popup on a mouse or touch press outside the popup and its | 445 // Dismisses a Web Popup on a mouse or touch press outside the popup and its |
| 441 // parent. | 446 // parent. |
| 442 void ApplyEventFilterForPopupExit(ui::LocatedEvent* event); | 447 void ApplyEventFilterForPopupExit(ui::LocatedEvent* event); |
| 443 | 448 |
| 444 // Converts |rect| from screen coordinate to window coordinate. | |
| 445 gfx::Rect ConvertRectFromScreen(const gfx::Rect& rect) const; | |
| 446 | |
| 447 // Called when the parent window bounds change. | 449 // Called when the parent window bounds change. |
| 448 void HandleParentBoundsChanged(); | 450 void HandleParentBoundsChanged(); |
| 449 | 451 |
| 450 // Called when the parent window hierarchy for our window changes. | 452 // Called when the parent window hierarchy for our window changes. |
| 451 void ParentHierarchyChanged(); | 453 void ParentHierarchyChanged(); |
| 452 | 454 |
| 453 // Helper function to create a selection controller. | 455 // Helper function to create a selection controller. |
| 454 void CreateSelectionController(); | 456 void CreateSelectionController(); |
| 455 | 457 |
| 456 // Used to set the |popup_child_host_view_| on the |popup_parent_host_view_| | 458 // Used to set the |popup_child_host_view_| on the |popup_parent_host_view_| |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 576 std::unique_ptr<RenderWidgetHostViewEventHandler> event_handler_; | 578 std::unique_ptr<RenderWidgetHostViewEventHandler> event_handler_; |
| 577 | 579 |
| 578 base::WeakPtrFactory<RenderWidgetHostViewAura> weak_ptr_factory_; | 580 base::WeakPtrFactory<RenderWidgetHostViewAura> weak_ptr_factory_; |
| 579 | 581 |
| 580 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAura); | 582 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAura); |
| 581 }; | 583 }; |
| 582 | 584 |
| 583 } // namespace content | 585 } // namespace content |
| 584 | 586 |
| 585 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_AURA_H_ | 587 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_AURA_H_ |
| OLD | NEW |