diff --git a/gtk2_ardour/editor_timefx.cc b/gtk2_ardour/editor_timefx.cc index 2f8adb8575..37678343cf 100644 --- a/gtk2_ardour/editor_timefx.cc +++ b/gtk2_ardour/editor_timefx.cc @@ -187,7 +187,7 @@ Editor::time_fx (RegionList& regions, Temporal::ratio_t ratio, bool pitching) current_timefx->request.time_fraction = current_timefx->get_time_fraction (); current_timefx->request.pitch_fraction = current_timefx->get_pitch_fraction (); - if (current_timefx->request.time_fraction == 1.0 && + if (current_timefx->request.time_fraction.to_double() == 1.0 && current_timefx->request.pitch_fraction == 1.0) { /* nothing to do */ current_timefx->hide (); @@ -269,7 +269,7 @@ Editor::time_fx (RegionList& regions, Temporal::ratio_t ratio, bool pitching) transients = NoTransients; precise = true; preserve_formants = false; - current_timefx->request.pitch_fraction = 1.0 / current_timefx->request.time_fraction; + current_timefx->request.pitch_fraction = 1.0 / current_timefx->request.time_fraction.to_double(); shortwin = true; // peaklock = false; break; diff --git a/gtk2_ardour/time_fx_dialog.cc b/gtk2_ardour/time_fx_dialog.cc index 6f25ad2c6b..c313cbe729 100644 --- a/gtk2_ardour/time_fx_dialog.cc +++ b/gtk2_ardour/time_fx_dialog.cc @@ -158,7 +158,7 @@ TimeFXDialog::TimeFXDialog (Editor& e, bool pitch, timecnt_t const & oldlen, tim table->attach (*clock_align, 1, 2, row, row+1, Gtk::AttachOptions (Gtk::EXPAND|Gtk::FILL), Gtk::FILL, 0, 0); row++; - const double fract = (double) (new_length / original_length); + const double fract = (new_length / original_length).to_double(); /* note the *100.0 to convert fract into a percentage */ duration_adjustment.set_value (fract*100.0); Gtk::SpinButton* spinner = manage (new Gtk::SpinButton (duration_adjustment, 1.0, 3)); @@ -313,5 +313,5 @@ TimeFXDialog::duration_clock_changed () PBD::Unwinder uw (ignore_adjustment_change, true); - duration_adjustment.set_value (100.0 * (double) (duration_clock->current_duration() / original_length)); + duration_adjustment.set_value (100.0 * (duration_clock->current_duration() / original_length).to_double()); }