summaryrefslogtreecommitdiff
path: root/gtk2_ardour
diff options
context:
space:
mode:
Diffstat (limited to 'gtk2_ardour')
-rw-r--r--gtk2_ardour/ardour_ui_ed.cc39
-rw-r--r--gtk2_ardour/editor_audio_import.cc1
-rw-r--r--gtk2_ardour/opts.cc2
-rw-r--r--gtk2_ardour/sfdb_ui.cc14
-rw-r--r--gtk2_ardour/sfdb_ui.h2
5 files changed, 44 insertions, 14 deletions
diff --git a/gtk2_ardour/ardour_ui_ed.cc b/gtk2_ardour/ardour_ui_ed.cc
index b5a6281c1b..4777617a77 100644
--- a/gtk2_ardour/ardour_ui_ed.cc
+++ b/gtk2_ardour/ardour_ui_ed.cc
@@ -423,22 +423,41 @@ ARDOUR_UI::install_actions ()
RadioAction::Group denormal_group;
ActionManager::register_toggle_action (option_actions, X_("DenormalProtection"), _("Use DC bias"), mem_fun (*this, &ARDOUR_UI::toggle_denormal_protection));
-
- FPU fpu;
ActionManager::register_radio_action (option_actions, denormal_group, X_("DenormalNone"), _("No processor handling"), bind (mem_fun (*this, &ARDOUR_UI::set_denormal_model), DenormalNone));
- act = ActionManager::register_radio_action (option_actions, denormal_group, X_("DenormalFTZ"), _("Use FlushToZero"), bind (mem_fun (*this, &ARDOUR_UI::set_denormal_model), DenormalFTZ));
- if (!fpu.has_flush_to_zero()) {
+ // as of September 10th 2007, Valgrind cannot handle various FPU flag setting instructions
+ // so avoid them
+
+ if (getenv ("ARDOUR_RUNNING_UNDER_VALGRIND")) {
+
+ /* we still need these actions to exist, but make them all insensitive */
+
+ act = ActionManager::register_radio_action (option_actions, denormal_group, X_("DenormalFTZ"), _("Use FlushToZero"), bind (mem_fun (*this, &ARDOUR_UI::set_denormal_model), DenormalFTZ));
act->set_sensitive (false);
- }
- act = ActionManager::register_radio_action (option_actions, denormal_group, X_("DenormalDAZ"), _("Use DenormalsAreZero"), bind (mem_fun (*this, &ARDOUR_UI::set_denormal_model), DenormalDAZ));
- if (!fpu.has_denormals_are_zero()) {
+ act = ActionManager::register_radio_action (option_actions, denormal_group, X_("DenormalDAZ"), _("Use DenormalsAreZero"), bind (mem_fun (*this, &ARDOUR_UI::set_denormal_model), DenormalDAZ));
act->set_sensitive (false);
- }
- act = ActionManager::register_radio_action (option_actions, denormal_group, X_("DenormalFTZDAZ"), _("Use FlushToZero & DenormalsAreZero"), bind (mem_fun (*this, &ARDOUR_UI::set_denormal_model), DenormalFTZDAZ));
- if (!fpu.has_flush_to_zero() || !fpu.has_denormals_are_zero()) {
+ act = ActionManager::register_radio_action (option_actions, denormal_group, X_("DenormalFTZDAZ"), _("Use FlushToZero & DenormalsAreZero"), bind (mem_fun (*this, &ARDOUR_UI::set_denormal_model), DenormalFTZDAZ));
act->set_sensitive (false);
+
+ } else {
+
+ FPU fpu;
+
+ act = ActionManager::register_radio_action (option_actions, denormal_group, X_("DenormalFTZ"), _("Use FlushToZero"), bind (mem_fun (*this, &ARDOUR_UI::set_denormal_model), DenormalFTZ));
+ if (!fpu.has_flush_to_zero()) {
+ act->set_sensitive (false);
+ }
+
+ act = ActionManager::register_radio_action (option_actions, denormal_group, X_("DenormalDAZ"), _("Use DenormalsAreZero"), bind (mem_fun (*this, &ARDOUR_UI::set_denormal_model), DenormalDAZ));
+ if (!fpu.has_denormals_are_zero()) {
+ act->set_sensitive (false);
+ }
+
+ act = ActionManager::register_radio_action (option_actions, denormal_group, X_("DenormalFTZDAZ"), _("Use FlushToZero & DenormalsAreZero"), bind (mem_fun (*this, &ARDOUR_UI::set_denormal_model), DenormalFTZDAZ));
+ if (!fpu.has_flush_to_zero() || !fpu.has_denormals_are_zero()) {
+ act->set_sensitive (false);
+ }
}
act = ActionManager::register_toggle_action (option_actions, X_("DoNotRunPluginsWhileRecording"), _("Do not run plugins while recording"), mem_fun (*this, &ARDOUR_UI::toggle_DoNotRunPluginsWhileRecording));
diff --git a/gtk2_ardour/editor_audio_import.cc b/gtk2_ardour/editor_audio_import.cc
index ac29b5264e..a4a9a7a420 100644
--- a/gtk2_ardour/editor_audio_import.cc
+++ b/gtk2_ardour/editor_audio_import.cc
@@ -135,6 +135,7 @@ Editor::external_audio_dialog ()
}
if (response == RESPONSE_APPLY) {
+ sfbrowser->clear_selection ();
goto again;
}
}
diff --git a/gtk2_ardour/opts.cc b/gtk2_ardour/opts.cc
index e9be9e49ec..6a78be9cb9 100644
--- a/gtk2_ardour/opts.cc
+++ b/gtk2_ardour/opts.cc
@@ -91,7 +91,7 @@ ARDOUR_COMMAND_LINE::parse_opts (int argc, char *argv[])
{ "novst", 0, 0, 'V' },
{ "new", 1, 0, 'N' },
{ "no-hw-optimizations", 0, 0, 'O' },
- { "sync", 0, 0, 'O' },
+ { "sync", 0, 0, 'S' },
{ "curvetest", 1, 0, 'C' },
{ "sillyAppleUndocumentedFinderFeature", 1, 0, 'p' },
{ 0, 0, 0, 0 }
diff --git a/gtk2_ardour/sfdb_ui.cc b/gtk2_ardour/sfdb_ui.cc
index e239f432d5..af950d8e6e 100644
--- a/gtk2_ardour/sfdb_ui.cc
+++ b/gtk2_ardour/sfdb_ui.cc
@@ -175,7 +175,7 @@ SoundFileBox::set_session(Session* s)
bool
SoundFileBox::setup_labels (const ustring& filename)
{
- if (path.empty()) {
+ if (!path.empty()) {
// save existing tags
tags_changed ();
}
@@ -407,6 +407,13 @@ SoundFileBrowser::~SoundFileBrowser ()
}
void
+SoundFileBrowser::clear_selection ()
+{
+ chooser.unselect_all ();
+ found_list_view.get_selection()->unselect_all ();
+}
+
+void
SoundFileBrowser::chooser_file_activated ()
{
preview.audition ();
@@ -499,13 +506,13 @@ SoundFileBrowser::get_paths ()
if (n == 0) {
vector<ustring> filenames = chooser.get_filenames();
vector<ustring>::iterator i;
+
for (i = filenames.begin(); i != filenames.end(); ++i) {
struct stat buf;
if ((!stat((*i).c_str(), &buf)) && S_ISREG(buf.st_mode)) {
results.push_back (*i);
}
}
- return results;
} else {
@@ -518,8 +525,9 @@ SoundFileBrowser::get_paths ()
results.push_back (str);
}
- return results;
}
+
+ return results;
}
void
diff --git a/gtk2_ardour/sfdb_ui.h b/gtk2_ardour/sfdb_ui.h
index 4670796700..ec057814be 100644
--- a/gtk2_ardour/sfdb_ui.h
+++ b/gtk2_ardour/sfdb_ui.h
@@ -122,6 +122,8 @@ class SoundFileBrowser : public ArdourDialog
virtual void set_session (ARDOUR::Session*);
std::vector<Glib::ustring> get_paths ();
+ void clear_selection ();
+
Gtk::FileChooserWidget chooser;
Gtk::TreeView found_list_view;