2017-12-22 14:20:59 -05:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2017 Robin Gareus <robin@gareus.org>
|
|
|
|
*
|
2019-08-02 17:26:43 -04:00
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
* (at your option) any later version.
|
2017-12-22 14:20:59 -05:00
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
2019-08-02 17:26:43 -04:00
|
|
|
* You should have received a copy of the GNU General Public License along
|
|
|
|
* with this program; if not, write to the Free Software Foundation, Inc.,
|
|
|
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
2017-12-22 14:20:59 -05:00
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef _gtkardour_transport_control_h_
|
|
|
|
#define _gtkardour_transport_control_h_
|
|
|
|
|
|
|
|
#include <gtkmm/widget.h>
|
|
|
|
#include "pbd/controllable.h"
|
|
|
|
|
2020-04-27 00:59:54 -04:00
|
|
|
#include "ardour/session_handle.h"
|
|
|
|
|
Fix typos in gtk2_ardour/ directory
Found via `codespell -q 3 -S *.po,./share/patchfiles,./libs -L ba,buss,busses,doubleclick,hsi,ontop,ro,seh,siz,sur,te,trough,ue`
2022-01-26 12:35:38 -05:00
|
|
|
/* This is an API implemented by AROUR_UI,
|
2017-12-22 14:20:59 -05:00
|
|
|
* and made available to transport-control-UIs
|
|
|
|
*/
|
|
|
|
class TransportControlProvider
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
TransportControlProvider ();
|
|
|
|
virtual ~TransportControlProvider () {}
|
|
|
|
|
|
|
|
/* show metronome preferences */
|
|
|
|
virtual bool click_button_clicked (GdkEventButton *) = 0;
|
|
|
|
|
2020-04-27 00:59:54 -04:00
|
|
|
struct TransportControllable : public PBD::Controllable, public ARDOUR::SessionHandlePtr {
|
2017-12-22 14:20:59 -05:00
|
|
|
enum ToggleType {
|
|
|
|
Roll = 0,
|
|
|
|
Stop,
|
|
|
|
RecordEnable,
|
|
|
|
GotoStart,
|
|
|
|
GotoEnd,
|
|
|
|
AutoLoop,
|
|
|
|
PlaySelection,
|
|
|
|
};
|
|
|
|
|
|
|
|
TransportControllable (std::string name, ToggleType);
|
|
|
|
void set_value (double, PBD::Controllable::GroupControlDisposition group_override);
|
2020-04-27 00:59:54 -04:00
|
|
|
double get_value (void) const;
|
2017-12-22 14:20:59 -05:00
|
|
|
|
|
|
|
ToggleType type;
|
|
|
|
};
|
|
|
|
|
2023-02-16 18:33:28 -05:00
|
|
|
std::shared_ptr<TransportControllable> roll_controllable;
|
|
|
|
std::shared_ptr<TransportControllable> stop_controllable;
|
|
|
|
std::shared_ptr<TransportControllable> goto_start_controllable;
|
|
|
|
std::shared_ptr<TransportControllable> goto_end_controllable;
|
|
|
|
std::shared_ptr<TransportControllable> auto_loop_controllable;
|
|
|
|
std::shared_ptr<TransportControllable> play_selection_controllable;
|
|
|
|
std::shared_ptr<TransportControllable> rec_controllable;
|
2017-12-22 14:20:59 -05:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|