summaryrefslogtreecommitdiffstats
path: root/metacity-theme-crash.patch
diff options
context:
space:
mode:
Diffstat (limited to 'metacity-theme-crash.patch')
-rw-r--r--metacity-theme-crash.patch39
1 files changed, 39 insertions, 0 deletions
diff --git a/metacity-theme-crash.patch b/metacity-theme-crash.patch
new file mode 100644
index 0000000..50c3b09
--- /dev/null
+++ b/metacity-theme-crash.patch
@@ -0,0 +1,39 @@
+Index: src/ui/preview-widget.c
+===================================================================
+--- src/ui/preview-widget.c (revision 3666)
++++ src/ui/preview-widget.c (working copy)
+@@ -478,6 +478,19 @@
+
+ flags = (META_PREVIEW (preview)->flags);
+
++ window_xregion = gdk_region_new ();
++
++ xrect.x = 0;
++ xrect.y = 0;
++ xrect.width = new_window_width;
++ xrect.height = new_window_height;
++
++ gdk_region_union_with_rect (window_xregion, &xrect);
++
++ if (preview->theme == NULL)
++ return window_xregion;
++
++ /* Otherwise, we do have a theme, so calculate the corners */
+ frame_style = meta_theme_get_frame_style (preview->theme,
+ META_FRAME_TYPE_NORMAL, flags);
+
+@@ -558,14 +571,6 @@
+ }
+ }
+
+- window_xregion = gdk_region_new ();
+-
+- xrect.x = 0;
+- xrect.y = 0;
+- xrect.width = new_window_width;
+- xrect.height = new_window_height;
+-
+- gdk_region_union_with_rect (window_xregion, &xrect);
+ gdk_region_subtract (window_xregion, corners_xregion);
+ gdk_region_destroy (corners_xregion);
+