diff options
author | Carlos Soriano <csoriano@gnome.org> | 2016-02-22 10:55:16 +0100 |
---|---|---|
committer | Carlos Soriano <csoriano@gnome.org> | 2016-02-23 16:46:18 +0100 |
commit | b18b38d0d787c02ad3df12443e78f903c91b8ec5 (patch) | |
tree | 502e711cf69ff022e347835013e780152457eb2b | |
parent | a7cde3046b01b286a105b32185cc595a0cde6764 (diff) | |
download | nautilus-b18b38d0d787c02ad3df12443e78f903c91b8ec5.tar.gz |
window: use slot location instead of loading
We were changing the location of the sidebar every time the slot started
loading.
However, that's dangerous since the slot can start loading few times
even with the old location.
Instead of using the loading property, use the location property and
change the sidebar only when the location actually changes on the slot.
This fixes the sidebar jumping rows with gtk+ 3.20.
https://bugzilla.gnome.org/show_bug.cgi?id=762137
-rw-r--r-- | src/nautilus-window.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/nautilus-window.c b/src/nautilus-window.c index ca565f8a4..708226672 100644 --- a/src/nautilus-window.c +++ b/src/nautilus-window.c @@ -481,9 +481,9 @@ on_location_changed (NautilusWindow *window) } static void -on_slot_loading_changed (NautilusWindowSlot *slot, - GParamSpec *pspec, - NautilusWindow *window) +on_slot_location_changed (NautilusWindowSlot *slot, + GParamSpec *pspec, + NautilusWindow *window) { if (nautilus_window_get_active_slot (window) == slot) on_location_changed (window); @@ -513,8 +513,8 @@ static void connect_slot (NautilusWindow *window, NautilusWindowSlot *slot) { - g_signal_connect (slot, "notify::loading", - G_CALLBACK (on_slot_loading_changed), window); + g_signal_connect (slot, "notify::location", + G_CALLBACK (on_slot_location_changed), window); } static void |