mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-06 14:54:56 +01:00
un-hardcode "*.ardour" file filters
This commit is contained in:
parent
5584f46003
commit
78d0b2eebb
4 changed files with 11 additions and 9 deletions
|
|
@ -26,6 +26,7 @@
|
|||
#include "pbd/xml++.h"
|
||||
#include "pbd/error.h"
|
||||
|
||||
#include "ardour/filename_extensions.h"
|
||||
#include "ardour/session.h"
|
||||
#include "ardour/session_utils.h"
|
||||
|
||||
|
|
@ -725,7 +726,7 @@ SessionMetadataImporter::run ()
|
|||
session_selector.set_default_response(Gtk::RESPONSE_ACCEPT);
|
||||
|
||||
Gtk::FileFilter session_filter;
|
||||
session_filter.add_pattern ("*.ardour");
|
||||
session_filter.add_pattern (string_compose(X_("*.%1"), ARDOUR::statefile_suffix));
|
||||
session_filter.set_name (string_compose (_("%1 sessions"), PROGRAM_NAME));
|
||||
session_selector.add_filter (session_filter);
|
||||
session_selector.set_filter (session_filter);
|
||||
|
|
@ -754,7 +755,7 @@ SessionMetadataImporter::run ()
|
|||
|
||||
/* We have a session: load the data and run dialog */
|
||||
|
||||
string filename = Glib::build_filename (path, name + ".ardour");
|
||||
string filename = Glib::build_filename (path, name + "." + ARDOUR::statefile_suffix);
|
||||
XMLTree session_tree;
|
||||
if (!session_tree.read (filename)) {
|
||||
warn_user (_("This session file could not be read!"));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue