39 Action( std::shared_ptr<Action> pOther );
102 friend bool operator ==(std::shared_ptr<Action> lhs, std::shared_ptr<Action> rhs ) {
103 return ( lhs->m_sType == rhs->m_sType &&
104 lhs->m_sParameter1 == rhs->m_sParameter1 &&
105 lhs->m_sParameter2 == rhs->m_sParameter2 &&
106 lhs->m_sParameter3 == rhs->m_sParameter3 &&
107 lhs->m_sValue == rhs->m_sValue );
109 friend bool operator !=(std::shared_ptr<Action> lhs, std::shared_ptr<Action> rhs ) {
110 return ( lhs->m_sType != rhs->m_sType ||
111 lhs->m_sParameter1 != rhs->m_sParameter1 ||
112 lhs->m_sParameter2 != rhs->m_sParameter2 ||
113 lhs->m_sParameter3 != rhs->m_sParameter3 ||
114 lhs->m_sValue != rhs->m_sValue );
125 QString
toQString(
const QString& sPrefix =
"",
bool bShort =
true )
const override;
232 bool handleActions( std::vector<std::shared_ptr<Action>> actions );
void setParameter3(QString text)
void setParameter2(QString text)
static QString getNullActionType()
void setParameter1(QString text)
bool isEquivalentTo(std::shared_ptr< Action > pOther)
void setValue(QString text)
bool isNull() const
Checks whether m_sType is of getNullActionType()
friend bool operator==(const Action &lhs, const Action &rhs)
QString toQString(const QString &sPrefix="", bool bShort=true) const override
Formatted string version for debugging purposes.
friend bool operator!=(const Action &lhs, const Action &rhs)
Action(QString sType=getNullActionType())
QString getParameter1() const
QString getParameter2() const
QString getParameter3() const
The MidiActionManager cares for the execution of MidiActions.
bool previous_bar(std::shared_ptr< Action >, H2Core::Hydrogen *)
static MidiActionManager * __instance
Object holding the current MidiActionManager singleton.
bool bpm_decrease(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool record_strobe(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool playlist_next_song(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool setSong(int nSongNumber, H2Core::Hydrogen *pHydrogen)
bool playlist_song(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool unmute(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool strip_volume_absolute(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool play(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool playlist_previous_song(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool select_instrument(std::shared_ptr< Action >, H2Core::Hydrogen *)
int m_nLastBpmChangeCCParameter
bool mute(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool record_exit(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool master_volume_absolute(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool pitch_level_absolute(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool tap_tempo(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool select_next_pattern_relative(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool handleAction(std::shared_ptr< Action > action)
The handleAction method is the heart of the MidiActionManager class.
bool strip_solo_toggle(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool beatcounter(std::shared_ptr< Action >, H2Core::Hydrogen *)
static MidiActionManager * get_instance()
Returns a pointer to the current MidiActionManager singleton stored in __instance.
bool pan_absolute(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool onlyNextPatternSelection(int nPatternNumber)
static void create_instance()
If __instance equals 0, a new MidiActionManager singleton will be created and stored in it.
bool pan_relative(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool pan_absolute_sym(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool select_next_pattern(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool bpm_fine_cc_relative(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool select_and_play_pattern(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool effect_level_absolute(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool redo_action(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool handleActions(std::vector< std::shared_ptr< Action > > actions)
Handles multiple actions at once and calls handleAction() on them.
bool filter_cutoff_level_absolute(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool strip_volume_relative(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool pause(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool next_bar(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool toggle_metronome(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool play_stop_pause_toggle(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool record_strobe_toggle(std::shared_ptr< Action >, H2Core::Hydrogen *)
QStringList getActionList()
bool select_only_next_pattern_cc_absolute(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool bpm_cc_relative(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool stop(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool record_ready(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool undo_action(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool select_only_next_pattern(std::shared_ptr< Action >, H2Core::Hydrogen *)
QStringList m_actionList
Holds the names of all Action identifiers which Hydrogen is able to interpret.
bool mute_toggle(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool nextPatternSelection(int nPatternNumber)
bool master_volume_relative(std::shared_ptr< Action >, H2Core::Hydrogen *)
int getParameterNumber(const QString &sActionType) const
bool select_next_pattern_cc_absolute(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool(MidiActionManager::* action_f)(std::shared_ptr< Action >, H2Core::Hydrogen *)
std::map< QString, std::pair< action_f, int > > m_actionMap
Holds all Action identifiers which Hydrogen is able to interpret.
bool bpm_increase(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool strip_mute_toggle(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool effect_level_relative(std::shared_ptr< Action >, H2Core::Hydrogen *)
bool gain_level_absolute(std::shared_ptr< Action >, H2Core::Hydrogen *)