From 2bc94116e85caf60f08ac020ec16858e42e2d332 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Mon, 15 Jun 2009 22:45:05 +0000 Subject: A few cleanups. Map scroll wheel to movement of the viewport. git-svn-id: svn://localhost/ardour2/branches/3.0@5197 d708f5d6-7413-0410-9779-e7cbd77b26cf --- gtk2_ardour/editor_summary.h | 24 ++++++++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) (limited to 'gtk2_ardour/editor_summary.h') diff --git a/gtk2_ardour/editor_summary.h b/gtk2_ardour/editor_summary.h index 0a279262c1..79c4174262 100644 --- a/gtk2_ardour/editor_summary.h +++ b/gtk2_ardour/editor_summary.h @@ -1,3 +1,22 @@ +/* + Copyright (C) 2009 Paul Davis + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + +*/ + #ifndef __gtk_ardour_editor_summary_h__ #define __gtk_ardour_editor_summary_h__ @@ -30,6 +49,7 @@ private: bool on_button_press_event (GdkEventButton *); bool on_button_release_event (GdkEventButton *); bool on_motion_notify_event (GdkEventMotion *); + bool on_scroll_event (GdkEventScroll *); void render (cairo_t *); GdkPixmap* get_pixmap (GdkDrawable *); @@ -42,8 +62,8 @@ private: bool _regions_dirty; ///< true if _pixmap requires re-rendering, otherwise false int _width; ///< pixmap width int _height; ///< pixmap height - double _pixels_per_frame; ///< pixels per frame for the x axis of the pixmap - double _vertical_scale; + double _x_scale; ///< pixels per frame for the x axis of the pixmap + double _y_scale; bool _move_dragging; double _x_offset; -- cgit v1.2.3