X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=gtk2_ardour%2Fghostregion.h;h=aa4ec8b2f32b8cfd944cdb186a66070da00ef8ab;hb=66e580d683a1bd7e63ee159f40e8e16a4fc0bf7f;hp=f4848fd3ccd2f659e2d7d7e18ff83e80b109d751;hpb=05c3850ac197c6a7c5217b060dc596caabdf3c27;p=ardour.git diff --git a/gtk2_ardour/ghostregion.h b/gtk2_ardour/ghostregion.h index f4848fd3cc..aa4ec8b2f3 100644 --- a/gtk2_ardour/ghostregion.h +++ b/gtk2_ardour/ghostregion.h @@ -21,6 +21,7 @@ #define __ardour_gtk_ghost_region_h__ #include +#include #include "pbd/signals.h" namespace ArdourCanvas { @@ -86,6 +87,7 @@ public: NoteBase* event; ArdourCanvas::Item* item; + bool is_hit; }; MidiGhostRegion(RegionView& rv, @@ -106,25 +108,25 @@ public: void set_samples_per_pixel (double spu); void set_colors(); - void update_range(); - void set_contents_height(); + void update_contents_height(); void add_note(NoteBase*); - void update_note (Note*); - void update_hit (Hit*); + void update_note (Note* note, bool hide); + void update_hit (Hit* hit, bool hide); void remove_note (NoteBase*); void clear_events(); private: + ArdourCanvas::Container* _note_group; ArdourCanvas::Color _outline; ArdourCanvas::Rectangle* _tmp_rect; ArdourCanvas::Polygon* _tmp_poly; - MidiGhostRegion::GhostEvent* find_event (NoteBase*); typedef Evoral::Note NoteType; + MidiGhostRegion::GhostEvent* find_event (boost::shared_ptr); - typedef std::map, MidiGhostRegion::GhostEvent* > EventList; + typedef boost::unordered_map, MidiGhostRegion::GhostEvent* > EventList; EventList events; EventList::iterator _optimization_iterator; };