diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2009-10-02 15:38:17 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2009-10-02 15:38:17 +0000 |
commit | b2d08a44b423ce9349b482e4c55ab613729c5d7d (patch) | |
tree | 1260a18e0687d76f749c61fc3a6a8fe82aa73842 /gtk2_ardour/editor.cc | |
parent | 03f6001f4a47d7095f148aa193042c9d0656bc56 (diff) |
now in gtk2_ardour: replace all instances of prop->value() == "yes" with string_is_affirmative (prop->value()) to avoid XML property SNAFUs
git-svn-id: svn://localhost/ardour2/branches/2.0-ongoing@5721 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/editor.cc')
-rw-r--r-- | gtk2_ardour/editor.cc | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/gtk2_ardour/editor.cc b/gtk2_ardour/editor.cc index f5aa512eab..15b6519810 100644 --- a/gtk2_ardour/editor.cc +++ b/gtk2_ardour/editor.cc @@ -2469,7 +2469,7 @@ Editor::set_state (const XMLNode& node) } if ((prop = node.property ("show-waveforms"))) { - bool yn = (prop->value() == "yes"); + bool yn = (string_is_affirmative (prop->value())); _show_waveforms = !yn; RefPtr<Action> act = ActionManager::get_action (X_("Editor"), X_("toggle-waveform-visible")); if (act) { @@ -2481,7 +2481,7 @@ Editor::set_state (const XMLNode& node) } if ((prop = node.property ("show-waveforms-rectified"))) { - bool yn = (prop->value() == "yes"); + bool yn = (string_is_affirmative (prop->value())); _show_waveforms_rectified = !yn; RefPtr<Action> act = ActionManager::get_action (X_("Editor"), X_("toggle-waveform-rectified")); if (act) { @@ -2493,7 +2493,7 @@ Editor::set_state (const XMLNode& node) } if ((prop = node.property ("show-waveforms-recording"))) { - bool yn = (prop->value() == "yes"); + bool yn = (string_is_affirmative (prop->value())); _show_waveforms_recording = !yn; RefPtr<Action> act = ActionManager::get_action (X_("Editor"), X_("ToggleWaveformsWhileRecording")); if (act) { @@ -2505,7 +2505,7 @@ Editor::set_state (const XMLNode& node) } if ((prop = node.property ("show-measures"))) { - bool yn = (prop->value() == "yes"); + bool yn = (string_is_affirmative (prop->value())); _show_measures = !yn; RefPtr<Action> act = ActionManager::get_action (X_("Editor"), X_("ToggleMeasureVisibility")); if (act) { @@ -2517,7 +2517,7 @@ Editor::set_state (const XMLNode& node) } if ((prop = node.property ("follow-playhead"))) { - bool yn = (prop->value() == "yes"); + bool yn = (string_is_affirmative (prop->value())); set_follow_playhead (yn); RefPtr<Action> act = ActionManager::get_action (X_("Editor"), X_("toggle-follow-playhead")); if (act) { @@ -2529,7 +2529,7 @@ Editor::set_state (const XMLNode& node) } if ((prop = node.property ("stationary-playhead"))) { - bool yn = (prop->value() == "yes"); + bool yn = (string_is_affirmative (prop->value())); set_stationary_playhead (yn); RefPtr<Action> act = ActionManager::get_action (X_("Editor"), X_("toggle-stationary-playhead")); if (act) { @@ -2546,7 +2546,7 @@ Editor::set_state (const XMLNode& node) } if ((prop = node.property ("xfades-visible"))) { - bool yn = (prop->value() == "yes"); + bool yn = (string_is_affirmative (prop->value())); _xfade_visibility = !yn; // set_xfade_visibility (yn); } |