Ardour  9.0-pre0-582-g084a23a80d
cc121/gui.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2016 W.P. van Paassen
3  * Copyright (C) 2016-2019 Paul Davis <paul@linuxaudiosystems.com>
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License along
16  * with this program; if not, write to the Free Software Foundation, Inc.,
17  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18  */
19 
20 #ifndef __ardour_cc121_gui_h__
21 #define __ardour_cc121_gui_h__
22 
23 #include <vector>
24 #include <string>
25 
26 #include <gtkmm/box.h>
27 #include <gtkmm/combobox.h>
28 #include <gtkmm/image.h>
29 #include <gtkmm/table.h>
30 #include <gtkmm/treestore.h>
31 
32 namespace Gtk {
33  class CellRendererCombo;
34  class ListStore;
35 }
36 
37 #include "cc121.h"
38 
39 namespace ActionManager {
40  class ActionModel;
41 }
42 
43 namespace ArdourSurface {
44 
45 class CC121GUI : public Gtk::VBox
46 {
47 public:
50 
51 private:
59 
73 
77 
80  add (short_name);
81  add (full_name);
82  }
85  };
86 
89 
90  Glib::RefPtr<Gtk::ListStore> build_midi_port_list (std::vector<std::string> const & ports, bool for_input);
91  void active_port_changed (Gtk::ComboBox*,bool for_input);
92 
94 
95  Glib::RefPtr<Gtk::TreeStore> available_action_model;
96  std::map<std::string,std::string> action_map; // map from action names to paths
97 
98  void build_action_combo (Gtk::ComboBox& cb, std::vector<std::pair<std::string,std::string> > const & actions, CC121::ButtonID, CC121::ButtonState);
101 
103 };
104 
105 }
106 
107 #endif /* __ardour_cc121_gui_h__ */
const ActionManager::ActionModel & action_model
Definition: cc121/gui.h:93
void action_changed(Gtk::ComboBox *, CC121::ButtonID, CC121::ButtonState)
Gtk::Table action_table
Definition: cc121/gui.h:55
Gtk::ComboBox lock_combo
Definition: cc121/gui.h:66
Gtk::ComboBox allbypass_combo
Definition: cc121/gui.h:72
void build_action_combo(Gtk::ComboBox &cb, std::vector< std::pair< std::string, std::string > > const &actions, CC121::ButtonID, CC121::ButtonState)
void build_foot_action_combo(Gtk::ComboBox &, CC121::ButtonState)
Gtk::ComboBox eq4_combo
Definition: cc121/gui.h:70
Gtk::ComboBox foot_combo
Definition: cc121/gui.h:60
Gtk::ComboBox function1_combo
Definition: cc121/gui.h:61
MidiPortColumns midi_port_columns
Definition: cc121/gui.h:87
void active_port_changed(Gtk::ComboBox *, bool for_input)
Gtk::ComboBox eq1_combo
Definition: cc121/gui.h:67
std::map< std::string, std::string > action_map
Definition: cc121/gui.h:96
Gtk::ComboBox function3_combo
Definition: cc121/gui.h:63
Gtk::ComboBox eq3_combo
Definition: cc121/gui.h:69
Gtk::ComboBox function4_combo
Definition: cc121/gui.h:64
Gtk::ComboBox function2_combo
Definition: cc121/gui.h:62
Glib::RefPtr< Gtk::ListStore > build_midi_port_list(std::vector< std::string > const &ports, bool for_input)
Gtk::ComboBox value_combo
Definition: cc121/gui.h:65
PBD::ScopedConnectionList _port_connections
Definition: cc121/gui.h:75
Gtk::ComboBox eq2_combo
Definition: cc121/gui.h:68
Glib::RefPtr< Gtk::TreeStore > available_action_model
Definition: cc121/gui.h:95
Gtk::ComboBox input_combo
Definition: cc121/gui.h:56
Gtk::ComboBox output_combo
Definition: cc121/gui.h:57
Gtk::ComboBox eqtype_combo
Definition: cc121/gui.h:71
void build_user_action_combo(Gtk::ComboBox &, CC121::ButtonState, CC121::ButtonID)
void add(TreeModelColumnBase &column)
Definition: ardour_ui.h:188
Gtk::TreeModelColumn< std::string > short_name
Definition: cc121/gui.h:83
Gtk::TreeModelColumn< std::string > full_name
Definition: cc121/gui.h:84