Merge lp:~cimi/overlay-scrollbar/fix-region-destroy-on-dispose into lp:overlay-scrollbar

Proposed by Andrea Cimitan
Status: Merged
Approved by: Ted Gould
Approved revision: 252
Merged at revision: 251
Proposed branch: lp:~cimi/overlay-scrollbar/fix-region-destroy-on-dispose
Merge into: lp:overlay-scrollbar
Diff against target: 34 lines (+10/-8)
1 file modified
os/os-scrollbar.c (+10/-8)
To merge this branch: bzr merge lp:~cimi/overlay-scrollbar/fix-region-destroy-on-dispose
Reviewer Review Type Date Requested Status
Ted Gould (community) Approve
Review via email: mp+64569@code.launchpad.net

Description of the change

Call cairo_region_destroy only when the glist of scrollbar pointers is NULL

To post a comment you must log in.
252. By Andrea Cimitan

help debugging by setting the pointer to NULL after destroying os_workarea

Revision history for this message
Ted Gould (ted) wrote :

Woot! Thanks!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'os/os-scrollbar.c'
--- os/os-scrollbar.c 2011-06-14 15:50:30 +0000
+++ os/os-scrollbar.c 2011-06-14 16:39:28 +0000
@@ -2213,8 +2213,16 @@
2213 os_root_list = g_list_remove (os_root_list, scrollbar);2213 os_root_list = g_list_remove (os_root_list, scrollbar);
22142214
2215 if (os_root_list == NULL)2215 if (os_root_list == NULL)
2216 gdk_window_remove_filter (gdk_get_default_root_window (),2216 {
2217 root_filter_func, NULL);2217 if (os_workarea != NULL)
2218 {
2219 cairo_region_destroy (os_workarea);
2220 os_workarea = NULL;
2221 }
2222
2223 gdk_window_remove_filter (gdk_get_default_root_window (),
2224 root_filter_func, NULL);
2225 }
22182226
2219 if (priv->pager != NULL)2227 if (priv->pager != NULL)
2220 {2228 {
@@ -2228,12 +2236,6 @@
2228 priv->window_group = NULL;2236 priv->window_group = NULL;
2229 }2237 }
22302238
2231 if (os_workarea != NULL)
2232 {
2233 cairo_region_destroy (os_workarea);
2234 os_workarea = NULL;
2235 }
2236
2237 swap_adjustment (scrollbar, NULL);2239 swap_adjustment (scrollbar, NULL);
2238 swap_thumb (scrollbar, NULL);2240 swap_thumb (scrollbar, NULL);
22392241

Subscribers

People subscribed via source and target branches