mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-24 07:27:44 +01:00
proper fix for stereo region wave drawing bug; make trackheight operations apply to all selected tracks
git-svn-id: svn://localhost/ardour2/branches/2.0-ongoing@3019 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
36b4930c45
commit
9eb8d34ecf
6 changed files with 30 additions and 14 deletions
|
|
@ -122,7 +122,7 @@ AudioRegionView::init (Gdk::Color& basic_color, bool wfd)
|
|||
// FIXME: Some redundancy here with RegionView::init. Need to figure out
|
||||
// where order is important and where it isn't...
|
||||
|
||||
RegionView::init (basic_color, true);
|
||||
RegionView::init (basic_color, wfd);
|
||||
|
||||
XMLNode *node;
|
||||
|
||||
|
|
@ -786,6 +786,15 @@ AudioRegionView::create_waves ()
|
|||
wave_caches.push_back (WaveView::create_cache ());
|
||||
|
||||
if (wait_for_data) {
|
||||
if (audio_region()->source(n)->peaks_ready (bind (mem_fun(*this, &AudioRegionView::peaks_ready_handler), n), data_ready_connection)) {
|
||||
create_one_wave (n, true);
|
||||
} else {
|
||||
// we'll get a PeaksReady signal from the source in the future
|
||||
// and will call create_one_wave(n) then.
|
||||
}
|
||||
|
||||
} else {
|
||||
|
||||
create_one_wave (n, true);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@ class AudioRegionView : public RegionView
|
|||
|
||||
~AudioRegionView ();
|
||||
|
||||
virtual void init (Gdk::Color& base_color, bool wait_for_data = false);
|
||||
virtual void init (Gdk::Color& base_color, bool wait_for_data);
|
||||
|
||||
boost::shared_ptr<ARDOUR::AudioRegion> audio_region() const;
|
||||
|
||||
|
|
|
|||
|
|
@ -182,9 +182,6 @@ Editor::set_selected_track_as_side_effect (bool force)
|
|||
void
|
||||
Editor::set_selected_track (TimeAxisView& view, Selection::Operation op, bool no_remove)
|
||||
{
|
||||
|
||||
cerr << "set selected track, op = " << op << " selected ? " << selection->selected (&view) << " no remove? " << no_remove << endl;
|
||||
|
||||
switch (op) {
|
||||
case Selection::Toggle:
|
||||
if (selection->selected (&view)) {
|
||||
|
|
|
|||
|
|
@ -815,7 +815,7 @@ EngineControl::driver_changed ()
|
|||
|
||||
vector<string>& strings = devices[driver];
|
||||
|
||||
if (strings.empty() && driver != "FFADO") {
|
||||
if (strings.empty() && driver != "FFADO" && driver != "Dummy") {
|
||||
error << string_compose (_("No devices found for driver \"%1\""), driver) << endmsg;
|
||||
return;
|
||||
}
|
||||
|
|
@ -835,7 +835,7 @@ EngineControl::driver_changed ()
|
|||
interface_combo.set_active_text (strings.front());
|
||||
input_device_combo.set_active_text (strings.front());
|
||||
output_device_combo.set_active_text (strings.front());
|
||||
}
|
||||
}
|
||||
|
||||
if (driver == "ALSA") {
|
||||
soft_mode_button.set_sensitive (true);
|
||||
|
|
|
|||
|
|
@ -271,7 +271,6 @@ TimeAxisView::controls_ebox_scroll (GdkEventScroll* ev)
|
|||
bool
|
||||
TimeAxisView::controls_ebox_button_release (GdkEventButton* ev)
|
||||
{
|
||||
cerr << "CEB button release\n";
|
||||
switch (ev->button) {
|
||||
case 1:
|
||||
selection_click (ev);
|
||||
|
|
@ -353,6 +352,16 @@ TimeAxisView::step_height (bool bigger)
|
|||
}
|
||||
}
|
||||
|
||||
void
|
||||
TimeAxisView::set_heights (TrackHeight h)
|
||||
{
|
||||
TrackSelection& ts (editor.get_selection().tracks);
|
||||
|
||||
for (TrackSelection::iterator i = ts.begin(); i != ts.end(); ++i) {
|
||||
(*i)->set_height (h);
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
TimeAxisView::set_height (TrackHeight h)
|
||||
{
|
||||
|
|
@ -586,12 +595,12 @@ TimeAxisView::build_size_menu ()
|
|||
size_menu->set_name ("ArdourContextMenu");
|
||||
MenuList& items = size_menu->items();
|
||||
|
||||
items.push_back (MenuElem (_("Largest"), bind (mem_fun (*this, &TimeAxisView::set_height), Largest)));
|
||||
items.push_back (MenuElem (_("Large"), bind (mem_fun (*this, &TimeAxisView::set_height), Large)));
|
||||
items.push_back (MenuElem (_("Larger"), bind (mem_fun (*this, &TimeAxisView::set_height), Larger)));
|
||||
items.push_back (MenuElem (_("Normal"), bind (mem_fun (*this, &TimeAxisView::set_height), Normal)));
|
||||
items.push_back (MenuElem (_("Smaller"), bind (mem_fun (*this, &TimeAxisView::set_height),Smaller)));
|
||||
items.push_back (MenuElem (_("Small"), bind (mem_fun (*this, &TimeAxisView::set_height), Small)));
|
||||
items.push_back (MenuElem (_("Largest"), bind (mem_fun (*this, &TimeAxisView::set_heights), Largest)));
|
||||
items.push_back (MenuElem (_("Large"), bind (mem_fun (*this, &TimeAxisView::set_heights), Large)));
|
||||
items.push_back (MenuElem (_("Larger"), bind (mem_fun (*this, &TimeAxisView::set_heights), Larger)));
|
||||
items.push_back (MenuElem (_("Normal"), bind (mem_fun (*this, &TimeAxisView::set_heights), Normal)));
|
||||
items.push_back (MenuElem (_("Smaller"), bind (mem_fun (*this, &TimeAxisView::set_heights),Smaller)));
|
||||
items.push_back (MenuElem (_("Small"), bind (mem_fun (*this, &TimeAxisView::set_heights), Small)));
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
|||
|
|
@ -322,6 +322,7 @@ class TimeAxisView : public virtual AxisView
|
|||
static void compute_controls_size_info ();
|
||||
static bool need_size_info;
|
||||
|
||||
void set_heights (TrackHeight);
|
||||
void set_height_pixels (uint32_t h);
|
||||
void color_handler ();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue