1 #ifndef __gtk2_ardour_region_layering_order_editor_h__
2 #define __gtk2_ardour_region_layering_order_editor_h__
4 #include <gtkmm/dialog.h>
5 #include <gtkmm/liststore.h>
6 #include <gtkmm/treeview.h>
7 #include <gtkmm/scrolledwindow.h>
9 #include "ardour/region.h"
10 #include "ardour/playlist.h"
12 #include "ardour_dialog.h"
13 #include "audio_clock.h"
21 class RegionLayeringOrderEditor
: public ArdourDialog
24 RegionLayeringOrderEditor (PublicEditor
&);
25 virtual ~RegionLayeringOrderEditor ();
27 void set_context(const std::string
& name
, ARDOUR::Session
* s
, const boost::shared_ptr
<ARDOUR::Playlist
> & pl
, ARDOUR::framepos_t position
);
28 void maybe_present ();
31 virtual bool on_key_press_event (GdkEventKey
* event
);
34 boost::shared_ptr
<ARDOUR::Playlist
> playlist
;
37 uint32_t regions_at_position
;
39 PBD::ScopedConnection playlist_modified_connection
;
41 struct LayeringOrderColumns
: public Gtk::TreeModel::ColumnRecord
{
42 LayeringOrderColumns () {
46 Gtk::TreeModelColumn
<std::string
> name
;
47 Gtk::TreeModelColumn
<boost::shared_ptr
<ARDOUR::Region
> > region
;
49 LayeringOrderColumns layering_order_columns
;
50 Glib::RefPtr
<Gtk::ListStore
> layering_order_model
;
51 Gtk::TreeView layering_order_display
;
53 Gtk::Label track_label
;
54 Gtk::Label track_name_label
;
55 Gtk::Label clock_label
;
56 Gtk::ScrolledWindow scroller
; // Available layers
59 void row_activated (const Gtk::TreeModel::Path
& path
, Gtk::TreeViewColumn
* column
);
61 void playlist_modified ();
64 #endif /* __gtk2_ardour_region_layering_order_editor_h__ */