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

Unified Diff: ui/views/widget/desktop_aura/desktop_root_window_host_win.cc

Issue 54983005: Plumb native AppWindow input region through to window shape under Aura. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix typo in X11 patch Created 7 years, 1 month 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
Index: ui/views/widget/desktop_aura/desktop_root_window_host_win.cc
diff --git a/ui/views/widget/desktop_aura/desktop_root_window_host_win.cc b/ui/views/widget/desktop_aura/desktop_root_window_host_win.cc
index 903706cc2ef4d93784439c15be36350d1c8be00a..4c8376d987384c7ba83f51f484966c3cc354a71d 100644
--- a/ui/views/widget/desktop_aura/desktop_root_window_host_win.cc
+++ b/ui/views/widget/desktop_aura/desktop_root_window_host_win.cc
@@ -236,9 +236,15 @@ gfx::Rect DesktopRootWindowHostWin::GetWorkAreaBoundsInScreen() const {
}
void DesktopRootWindowHostWin::SetShape(gfx::NativeRegion native_region) {
- SkPath path;
- native_region->getBoundaryPath(&path);
- message_handler_->SetRegion(gfx::CreateHRGNFromSkPath(path));
+ if (native_region) {
+ SkPath path;
+ native_region->getBoundaryPath(&path);
+ message_handler_->SetRegion(gfx::CreateHRGNFromSkPath(path));
+ } else {
+ message_handler_->SetRegion(NULL);
+ }
+
+ delete native_region;
}
void DesktopRootWindowHostWin::Activate() {
« no previous file with comments | « ui/views/widget/desktop_aura/desktop_root_window_host.h ('k') | ui/views/widget/desktop_aura/desktop_root_window_host_x11.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698