update CycleTimer to utilize NDEBUG and PBD::DEBUG so that we can leave them in place...
[ardour.git] / gtk2_ardour / location_ui.h
index 5ab297f69c7de8fa78eff5198fa4b4bea238a8b7..9a316bc1edfe24255aed2956c885fc52e045566f 100644 (file)
@@ -34,7 +34,7 @@
 #include "ardour/location.h"
 #include "ardour/session_handle.h"
 
-#include "ardour_dialog.h"
+#include "ardour_window.h"
 #include "audio_clock.h"
 
 namespace ARDOUR {
@@ -42,6 +42,8 @@ namespace ARDOUR {
        class Location;
 }
 
+class ClockGroup;
+
 class LocationEditRow  : public Gtk::HBox, public ARDOUR::SessionHandlePtr
 {
   public:
@@ -55,6 +57,7 @@ class LocationEditRow  : public Gtk::HBox, public ARDOUR::SessionHandlePtr
 
        void set_number (int);
        void focus_name();
+        void set_clock_group (ClockGroup&);
 
        sigc::signal<void,ARDOUR::Location*> remove_requested;
        sigc::signal<void> redraw_ranges;
@@ -97,11 +100,12 @@ class LocationEditRow  : public Gtk::HBox, public ARDOUR::SessionHandlePtr
 
 
        Gtk::Label    performer_label;
-       Gtk::Entry  performer_entry;
+       Gtk::Entry    performer_entry;
        Gtk::Label    composer_label;
-       Gtk::Entry  composer_entry;
+       Gtk::Entry    composer_entry;
        Gtk::CheckButton   scms_check_button;
        Gtk::CheckButton   preemph_check_button;
+        ClockGroup* _clock_group;
 
        guint32 i_am_the_modifier;
        int   number;
@@ -111,11 +115,10 @@ class LocationEditRow  : public Gtk::HBox, public ARDOUR::SessionHandlePtr
        void performer_entry_changed ();
        void composer_entry_changed ();
 
-       void set_button_pressed (LocationPart part);
+       void to_playhead_button_pressed (LocationPart part);
        void go_button_pressed (LocationPart part);
 
        void clock_changed (LocationPart part);
-       void change_aborted (LocationPart part);
 
        void cd_toggled ();
        void hide_toggled ();
@@ -144,14 +147,17 @@ class LocationUI : public Gtk::HBox, public ARDOUR::SessionHandlePtr
   public:
        LocationUI ();
        ~LocationUI ();
-       
+
        void set_session (ARDOUR::Session *);
+        void set_clock_mode (AudioClock::Mode);
 
        void add_new_location();
        void add_new_range();
 
        void refresh_location_list ();
 
+       XMLNode & get_state () const;
+
   private:
        ARDOUR::LocationStack* locations;
        ARDOUR::Location *newest_location;
@@ -191,15 +197,18 @@ class LocationUI : public Gtk::HBox, public ARDOUR::SessionHandlePtr
        void location_added (ARDOUR::Location *);
        void locations_changed (ARDOUR::Locations::Change);
        void map_locations (ARDOUR::Locations::LocationList&);
+
+        ClockGroup* _clock_group;
+       AudioClock::Mode clock_mode_from_session_instant_xml () const;
 };
 
-class LocationUIWindow : public ArdourDialog
+class LocationUIWindow : public ArdourWindow
 {
   public:
        LocationUIWindow ();
        ~LocationUIWindow ();
 
-       void on_show();
+       void on_map ();
        void set_session (ARDOUR::Session *);
 
        LocationUI& ui() { return _ui; }