Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(198)

Side by Side Diff: ui/views/widget/desktop_aura/desktop_native_widget_aura.cc

Issue 2173033002: Make various views SetShape() methods take an unique_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: nits Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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/trace_event/trace_event.h" 9 #include "base/trace_event/trace_event.h"
10 #include "build/build_config.h" 10 #include "build/build_config.h"
(...skipping 689 matching lines...) Expand 10 before | Expand all | Expand 10 after
700 } 700 }
701 701
702 void DesktopNativeWidgetAura::StackAtTop() { 702 void DesktopNativeWidgetAura::StackAtTop() {
703 if (content_window_) 703 if (content_window_)
704 desktop_window_tree_host_->StackAtTop(); 704 desktop_window_tree_host_->StackAtTop();
705 } 705 }
706 706
707 void DesktopNativeWidgetAura::StackBelow(gfx::NativeView native_view) { 707 void DesktopNativeWidgetAura::StackBelow(gfx::NativeView native_view) {
708 } 708 }
709 709
710 void DesktopNativeWidgetAura::SetShape(SkRegion* shape) { 710 void DesktopNativeWidgetAura::SetShape(std::unique_ptr<SkRegion> shape) {
711 if (content_window_) 711 if (content_window_)
712 desktop_window_tree_host_->SetShape(shape); 712 desktop_window_tree_host_->SetShape(std::move(shape));
713 } 713 }
714 714
715 void DesktopNativeWidgetAura::Close() { 715 void DesktopNativeWidgetAura::Close() {
716 if (!content_window_) 716 if (!content_window_)
717 return; 717 return;
718 718
719 content_window_->SuppressPaint(); 719 content_window_->SuppressPaint();
720 content_window_->Hide(); 720 content_window_->Hide();
721 721
722 desktop_window_tree_host_->Close(); 722 desktop_window_tree_host_->Close();
(...skipping 473 matching lines...) Expand 10 before | Expand all | Expand 10 after
1196 if (cursor_reference_count_ == 0) { 1196 if (cursor_reference_count_ == 0) {
1197 // We are the last DesktopNativeWidgetAura instance, and we are responsible 1197 // We are the last DesktopNativeWidgetAura instance, and we are responsible
1198 // for cleaning up |cursor_manager_|. 1198 // for cleaning up |cursor_manager_|.
1199 delete cursor_manager_; 1199 delete cursor_manager_;
1200 native_cursor_manager_ = NULL; 1200 native_cursor_manager_ = NULL;
1201 cursor_manager_ = NULL; 1201 cursor_manager_ = NULL;
1202 } 1202 }
1203 } 1203 }
1204 1204
1205 } // namespace views 1205 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/widget/desktop_aura/desktop_native_widget_aura.h ('k') | ui/views/widget/desktop_aura/desktop_window_tree_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698