On 1/21/23 1:57 PM, Ted Felix wrote:
If you have time to make this change against master, I'd appreciate it. Then I can merge it right away. Thanks.
The attached patch against the latest master I have should apply cleanly unless there's been changes in the two files since then. Also feel free to remove my fork's extra copyright lines.
Hope this is what you were looking for. "Works for me" as the canonical saying goes. ;)
diff --git a/src/gui/dialogs/EventFilterDialog.cpp b/src/gui/dialogs/EventFilterDialog.cpp index 55fa9836c..4b545c5f5 100644 --- a/src/gui/dialogs/EventFilterDialog.cpp +++ b/src/gui/dialogs/EventFilterDialog.cpp @@ -3,7 +3,8 @@ /* Rosegarden A MIDI and audio sequencer and musical notation editor. - Copyright 2000-2022 the Rosegarden development team. + Copyright 2000-2023 the Rosegarden development team. + Modifications and additions Copyright (c) 2023 Mark R. Rubin aka "thanks4opensource" aka "thanks4opensrc" This file is Copyright 2003-2006 D. Michael McIntyre <dmmcin...@users.sourceforge.net> @@ -285,28 +286,38 @@ EventFilterDialog::populateDurationCombos() settings.endGroup(); } +void +EventFilterDialog::resetValuesToAll() +{ + m_pitchFromSpinBox ->setValue( 0); + m_pitchToSpinBox ->setValue(127); + m_velocityFromSpinBox->setValue( 0); + m_velocityToSpinBox ->setValue(127); + + m_noteDurationFromComboBox->setCurrentIndex( m_noteDurationToComboBox + ->count() + - 1); + m_noteDurationToComboBox ->setCurrentIndex(0); +} + void EventFilterDialog::slotToggleAll() { RG_DEBUG << "EventFilterDialog::slotToggleAll()"; - m_pitchFromSpinBox ->setValue(0); - m_pitchToSpinBox ->setValue(127); - m_velocityFromSpinBox ->setValue(0); - m_velocityToSpinBox ->setValue(127); - m_noteDurationFromComboBox ->setCurrentIndex(11); // hard coded; should be variable - m_noteDurationToComboBox ->setCurrentIndex(0); // 0 = unlimited; 11 = 0 + resetValuesToAll(); + m_notePitchIncludeComboBox ->setCurrentIndex(0); + m_noteVelocityIncludeComboBox->setCurrentIndex(0); + m_noteDurationIncludeComboBox->setCurrentIndex(0); } void EventFilterDialog::slotToggleNone() { RG_DEBUG << "EventFilterDialog::slotToggleNone()"; - m_pitchFromSpinBox ->setValue(0); - m_pitchToSpinBox ->setValue(0); - m_velocityFromSpinBox ->setValue(0); - m_velocityToSpinBox ->setValue(0); - m_noteDurationFromComboBox ->setCurrentIndex(11); - m_noteDurationToComboBox ->setCurrentIndex(11); + resetValuesToAll(); + m_notePitchIncludeComboBox ->setCurrentIndex(1); + m_noteVelocityIncludeComboBox->setCurrentIndex(1); + m_noteDurationIncludeComboBox->setCurrentIndex(1); } void diff --git a/src/gui/dialogs/EventFilterDialog.h b/src/gui/dialogs/EventFilterDialog.h index 2f80c40e0..4eb93bef9 100644 --- a/src/gui/dialogs/EventFilterDialog.h +++ b/src/gui/dialogs/EventFilterDialog.h @@ -3,7 +3,8 @@ /* Rosegarden A MIDI and audio sequencer and musical notation editor. - Copyright 2000-2022 the Rosegarden development team. + Copyright 2000-2023 the Rosegarden development team. + Modifications and additions Copyright (c) 2023 Mark R. Rubin aka "thanks4opensource" aka "thanks4opensrc" This file is Copyright 2003-2006 D. Michael McIntyre <dmmcin...@users.sourceforge.net> @@ -132,6 +133,8 @@ protected slots: private: + void resetValuesToAll(); + //---------[ data members ]----------------------------- QGridLayout* layout;
_______________________________________________ Rosegarden-user mailing list Rosegarden-user@lists.sourceforge.net - use the link below to unsubscribe https://lists.sourceforge.net/lists/listinfo/rosegarden-user