summaryrefslogtreecommitdiff
path: root/gtk2_ardour/editor.h
diff options
context:
space:
mode:
authornick_m <mainsbridge@gmail.com>2014-12-15 00:13:38 +1100
committerPaul Davis <paul@linuxaudiosystems.com>2014-12-18 11:03:10 -0500
commit9af9e17adc96f7c27ce0e1651d6949393e787636 (patch)
tree395fb4ddffd3a66ba0e8021bd7ec1de137c315d2 /gtk2_ardour/editor.h
parent2c8a769aaef7465f170edf37982733fd19d89c0e (diff)
Add editor selection state to session history via a SelectionMemento, which
combines selection related editor properties with the current editor selection. The related editor properties are: mouse mode, zoom setting, left frame of the canvas, y origin of the canvas. Selection state now includes region views (storing the underlying region id) and time. This patch also fixes a region mute undo bug.
Diffstat (limited to 'gtk2_ardour/editor.h')
-rw-r--r--gtk2_ardour/editor.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/gtk2_ardour/editor.h b/gtk2_ardour/editor.h
index ab781d3cd4..fa86833dc6 100644
--- a/gtk2_ardour/editor.h
+++ b/gtk2_ardour/editor.h
@@ -58,6 +58,7 @@
#include "enums.h"
#include "editor_items.h"
#include "region_selection.h"
+#include "selection_memento.h"
namespace Gtkmm2ext {
class TearOff;
@@ -149,7 +150,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
double visible_canvas_height () const {
return _visible_canvas_height;
}
- double trackviews_height() const;
+ double trackviews_height () const;
void cycle_snap_mode ();
void next_snap_choice ();
@@ -372,6 +373,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
void update_tearoff_visibility();
void reattach_all_tearoffs ();
+ double get_y_origin () const;
void reset_x_origin (framepos_t);
void reset_x_origin_to_follow_playhead ();
void reset_y_origin (double);
@@ -405,6 +407,8 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
void get_regions_corresponding_to (boost::shared_ptr<ARDOUR::Region> region, std::vector<RegionView*>& regions, bool src_comparison);
+ void get_regionviews_by_id (PBD::ID const & id, RegionSelection & regions) const;
+
void center_screen (framepos_t);
TrackViewList axis_views_from_routes (boost::shared_ptr<ARDOUR::RouteList>) const;
@@ -1716,6 +1720,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
Selection* selection;
Selection* cut_buffer;
+ SelectionMemento* _selection_memento;
void time_selection_changed ();
void update_time_selection_display ();
@@ -1875,7 +1880,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
void write_selection ();
- XMLNode *before; /* used in *_reversible_command */
+ std::list<XMLNode *> before; /* used in *_reversible_command */
void update_title ();
void update_title_s (const std::string & snapshot_name);