| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "ui/views/widget/root_view.h" | 5 #include "ui/views/widget/root_view.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/message_loop.h" | 10 #include "base/message_loop.h" |
| (...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 140 // RootView, View overrides: | 140 // RootView, View overrides: |
| 141 | 141 |
| 142 const Widget* RootView::GetWidget() const { | 142 const Widget* RootView::GetWidget() const { |
| 143 return widget_; | 143 return widget_; |
| 144 } | 144 } |
| 145 | 145 |
| 146 Widget* RootView::GetWidget() { | 146 Widget* RootView::GetWidget() { |
| 147 return const_cast<Widget*>(const_cast<const RootView*>(this)->GetWidget()); | 147 return const_cast<Widget*>(const_cast<const RootView*>(this)->GetWidget()); |
| 148 } | 148 } |
| 149 | 149 |
| 150 bool RootView::IsVisibleInRootView() const { | 150 bool RootView::IsDrawn() const { |
| 151 return visible(); | 151 return visible(); |
| 152 } | 152 } |
| 153 | 153 |
| 154 std::string RootView::GetClassName() const { | 154 std::string RootView::GetClassName() const { |
| 155 return kViewClassName; | 155 return kViewClassName; |
| 156 } | 156 } |
| 157 | 157 |
| 158 void RootView::SchedulePaintInRect(const gfx::Rect& rect) { | 158 void RootView::SchedulePaintInRect(const gfx::Rect& rect) { |
| 159 if (layer()) { | 159 if (layer()) { |
| 160 layer()->SchedulePaint(rect); | 160 layer()->SchedulePaint(rect); |
| (...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 446 } | 446 } |
| 447 | 447 |
| 448 void RootView::SetMouseLocationAndFlags(const MouseEvent& event) { | 448 void RootView::SetMouseLocationAndFlags(const MouseEvent& event) { |
| 449 last_mouse_event_flags_ = event.flags(); | 449 last_mouse_event_flags_ = event.flags(); |
| 450 last_mouse_event_x_ = event.x(); | 450 last_mouse_event_x_ = event.x(); |
| 451 last_mouse_event_y_ = event.y(); | 451 last_mouse_event_y_ = event.y(); |
| 452 } | 452 } |
| 453 | 453 |
| 454 } // namespace internal | 454 } // namespace internal |
| 455 } // namespace views | 455 } // namespace views |
| OLD | NEW |