| 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 #include "content/browser/web_contents/web_contents_view_aura.h" | 5 #include "content/browser/web_contents/web_contents_view_aura.h" |
| 6 | 6 |
| 7 #include "base/auto_reset.h" | 7 #include "base/auto_reset.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/metrics/histogram.h" | 9 #include "base/metrics/histogram.h" |
| 10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
| (...skipping 680 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 691 } | 691 } |
| 692 | 692 |
| 693 virtual void OnWindowRemovingFromRootWindow(aura::Window* window) OVERRIDE { | 693 virtual void OnWindowRemovingFromRootWindow(aura::Window* window) OVERRIDE { |
| 694 if (window != parent_) | 694 if (window != parent_) |
| 695 window->GetDispatcher()->RemoveRootWindowObserver(this); | 695 window->GetDispatcher()->RemoveRootWindowObserver(this); |
| 696 } | 696 } |
| 697 | 697 |
| 698 // Overridden RootWindowObserver: | 698 // Overridden RootWindowObserver: |
| 699 virtual void OnRootWindowHostMoved(const aura::RootWindow* root, | 699 virtual void OnRootWindowHostMoved(const aura::RootWindow* root, |
| 700 const gfx::Point& new_origin) OVERRIDE { | 700 const gfx::Point& new_origin) OVERRIDE { |
| 701 TRACE_EVENT1("ui", |
| 702 "WebContentsViewAura::WindowObserver::OnRootWindowHostMoved", |
| 703 "new_origin", new_origin.ToString()); |
| 704 |
| 701 // This is for the desktop case (i.e. Aura desktop). | 705 // This is for the desktop case (i.e. Aura desktop). |
| 702 SendScreenRects(); | 706 SendScreenRects(); |
| 703 } | 707 } |
| 704 | 708 |
| 705 private: | 709 private: |
| 706 void SendScreenRects() { | 710 void SendScreenRects() { |
| 707 RenderWidgetHostImpl::From(view_->web_contents_->GetRenderViewHost())-> | 711 RenderWidgetHostImpl::From(view_->web_contents_->GetRenderViewHost())-> |
| 708 SendScreenRects(); | 712 SendScreenRects(); |
| 709 } | 713 } |
| 710 | 714 |
| (...skipping 935 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1646 event.location(), | 1650 event.location(), |
| 1647 gfx::Screen::GetScreenFor(GetNativeView())->GetCursorScreenPoint(), | 1651 gfx::Screen::GetScreenFor(GetNativeView())->GetCursorScreenPoint(), |
| 1648 ConvertAuraEventFlagsToWebInputEventModifiers(event.flags())); | 1652 ConvertAuraEventFlagsToWebInputEventModifiers(event.flags())); |
| 1649 if (drag_dest_delegate_) | 1653 if (drag_dest_delegate_) |
| 1650 drag_dest_delegate_->OnDrop(); | 1654 drag_dest_delegate_->OnDrop(); |
| 1651 current_drop_data_.reset(); | 1655 current_drop_data_.reset(); |
| 1652 return current_drag_op_; | 1656 return current_drag_op_; |
| 1653 } | 1657 } |
| 1654 | 1658 |
| 1655 } // namespace content | 1659 } // namespace content |
| OLD | NEW |