diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2012-12-27 18:49:35 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2012-12-27 18:49:35 +0000 |
commit | db36cb793a8e500531e18efd967a9f6eac8183eb (patch) | |
tree | 14ab486bf10a94c5b3dd3e05fc3858ec1d3f087a | |
parent | fe1796fd6fbf0e340b14004f4a1cebaa1743ed30 (diff) |
fix for #5224
git-svn-id: svn://localhost/ardour2/branches/3.0@13741 d708f5d6-7413-0410-9779-e7cbd77b26cf
-rw-r--r-- | gtk2_ardour/ardour_ui_ed.cc | 2 | ||||
-rw-r--r-- | gtk2_ardour/search_path_option.cc | 5 | ||||
-rw-r--r-- | gtk2_ardour/search_path_option.h | 1 | ||||
-rw-r--r-- | gtk2_ardour/session_option_editor.cc | 2 |
4 files changed, 8 insertions, 2 deletions
diff --git a/gtk2_ardour/ardour_ui_ed.cc b/gtk2_ardour/ardour_ui_ed.cc index 662ab44bfa..36a1cf0084 100644 --- a/gtk2_ardour/ardour_ui_ed.cc +++ b/gtk2_ardour/ardour_ui_ed.cc @@ -714,7 +714,7 @@ ARDOUR_UI::float_big_clock (Gtk::Window* parent) } void -ARDOUR_UI::big_clock_size_allocate (Gtk::Allocation&) +ARDOUR_UI::big_clock_size_allocate (Gtk::Allocation& a) { if (!big_clock_resize_in_progress) { Glib::signal_idle().connect (sigc::bind (sigc::mem_fun (*this, &ARDOUR_UI::idle_big_clock_text_resizer), 0, 0)); diff --git a/gtk2_ardour/search_path_option.cc b/gtk2_ardour/search_path_option.cc index 4590183e6c..8a5d99a375 100644 --- a/gtk2_ardour/search_path_option.cc +++ b/gtk2_ardour/search_path_option.cc @@ -18,6 +18,8 @@ #include "pbd/strsplit.h" #include "pbd/compose.h" +#include "pbd/shortpath.h" + #include "search_path_option.h" #include "i18n.h" @@ -25,6 +27,7 @@ using namespace std; using namespace Gtk; SearchPathOption::SearchPathOption (const string& pathname, const string& label, + const string& default_path, sigc::slot<std::string> get, sigc::slot<bool, std::string> set) : Option (pathname, label) , _get (get) @@ -45,7 +48,7 @@ SearchPathOption::SearchPathOption (const string& pathname, const string& label, vbox.pack_end (*hbox); session_label.set_use_markup (true); - session_label.set_markup (string_compose ("<i>%1</i>", _("the session folder"))); + session_label.set_markup (string_compose ("<i>%1 (%2)</i>", _("the session folder"), short_path (default_path, 32))); session_label.set_alignment (0.0, 0.5); session_label.show (); diff --git a/gtk2_ardour/search_path_option.h b/gtk2_ardour/search_path_option.h index f7cf9b5dcf..0230666656 100644 --- a/gtk2_ardour/search_path_option.h +++ b/gtk2_ardour/search_path_option.h @@ -33,6 +33,7 @@ class SearchPathOption : public Option { public: SearchPathOption (const std::string& pathname, const std::string& label, + const std::string& default_path, sigc::slot<std::string>, sigc::slot<bool, std::string>); ~SearchPathOption (); diff --git a/gtk2_ardour/session_option_editor.cc b/gtk2_ardour/session_option_editor.cc index 9470dd8a8d..2b5c480503 100644 --- a/gtk2_ardour/session_option_editor.cc +++ b/gtk2_ardour/session_option_editor.cc @@ -200,11 +200,13 @@ SessionOptionEditor::SessionOptionEditor (Session* s) add_option (_("Media"), new OptionEditorHeading (_("File locations"))); SearchPathOption* spo = new SearchPathOption ("audio-search-path", _("Search for audio files in:"), + _session->path(), sigc::mem_fun (*_session_config, &SessionConfiguration::get_audio_search_path), sigc::mem_fun (*_session_config, &SessionConfiguration::set_audio_search_path)); add_option (_("Media"), spo); spo = new SearchPathOption ("midi-search-path", _("Search for MIDI files in:"), + _session->path(), sigc::mem_fun (*_session_config, &SessionConfiguration::get_midi_search_path), sigc::mem_fun (*_session_config, &SessionConfiguration::set_midi_search_path)); |