From 888c3b95380952edf547dac8545d20b5819c2f34 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Tue, 11 Aug 2009 18:23:53 +0000 Subject: Scroll to center properly on initial display. git-svn-id: http://svn.drobilla.net/lad/trunk/patchage@2176 a436a847-0d15-0410-975c-d299462d15a1 --- src/Patchage.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'src') diff --git a/src/Patchage.cpp b/src/Patchage.cpp index 9054547..22c52fb 100644 --- a/src/Patchage.cpp +++ b/src/Patchage.cpp @@ -161,8 +161,6 @@ Patchage::Patchage(int argc, char** argv) gtkmm_set_width_for_given_text(*_buffer_size_combo, "4096 frames", 40); _main_scrolledwin->add(*_canvas); - _canvas->scroll_to(static_cast(_canvas->width()/2 - 320), - static_cast(_canvas->height()/2 - 240)); // FIXME: hardcoded _main_scrolledwin->property_hadjustment().get_value()->set_step_increment(10); _main_scrolledwin->property_vadjustment().get_value()->set_step_increment(10); @@ -310,8 +308,6 @@ Patchage::attach() refresh(); update_toolbar(); - - //m_status_bar->push("Connected to JACK server"); } @@ -321,6 +317,7 @@ Patchage::idle_callback() // Initial run, attach if (_attach) { attach(); + _canvas->scroll_to_center(); _attach = false; } @@ -680,7 +677,6 @@ Patchage::on_view_toolbar() bool Patchage::on_scroll(GdkEventScroll* ev) { - cout << "ON SCROLL" << endl; return false; } -- cgit v1.2.1