summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarlos Soriano <csoriano@gnome.org>2015-12-11 11:07:52 +0100
committerCarlos Soriano <csoriano@gnome.org>2015-12-11 13:43:49 +0100
commit81c58a9c7ae2688ed7fff7f3400a698bbc4d1a00 (patch)
tree3e399aadb89dc1c130f4caf66f3e7facecb51862
parent755c7710582eeb1cb34350ce983a6c4e3a451f47 (diff)
downloadnautilus-81c58a9c7ae2688ed7fff7f3400a698bbc4d1a00.tar.gz
mime-actions: use explicit slot for opening locations
Even if we wanted to always use the active window as the default action to open locations, seems gtk_get_active_windows doesn't work as expected for us. Until we figure out the problem, pass explicitly the target slot that the caller provides so users don't experience the location opening in a different window than the expected. https://bugzilla.gnome.org/show_bug.cgi?id=756499
-rw-r--r--src/nautilus-mime-actions.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/nautilus-mime-actions.c b/src/nautilus-mime-actions.c
index 44c99d8e4..6b47d4e53 100644
--- a/src/nautilus-mime-actions.c
+++ b/src/nautilus-mime-actions.c
@@ -1528,8 +1528,12 @@ activate_files (ActivateParameters *parameters)
uri = nautilus_file_get_activation_uri (file);
f = g_file_new_for_uri (uri);
+ /* FIXME: we need to pass the parent_window, but we only use it for the current active window,
+ * which nautilus-application should take care of. However is not working and creating regressions
+ * in some cases. Until we figure out what's going on, continue to use the parameters->slot
+ * to make splicit the window we want to use for activating the files */
nautilus_application_open_location_full (NAUTILUS_APPLICATION (g_application_get_default ()),
- f, flags, NULL, NULL, NULL);
+ f, flags, NULL, NULL, parameters->slot);
g_object_unref (f);
g_free (uri);
}