View Issue Details

IDProjectCategoryView StatusLast Update
0010233ardourbugspublic2026-06-25 14:04
Reportercolinf Assigned To 
PrioritylowSeveritytweakReproducibilityalways
Status newResolutionopen 
Product Version9.2 
Summary0010233: "Session | Open" no longer opens in current session's location
DescriptionThe file chooser in the open/recent/new session dialogue always default to the configured ardour default session location, even when a session is already loaded. In 8.12 & previous, the 'New session' dialogue would start in the parent directory of the current session.
TagsNo tags attached.

Activities

colinf

2026-06-14 16:44

updater   ~0030499

Actually, the "New" tab of the open/new/recent session dialogue does default to the parent of the current session, but the "Open" tab to open an existing session always goes back to the default.

colinf

2026-06-25 14:04

updater   ~0030548

Simple patch attached -
0008-start-open-session-chooser-in-parent-directory-of-cu.patch (1,990 bytes)   
From 5793dc20704e312e4ace137f94d60428210706c8 Mon Sep 17 00:00:00 2001
From: Colin Fletcher <colin.m.fletcher@googlemail.com>
Date: Sun, 14 Jun 2026 17:42:56 +0100
Subject: [PATCH 08/10] start "open session" chooser in parent directory of
 current session

Copied'n'pasted from the code for the new session dialogue page: perhaps
the check for existing session should be factored out, but this at least
works for now.

Fix for #10233
---
 gtk2_ardour/session_dialog.cc | 17 ++++++++++++++++-
 1 file changed, 16 insertions(+), 1 deletion(-)

diff --git a/gtk2_ardour/session_dialog.cc b/gtk2_ardour/session_dialog.cc
index 564352dea2..28ec4029dc 100644
--- a/gtk2_ardour/session_dialog.cc
+++ b/gtk2_ardour/session_dialog.cc
@@ -576,7 +576,22 @@ SessionDialog::setup_existing_box ()
 	/* Browse button */
 
 	existing_session_chooser.set_size_request (450, 300);
-	existing_session_chooser.set_current_folder(poor_mans_glob (Config->get_default_session_parent_dir()));
+
+	if (ARDOUR_UI::instance()->the_session ()) {
+		// point the existing session file chooser at the parent directory of the current session
+		string session_parent_dir = Glib::path_get_dirname(ARDOUR_UI::instance()->the_session()->path());
+		existing_session_chooser.set_current_folder (session_parent_dir);
+		string default_session_folder = poor_mans_glob (Config->get_default_session_parent_dir());
+		try {
+			/* add_shortcut_folder throws an exception if the folder being added already has a shortcut */
+			existing_session_chooser.add_shortcut_folder (default_session_folder);
+		}
+		catch (Glib::Error & e) {
+			std::cerr << "existing_session_chooser.add_shortcut_folder (" << default_session_folder << ") threw Glib::Error " << e.what() << std::endl;
+		}
+	} else {
+		existing_session_chooser.set_current_folder(poor_mans_glob (Config->get_default_session_parent_dir()));
+	}
 
 	FileFilter session_filter;
 	session_filter.add_pattern (string_compose(X_("*%1"), ARDOUR::statefile_suffix));
-- 
2.47.3

Issue History

Date Modified Username Field Change
2026-03-06 11:29 colinf New Issue
2026-06-14 16:44 colinf Note Added: 0030499
2026-06-25 14:04 colinf Note Added: 0030548
2026-06-25 14:04 colinf File Added: 0008-start-open-session-chooser-in-parent-directory-of-cu.patch