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 "views/widget/native_widget_views.h" | 5 #include "views/widget/native_widget_views.h" |
6 | 6 |
7 #include "ui/gfx/compositor/compositor.h" | 7 #include "ui/gfx/compositor/compositor.h" |
8 #include "views/desktop/desktop_window_view.h" | 8 #include "views/desktop/desktop_window_view.h" |
9 #include "views/view.h" | 9 #include "views/view.h" |
10 #include "views/views_delegate.h" | 10 #include "views/views_delegate.h" |
(...skipping 459 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
470 const ui::OSExchangeData& data, | 470 const ui::OSExchangeData& data, |
471 int operation) { | 471 int operation) { |
472 GetParentNativeWidget()->RunShellDrag(view, data, operation); | 472 GetParentNativeWidget()->RunShellDrag(view, data, operation); |
473 } | 473 } |
474 | 474 |
475 void NativeWidgetViews::SchedulePaintInRect(const gfx::Rect& rect) { | 475 void NativeWidgetViews::SchedulePaintInRect(const gfx::Rect& rect) { |
476 view_->SchedulePaintInternal(rect); | 476 view_->SchedulePaintInternal(rect); |
477 } | 477 } |
478 | 478 |
479 void NativeWidgetViews::SetCursor(gfx::NativeCursor cursor) { | 479 void NativeWidgetViews::SetCursor(gfx::NativeCursor cursor) { |
| 480 view_->set_cursor(cursor); |
480 GetParentNativeWidget()->SetCursor(cursor); | 481 GetParentNativeWidget()->SetCursor(cursor); |
481 } | 482 } |
482 | 483 |
483 void NativeWidgetViews::ClearNativeFocus() { | 484 void NativeWidgetViews::ClearNativeFocus() { |
484 GetParentNativeWidget()->ClearNativeFocus(); | 485 GetParentNativeWidget()->ClearNativeFocus(); |
485 } | 486 } |
486 | 487 |
487 void NativeWidgetViews::FocusNativeView(gfx::NativeView native_view) { | 488 void NativeWidgetViews::FocusNativeView(gfx::NativeView native_view) { |
488 GetParentNativeWidget()->FocusNativeView(native_view); | 489 GetParentNativeWidget()->FocusNativeView(native_view); |
489 } | 490 } |
(...skipping 10 matching lines...) Expand all Loading... |
500 | 501 |
501 const internal::NativeWidgetPrivate* | 502 const internal::NativeWidgetPrivate* |
502 NativeWidgetViews::GetParentNativeWidget() const { | 503 NativeWidgetViews::GetParentNativeWidget() const { |
503 const Widget* containing_widget = view_ ? view_->GetWidget() : NULL; | 504 const Widget* containing_widget = view_ ? view_->GetWidget() : NULL; |
504 return containing_widget ? static_cast<const internal::NativeWidgetPrivate*>( | 505 return containing_widget ? static_cast<const internal::NativeWidgetPrivate*>( |
505 containing_widget->native_widget()) : | 506 containing_widget->native_widget()) : |
506 NULL; | 507 NULL; |
507 } | 508 } |
508 | 509 |
509 } // namespace views | 510 } // namespace views |
OLD | NEW |