mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-09 00:04:56 +01:00
midi scroomer updates streamview during drags.
This commit is contained in:
parent
910cbc600c
commit
2ec2c1c017
2 changed files with 19 additions and 5 deletions
|
|
@ -163,8 +163,6 @@ MidiTimeAxisView::set_route (boost::shared_ptr<Route> rt)
|
||||||
true);
|
true);
|
||||||
}
|
}
|
||||||
|
|
||||||
midi_view()->NoteRangeChanged.connect (
|
|
||||||
sigc::mem_fun (*this, &MidiTimeAxisView::note_range_changed));
|
|
||||||
_view->ContentsHeightChanged.connect (
|
_view->ContentsHeightChanged.connect (
|
||||||
sigc::mem_fun (*this, &MidiTimeAxisView::contents_height_changed));
|
sigc::mem_fun (*this, &MidiTimeAxisView::contents_height_changed));
|
||||||
|
|
||||||
|
|
@ -207,11 +205,12 @@ MidiTimeAxisView::set_route (boost::shared_ptr<Route> rt)
|
||||||
_piano_roll_header->ToggleNoteSelection.connect (
|
_piano_roll_header->ToggleNoteSelection.connect (
|
||||||
sigc::mem_fun (*this, &MidiTimeAxisView::toggle_note_selection));
|
sigc::mem_fun (*this, &MidiTimeAxisView::toggle_note_selection));
|
||||||
|
|
||||||
/* Suspend updates of the StreamView during scroomer drags to speed things up */
|
/* Update StreamView during scroomer drags.*/
|
||||||
|
|
||||||
_range_scroomer->DragStarting.connect (
|
_range_scroomer->DragStarting.connect (
|
||||||
sigc::mem_fun (*midi_view(), &MidiStreamView::suspend_updates));
|
sigc::mem_fun (*this, &MidiTimeAxisView::start_scroomer_update));
|
||||||
_range_scroomer->DragFinishing.connect (
|
_range_scroomer->DragFinishing.connect (
|
||||||
sigc::mem_fun (*midi_view(), &MidiStreamView::resume_updates));
|
sigc::mem_fun (*this, &MidiTimeAxisView::stop_scroomer_update));
|
||||||
|
|
||||||
/* Put the scroomer and the keyboard in a VBox with a padding
|
/* Put the scroomer and the keyboard in a VBox with a padding
|
||||||
label so that they can be reduced in height for stacked-view
|
label so that they can be reduced in height for stacked-view
|
||||||
|
|
@ -431,6 +430,17 @@ MidiTimeAxisView::drop_instrument_ref ()
|
||||||
{
|
{
|
||||||
midnam_connection.drop_connections ();
|
midnam_connection.drop_connections ();
|
||||||
}
|
}
|
||||||
|
void
|
||||||
|
MidiTimeAxisView::start_scroomer_update ()
|
||||||
|
{
|
||||||
|
_note_range_changed_connection = midi_view()->NoteRangeChanged.connect (
|
||||||
|
sigc::mem_fun (*this, &MidiTimeAxisView::note_range_changed));
|
||||||
|
}
|
||||||
|
void
|
||||||
|
MidiTimeAxisView::stop_scroomer_update ()
|
||||||
|
{
|
||||||
|
_note_range_changed_connection.disconnect();
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
MidiTimeAxisView::update_patch_selector ()
|
MidiTimeAxisView::update_patch_selector ()
|
||||||
|
|
|
||||||
|
|
@ -123,6 +123,10 @@ private:
|
||||||
void drop_instrument_ref ();
|
void drop_instrument_ref ();
|
||||||
PBD::ScopedConnectionList midnam_connection;
|
PBD::ScopedConnectionList midnam_connection;
|
||||||
|
|
||||||
|
void start_scroomer_update ();
|
||||||
|
void stop_scroomer_update ();
|
||||||
|
sigc::connection _note_range_changed_connection;
|
||||||
|
|
||||||
void model_changed(const std::string& model);
|
void model_changed(const std::string& model);
|
||||||
void custom_device_mode_changed(const std::string& mode);
|
void custom_device_mode_changed(const std::string& mode);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue