#include <gtkmm/drawingarea.h>
#include "gtkmm2ext/binding_proxy.h"
+#include "gtkmm2ext/cairo_widget.h"
#include "pbd/controllable.h"
#include "ardour/session_handle.h"
~ShuttleControl ();
void map_transport_state ();
- void update_speed_display ();
- void set_shuttle_fract (double, bool zero_ok = false);
+ void set_shuttle_fract (double, bool zero_ok = false);
double get_shuttle_fract () const { return shuttle_fract; }
void set_session (ARDOUR::Session*);
struct ShuttleControllable : public PBD::Controllable {
ShuttleControllable (ShuttleControl&);
- void set_value (double);
+ void set_value (double, PBD::Controllable::GroupControlDisposition group_override);
double get_value (void) const;
double lower() const { return -1.0; }
};
boost::shared_ptr<ShuttleControllable> controllable() const { return _controllable; }
+ void set_colors ();
protected:
bool _hovering;
float last_speed_displayed;
bool shuttle_grabbed;
double shuttle_speed_on_grab;
+ double requested_speed;
float shuttle_fract;
boost::shared_ptr<ShuttleControllable> _controllable;
cairo_pattern_t* pattern;
Gtk::Menu* shuttle_style_menu;
Gtk::Menu* shuttle_context_menu;
BindingProxy binding_proxy;
-
+ Glib::RefPtr<Pango::Layout> left_text;
+ Glib::RefPtr<Pango::Layout> right_text;
+ Pango::AttrList text_attributes;
+ Pango::AttrColor* text_color;
+ float bg_r, bg_g, bg_b;
void build_shuttle_context_menu ();
void show_shuttle_context_menu ();
void shuttle_style_changed();
void shuttle_unit_clicked ();
void set_shuttle_max_speed (float);
+ void reset_speed ();
bool on_enter_notify_event (GdkEventCrossing*);
bool on_leave_notify_event (GdkEventCrossing*);