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

Unified Diff: ui/views/widget/native_widget_aura.cc

Issue 456943004: Fix SetShape (SetAlphaShape) to allow Null regions (+ tests). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Move SetAlphaShape into native_widget's SetShape Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/views/widget/desktop_aura/desktop_window_tree_host_x11_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/widget/native_widget_aura.cc
diff --git a/ui/views/widget/native_widget_aura.cc b/ui/views/widget/native_widget_aura.cc
index e57a4ff0bc0ecb56c12fba415058f0d60a13b85f..089872fe305f79b0356311ff0d87a2525227f8b6 100644
--- a/ui/views/widget/native_widget_aura.cc
+++ b/ui/views/widget/native_widget_aura.cc
@@ -438,8 +438,8 @@ void NativeWidgetAura::StackBelow(gfx::NativeView native_view) {
}
void NativeWidgetAura::SetShape(gfx::NativeRegion region) {
- // No need for this. Just delete and ignore.
- delete region;
+ if (window_ && window_->layer())
sky 2014/08/11 23:06:18 no need for the window_->layer() part of the condi
garykac 2014/08/11 23:20:56 Done.
+ window_->layer()->SetAlphaShape(make_scoped_ptr(region));
sky 2014/08/11 23:06:18 else case to delete region?
garykac 2014/08/11 23:20:56 Done.
}
void NativeWidgetAura::Close() {
« no previous file with comments | « ui/views/widget/desktop_aura/desktop_window_tree_host_x11_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698