summaryrefslogtreecommitdiff
path: root/gtk2_ardour/latency_gui.cc
diff options
context:
space:
mode:
authorCarl Hetherington <carl@carlh.net>2009-06-22 02:00:25 +0000
committerCarl Hetherington <carl@carlh.net>2009-06-22 02:00:25 +0000
commit92f3bc5c4486bd9d26979baf60c742c95faea62e (patch)
treedc1ccd8975d8dedc1b5363bcbf28263eea985699 /gtk2_ardour/latency_gui.cc
parent167929c25a4d2f839e078eeaa50ab40b8f544978 (diff)
Some small fixes to the latency GUI.
git-svn-id: svn://localhost/ardour2/branches/3.0@5243 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/latency_gui.cc')
-rw-r--r--gtk2_ardour/latency_gui.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/gtk2_ardour/latency_gui.cc b/gtk2_ardour/latency_gui.cc
index 3b4e3b4222..08c59dc64d 100644
--- a/gtk2_ardour/latency_gui.cc
+++ b/gtk2_ardour/latency_gui.cc
@@ -26,15 +26,15 @@ static const gchar *_unit_strings[] = {
std::vector<std::string> LatencyGUI::unit_strings;
std::string
-LatencyGUI::get_label (int&)
+LatencyBarController::get_label (int&)
{
- double const nframes = adjustment.get_value();
+ double const nframes = _latency_gui->adjustment.get_value();
std::stringstream s;
- if (nframes < (sample_rate / 1000.0)) {
+ if (nframes < (_latency_gui->sample_rate / 1000.0)) {
s << ((nframes64_t) rint (nframes)) << " samples";
} else {
- s << std::fixed << std::setprecision (2) << (nframes / (sample_rate / 1000.0)) << " msecs";
+ s << std::fixed << std::setprecision (2) << (nframes / (_latency_gui->sample_rate / 1000.0)) << " msecs";
}
return s.str ();
@@ -48,7 +48,7 @@ LatencyGUI::LatencyGUI (Latent& l, nframes64_t sr, nframes64_t psz)
ignored (new PBD::IgnorableControllable()),
/* max 1 second, step by frames, page by msecs */
adjustment (initial_value, 0.0, sample_rate, 1.0, sample_rate / 1000.0f),
- bc (adjustment, ignored),
+ bc (adjustment, this),
reset_button (_("Reset"))
{
Widget* w;