remove unused member variable
[ardour.git] / libs / surfaces / push2 / scale.h
1 /*
2     Copyright (C) 2016 Paul Davis
3
4     This program is free software; you can redistribute it and/or modify
5     it under the terms of the GNU General Public License as published by
6     the Free Software Foundation; either version 2 of the License, or
7     (at your option) any later version.
8
9     This program is distributed in the hope that it will be useful,
10     but WITHOUT ANY WARRANTY; without even the implied warranty of
11     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12     GNU General Public License for more details.
13
14     You should have received a copy of the GNU General Public License
15     along with this program; if not, write to the Free Software
16     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
17 */
18
19 #ifndef __ardour_push2_scale_layout_h__
20 #define __ardour_push2_scale_layout_h__
21
22 #include <vector>
23
24 #include "layout.h"
25
26 namespace ARDOUR {
27         class Stripable;
28 }
29
30 namespace ArdourCanvas {
31         class Rectangle;
32 }
33
34 namespace ArdourSurface {
35
36 class ScaleLayout : public Push2Layout
37 {
38    public:
39         ScaleLayout (Push2& p, ARDOUR::Session&, std::string const &);
40         ~ScaleLayout ();
41
42         void render (ArdourCanvas::Rect const &, Cairo::RefPtr<Cairo::Context>) const;
43
44         void show ();
45
46         void button_upper (uint32_t n);
47         void button_lower (uint32_t n);
48         void button_up ();
49         void button_down ();
50         void button_left ();
51         void button_right ();
52         void strip_vpot (int, int);
53
54         void strip_vpot_touch (int, bool) {}
55
56    private:
57         ArdourCanvas::Rectangle* bg;
58         std::vector<ArdourCanvas::Text*> upper_text;
59         std::vector<ArdourCanvas::Text*> lower_text;
60         ArdourCanvas::Text* left_scroll_text;
61         ArdourCanvas::Text* right_scroll_text;
62         ArdourCanvas::Text* inkey_text;
63         ArdourCanvas::Text* chromatic_text;
64         ArdourCanvas::Text* close_text;
65         Push2Menu* scale_menu;
66         int last_vpot;
67         int vpot_delta_cnt;
68         Push2::Button* root_button;
69
70         void build_scale_menu ();
71         PBD::ScopedConnectionList menu_connections;
72         PBD::ScopedConnectionList p2_connections;
73         void mode_changed ();
74         void menu_rearranged ();
75         void show_root_state ();
76         void update_cursor_buttons ();
77 };
78
79 } /* namespace */
80
81 #endif /* __ardour_push2_scale_layout_h__ */