Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/mus/native_widget_mus.h" | 5 #include "ui/views/mus/native_widget_mus.h" |
| 6 | 6 |
| 7 #include "base/macros.h" | 7 #include "base/macros.h" |
| 8 #include "base/thread_task_runner_handle.h" | 8 #include "base/thread_task_runner_handle.h" |
| 9 #include "components/mus/public/cpp/property_type_converters.h" | 9 #include "components/mus/public/cpp/property_type_converters.h" |
| 10 #include "components/mus/public/cpp/window.h" | 10 #include "components/mus/public/cpp/window.h" |
| (...skipping 454 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 465 | 465 |
| 466 gfx::NativeWindow NativeWidgetMus::GetNativeWindow() const { | 466 gfx::NativeWindow NativeWidgetMus::GetNativeWindow() const { |
| 467 return content_; | 467 return content_; |
| 468 } | 468 } |
| 469 | 469 |
| 470 Widget* NativeWidgetMus::GetTopLevelWidget() { | 470 Widget* NativeWidgetMus::GetTopLevelWidget() { |
| 471 return GetWidget(); | 471 return GetWidget(); |
| 472 } | 472 } |
| 473 | 473 |
| 474 const ui::Compositor* NativeWidgetMus::GetCompositor() const { | 474 const ui::Compositor* NativeWidgetMus::GetCompositor() const { |
| 475 return window_tree_host_->window()->layer()->GetCompositor(); | 475 return window_tree_host_->window()->layer()->GetCompositor(); |
|
James Cook
2016/04/06 03:44:16
Drive-by question... I presume this doesn't need t
sadrul
2016/04/06 14:05:44
Yes, the entire layer-tree share the same composit
| |
| 476 } | 476 } |
| 477 | 477 |
| 478 const ui::Layer* NativeWidgetMus::GetLayer() const { | 478 const ui::Layer* NativeWidgetMus::GetLayer() const { |
| 479 return window_tree_host_ ? window_tree_host_->window()->layer() : nullptr; | 479 return content_ ? content_->layer() : nullptr; |
| 480 } | 480 } |
| 481 | 481 |
| 482 void NativeWidgetMus::ReorderNativeViews() { | 482 void NativeWidgetMus::ReorderNativeViews() { |
| 483 // NOTIMPLEMENTED(); | 483 // NOTIMPLEMENTED(); |
| 484 } | 484 } |
| 485 | 485 |
| 486 void NativeWidgetMus::ViewRemoved(View* view) { | 486 void NativeWidgetMus::ViewRemoved(View* view) { |
| 487 // NOTIMPLEMENTED(); | 487 // NOTIMPLEMENTED(); |
| 488 } | 488 } |
| 489 | 489 |
| (...skipping 512 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1002 window_tree_host_->Show(); | 1002 window_tree_host_->Show(); |
| 1003 GetNativeWindow()->Show(); | 1003 GetNativeWindow()->Show(); |
| 1004 } else { | 1004 } else { |
| 1005 window_tree_host_->Hide(); | 1005 window_tree_host_->Hide(); |
| 1006 GetNativeWindow()->Hide(); | 1006 GetNativeWindow()->Hide(); |
| 1007 } | 1007 } |
| 1008 native_widget_delegate_->OnNativeWidgetVisibilityChanged(window->visible()); | 1008 native_widget_delegate_->OnNativeWidgetVisibilityChanged(window->visible()); |
| 1009 } | 1009 } |
| 1010 | 1010 |
| 1011 } // namespace views | 1011 } // namespace views |
| OLD | NEW |