Merge lp:~cimi/overlay-scrollbar/fix-771511 into lp:overlay-scrollbar

Proposed by Andrea Cimitan
Status: Merged
Merged at revision: 227
Proposed branch: lp:~cimi/overlay-scrollbar/fix-771511
Merge into: lp:overlay-scrollbar
Diff against target: 37 lines (+2/-5)
2 files modified
os/os-scrollbar.c (+2/-2)
os/os-utils.c (+0/-3)
To merge this branch: bzr merge lp:~cimi/overlay-scrollbar/fix-771511
Reviewer Review Type Date Requested Status
Jason Smith (community) Approve
Review via email: mp+59140@code.launchpad.net

Description of the change

the scrollbar's gdkwindow is not always the same of the toplevel, so the check for the active window may fail... let's get the toplevel, and check for the active window from it.

To post a comment you must log in.
Revision history for this message
Jason Smith (jassmith) wrote :

+1 looks good and makes good sense

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-04-26 15:20:49 +0000
+++ os/os-scrollbar.c 2011-04-26 22:20:55 +0000
@@ -1197,7 +1197,7 @@
11971197
1198 if (gtk_widget_get_mapped (GTK_WIDGET (scrollbar)))1198 if (gtk_widget_get_mapped (GTK_WIDGET (scrollbar)))
1199 {1199 {
1200 if (gtk_widget_get_window (GTK_WIDGET (scrollbar)) ==1200 if (gtk_widget_get_window (gtk_widget_get_toplevel (GTK_WIDGET (scrollbar))) ==
1201 gdk_screen_get_active_window (gtk_widget_get_screen (GTK_WIDGET (scrollbar))))1201 gdk_screen_get_active_window (gtk_widget_get_screen (GTK_WIDGET (scrollbar))))
1202 {1202 {
1203 /* stops potential running timeout. */1203 /* stops potential running timeout. */
@@ -1666,7 +1666,7 @@
1666 priv->proximity = TRUE;1666 priv->proximity = TRUE;
16671667
1668 /* on map, check for the active window. */1668 /* on map, check for the active window. */
1669 if (gtk_widget_get_window (widget) ==1669 if (gtk_widget_get_window (gtk_widget_get_toplevel (widget)) ==
1670 gdk_screen_get_active_window (gtk_widget_get_screen (widget)))1670 gdk_screen_get_active_window (gtk_widget_get_screen (widget)))
1671 {1671 {
1672 /* stops potential running timeout. */1672 /* stops potential running timeout. */
16731673
=== modified file 'os/os-utils.c'
--- os/os-utils.c 2011-04-26 22:09:39 +0000
+++ os/os-utils.c 2011-04-26 22:20:55 +0000
@@ -37,11 +37,8 @@
37 "Banshee",37 "Banshee",
38 "codeblocks",38 "codeblocks",
39 "codelite",39 "codelite",
40 "deja-dup",
41 "eclipse",40 "eclipse",
42 "gnucash",41 "gnucash",
43 "inkscape",
44 "lshw-gtk",
45 "meld",42 "meld",
46 "pgadmin3",43 "pgadmin3",
47 "synaptic",44 "synaptic",

Subscribers

People subscribed via source and target branches