X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=gtk2_ardour%2Feditor_cursors.h;h=f6d4997690d42d7be8ddb6bc3a8e6ef9155d43a3;hb=1f6c54a2f053caa8afec70f2acffdb7f7d73f09f;hp=93689c6e7b368fcdc9c4c75881ed0620fda084ae;hpb=580520b12f90251e38d94a1a5d6a199b76142b0b;p=ardour.git diff --git a/gtk2_ardour/editor_cursors.h b/gtk2_ardour/editor_cursors.h index 93689c6e7b..f6d4997690 100644 --- a/gtk2_ardour/editor_cursors.h +++ b/gtk2_ardour/editor_cursors.h @@ -17,7 +17,11 @@ */ +#ifndef __gtk_ardour_editor_cursors_h__ +#define __gtk_ardour_editor_cursors_h__ + #include "pbd/signals.h" +#include "ardour/types.h" #include "canvas/arrow.h" #include "canvas/line.h" @@ -25,36 +29,35 @@ class Editor; -class EditorCursor { - public: - EditorCursor (Editor&, bool (Editor::*)(GdkEvent*,ArdourCanvas::Item*)); - ~EditorCursor (); +class EditorCursor +{ +public: + EditorCursor (Editor&, bool (Editor::*)(GdkEvent*,ArdourCanvas::Item*)); + EditorCursor (Editor&); + ~EditorCursor (); void set_position (framepos_t); void show (); void hide (); - void set_color (ArdourCanvas::Color); + void set_color (Gtkmm2ext::Color); + void set_sensitive (bool); framepos_t current_frame () const { return _current_frame; } - ArdourCanvas::Line& track_canvas_item () { - return _track_canvas_item; - } - - ArdourCanvas::Arrow& time_bar_canvas_item () { - return _time_bars_canvas_item; + ArdourCanvas::Arrow& track_canvas_item () { + return *_track_canvas_item; } PBD::Signal1 PositionChanged; - private: +private: Editor& _editor; - ArdourCanvas::Arrow _time_bars_canvas_item; - ArdourCanvas::Line _track_canvas_item; + ArdourCanvas::Arrow* _track_canvas_item; framepos_t _current_frame; - double _length; }; + +#endif // __gtk_ardour_editor_cursors_h__