| 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 "ui/views/widget/desktop_aura/desktop_native_widget_aura.h" | 5 #include "ui/views/widget/desktop_aura/desktop_native_widget_aura.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 #include "base/memory/ptr_util.h" | 9 #include "base/memory/ptr_util.h" |
| 10 #include "base/trace_event/trace_event.h" | 10 #include "base/trace_event/trace_event.h" |
| (...skipping 823 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 834 | 834 |
| 835 void DesktopNativeWidgetAura::SetFullscreen(bool fullscreen) { | 835 void DesktopNativeWidgetAura::SetFullscreen(bool fullscreen) { |
| 836 if (content_window_) | 836 if (content_window_) |
| 837 desktop_window_tree_host_->SetFullscreen(fullscreen); | 837 desktop_window_tree_host_->SetFullscreen(fullscreen); |
| 838 } | 838 } |
| 839 | 839 |
| 840 bool DesktopNativeWidgetAura::IsFullscreen() const { | 840 bool DesktopNativeWidgetAura::IsFullscreen() const { |
| 841 return content_window_ && desktop_window_tree_host_->IsFullscreen(); | 841 return content_window_ && desktop_window_tree_host_->IsFullscreen(); |
| 842 } | 842 } |
| 843 | 843 |
| 844 void DesktopNativeWidgetAura::Pin(bool trusted) { |
| 845 if (content_window_) |
| 846 desktop_window_tree_host_->Pin(trusted); |
| 847 } |
| 848 |
| 849 bool DesktopNativeWidgetAura::IsPinned() const { |
| 850 return content_window_ && desktop_window_tree_host_->IsPinned(); |
| 851 } |
| 852 |
| 844 void DesktopNativeWidgetAura::SetOpacity(float opacity) { | 853 void DesktopNativeWidgetAura::SetOpacity(float opacity) { |
| 845 if (content_window_) | 854 if (content_window_) |
| 846 desktop_window_tree_host_->SetOpacity(opacity); | 855 desktop_window_tree_host_->SetOpacity(opacity); |
| 847 } | 856 } |
| 848 | 857 |
| 849 void DesktopNativeWidgetAura::FlashFrame(bool flash_frame) { | 858 void DesktopNativeWidgetAura::FlashFrame(bool flash_frame) { |
| 850 if (content_window_) | 859 if (content_window_) |
| 851 desktop_window_tree_host_->FlashFrame(flash_frame); | 860 desktop_window_tree_host_->FlashFrame(flash_frame); |
| 852 } | 861 } |
| 853 | 862 |
| (...skipping 353 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1207 if (cursor_reference_count_ == 0) { | 1216 if (cursor_reference_count_ == 0) { |
| 1208 // We are the last DesktopNativeWidgetAura instance, and we are responsible | 1217 // We are the last DesktopNativeWidgetAura instance, and we are responsible |
| 1209 // for cleaning up |cursor_manager_|. | 1218 // for cleaning up |cursor_manager_|. |
| 1210 delete cursor_manager_; | 1219 delete cursor_manager_; |
| 1211 native_cursor_manager_ = NULL; | 1220 native_cursor_manager_ = NULL; |
| 1212 cursor_manager_ = NULL; | 1221 cursor_manager_ = NULL; |
| 1213 } | 1222 } |
| 1214 } | 1223 } |
| 1215 | 1224 |
| 1216 } // namespace views | 1225 } // namespace views |
| OLD | NEW |