summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Sullivan <sullivan@src.gnome.org>2001-03-29 19:19:43 +0000
committerJohn Sullivan <sullivan@src.gnome.org>2001-03-29 19:19:43 +0000
commit295499e7d67b731d66d4ccc06990202802aac066 (patch)
tree2823af0b8f8646dca534a367b6a6242291a34862
parent586793d2bb4687f8a13081e9e35e01147dbf313e (diff)
downloadnautilus-295499e7d67b731d66d4ccc06990202802aac066.tar.gz
reviewed by: Darin Adler <darin@eazel.com>
Fixed bug 7921 ("Up" should select folder you came from) * src/nautilus-window-manage-views.h: * src/nautilus-window-manage-views.c: (nautilus_window_open_location_with_selection): New private-to-nautilus-window call, just calls existing private call open_location with the right parameters. * src/nautilus-window.c: (nautilus_window_go_up): Set current location as selection when going up.
-rw-r--r--ChangeLog16
-rw-r--r--src/nautilus-navigation-window.c8
-rw-r--r--src/nautilus-object-window.c8
-rw-r--r--src/nautilus-spatial-window.c8
-rw-r--r--src/nautilus-window-manage-views.c8
-rw-r--r--src/nautilus-window-manage-views.h4
-rw-r--r--src/nautilus-window.c8
7 files changed, 52 insertions, 8 deletions
diff --git a/ChangeLog b/ChangeLog
index 565691e9d..09681b4e1 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,21 @@
2001-03-29 John Sullivan <sullivan@eazel.com>
+ reviewed by: Darin Adler <darin@eazel.com>
+
+ Fixed bug 7921 ("Up" should select folder you came from)
+
+ * src/nautilus-window-manage-views.h:
+ * src/nautilus-window-manage-views.c:
+ (nautilus_window_open_location_with_selection):
+ New private-to-nautilus-window call, just calls
+ existing private call open_location with the
+ right parameters.
+
+ * src/nautilus-window.c: (nautilus_window_go_up):
+ Set current location as selection when going up.
+
+2001-03-29 John Sullivan <sullivan@eazel.com>
+
reviewed by: Ramiro Estrugo <ramiro@eazel.com>
Fixed bug 3328 (Need a preference to specify upper bounds for
diff --git a/src/nautilus-navigation-window.c b/src/nautilus-navigation-window.c
index 9ea784fe0..50a464bca 100644
--- a/src/nautilus-navigation-window.c
+++ b/src/nautilus-navigation-window.c
@@ -1394,6 +1394,7 @@ nautilus_window_go_up (NautilusWindow *window)
{
GnomeVFSURI *current_uri;
GnomeVFSURI *parent_uri;
+ GList *selection;
char *parent_uri_string;
if (window->details->location == NULL) {
@@ -1410,11 +1411,14 @@ nautilus_window_go_up (NautilusWindow *window)
}
parent_uri_string = gnome_vfs_uri_to_string (parent_uri, GNOME_VFS_URI_HIDE_NONE);
- gnome_vfs_uri_unref (parent_uri);
+ gnome_vfs_uri_unref (parent_uri);
+
+ selection = g_list_prepend (NULL, g_strdup (window->details->location));
- nautilus_window_go_to (window, parent_uri_string);
+ nautilus_window_open_location_with_selection (window, parent_uri_string, selection);
g_free (parent_uri_string);
+ nautilus_g_list_free_deep (selection);
}
void
diff --git a/src/nautilus-object-window.c b/src/nautilus-object-window.c
index 9ea784fe0..50a464bca 100644
--- a/src/nautilus-object-window.c
+++ b/src/nautilus-object-window.c
@@ -1394,6 +1394,7 @@ nautilus_window_go_up (NautilusWindow *window)
{
GnomeVFSURI *current_uri;
GnomeVFSURI *parent_uri;
+ GList *selection;
char *parent_uri_string;
if (window->details->location == NULL) {
@@ -1410,11 +1411,14 @@ nautilus_window_go_up (NautilusWindow *window)
}
parent_uri_string = gnome_vfs_uri_to_string (parent_uri, GNOME_VFS_URI_HIDE_NONE);
- gnome_vfs_uri_unref (parent_uri);
+ gnome_vfs_uri_unref (parent_uri);
+
+ selection = g_list_prepend (NULL, g_strdup (window->details->location));
- nautilus_window_go_to (window, parent_uri_string);
+ nautilus_window_open_location_with_selection (window, parent_uri_string, selection);
g_free (parent_uri_string);
+ nautilus_g_list_free_deep (selection);
}
void
diff --git a/src/nautilus-spatial-window.c b/src/nautilus-spatial-window.c
index 9ea784fe0..50a464bca 100644
--- a/src/nautilus-spatial-window.c
+++ b/src/nautilus-spatial-window.c
@@ -1394,6 +1394,7 @@ nautilus_window_go_up (NautilusWindow *window)
{
GnomeVFSURI *current_uri;
GnomeVFSURI *parent_uri;
+ GList *selection;
char *parent_uri_string;
if (window->details->location == NULL) {
@@ -1410,11 +1411,14 @@ nautilus_window_go_up (NautilusWindow *window)
}
parent_uri_string = gnome_vfs_uri_to_string (parent_uri, GNOME_VFS_URI_HIDE_NONE);
- gnome_vfs_uri_unref (parent_uri);
+ gnome_vfs_uri_unref (parent_uri);
+
+ selection = g_list_prepend (NULL, g_strdup (window->details->location));
- nautilus_window_go_to (window, parent_uri_string);
+ nautilus_window_open_location_with_selection (window, parent_uri_string, selection);
g_free (parent_uri_string);
+ nautilus_g_list_free_deep (selection);
}
void
diff --git a/src/nautilus-window-manage-views.c b/src/nautilus-window-manage-views.c
index c89eeef1f..f77c873b9 100644
--- a/src/nautilus-window-manage-views.c
+++ b/src/nautilus-window-manage-views.c
@@ -745,6 +745,14 @@ nautilus_window_open_location (NautilusWindow *window,
open_location (window, location, FALSE, NULL);
}
+void
+nautilus_window_open_location_with_selection (NautilusWindow *window,
+ const char *location,
+ GList *selection)
+{
+ open_location (window, location, FALSE, selection);
+}
+
static ViewFrameInfo *
view_frame_info_new (gboolean is_sidebar_panel, const char *label)
diff --git a/src/nautilus-window-manage-views.h b/src/nautilus-window-manage-views.h
index bd331e84e..8ac96476c 100644
--- a/src/nautilus-window-manage-views.h
+++ b/src/nautilus-window-manage-views.h
@@ -32,6 +32,10 @@
void nautilus_window_manage_views_destroy (NautilusWindow *window);
void nautilus_window_open_location (NautilusWindow *window,
const char *location);
+void nautilus_window_open_location_with_selection
+ (NautilusWindow *window,
+ const char *location,
+ GList *selection);
void nautilus_window_stop_loading (NautilusWindow *window);
void nautilus_window_set_content_view (NautilusWindow *window,
NautilusViewIdentifier *id);
diff --git a/src/nautilus-window.c b/src/nautilus-window.c
index 9ea784fe0..50a464bca 100644
--- a/src/nautilus-window.c
+++ b/src/nautilus-window.c
@@ -1394,6 +1394,7 @@ nautilus_window_go_up (NautilusWindow *window)
{
GnomeVFSURI *current_uri;
GnomeVFSURI *parent_uri;
+ GList *selection;
char *parent_uri_string;
if (window->details->location == NULL) {
@@ -1410,11 +1411,14 @@ nautilus_window_go_up (NautilusWindow *window)
}
parent_uri_string = gnome_vfs_uri_to_string (parent_uri, GNOME_VFS_URI_HIDE_NONE);
- gnome_vfs_uri_unref (parent_uri);
+ gnome_vfs_uri_unref (parent_uri);
+
+ selection = g_list_prepend (NULL, g_strdup (window->details->location));
- nautilus_window_go_to (window, parent_uri_string);
+ nautilus_window_open_location_with_selection (window, parent_uri_string, selection);
g_free (parent_uri_string);
+ nautilus_g_list_free_deep (selection);
}
void