KiCad PCB EDA Suite
panel_mouse_settings.h
Go to the documentation of this file.
1/*
2 * This program source code file is part of KiCad, a free EDA CAD application.
3 *
4 * Copyright (C) 2020 Jon Evans <[email protected]>
5 * Copyright (C) 2020 KiCad Developers, see AUTHORS.txt for contributors.
6 *
7 * This program is free software: you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License as published by the
9 * Free Software Foundation, either version 3 of the License, or (at your
10 * option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful, but
13 * WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License along
18 * with this program. If not, see <http://www.gnu.org/licenses/>.
19 */
20
21#ifndef KICAD_PANEL_MOUSE_SETTINGS_H
22#define KICAD_PANEL_MOUSE_SETTINGS_H
23
25
26
27class COMMON_SETTINGS;
28class PAGED_DIALOG;
29
30
32{
33 int zoom;
34 int panh;
35 int panv;
36};
37
38
40{
41public:
42 PANEL_MOUSE_SETTINGS( PAGED_DIALOG* aDialog, wxWindow* aParent );
43
45
46 void ResetPanel() override;
47
48protected:
49 bool TransferDataFromWindow() override;
50
51 bool TransferDataToWindow() override;
52
53 void OnScrollRadioButton( wxCommandEvent& event ) override;
54 void onMouseDefaults( wxCommandEvent& event ) override;
55 void onTrackpadDefaults( wxCommandEvent& event ) override;
56
57private:
58 void applySettingsToPanel( const COMMON_SETTINGS& aSettings );
59
61
63
64 bool isScrollModSetValid( const SCROLL_MOD_SET& aSet );
65
66protected:
68
69private:
71};
72
73
74#endif
Class PANEL_MOUSE_SETTINGS_BASE.
void onMouseDefaults(wxCommandEvent &event) override
bool TransferDataFromWindow() override
void ResetPanel() override
Reset the contents of this panel.
void applySettingsToPanel(const COMMON_SETTINGS &aSettings)
SCROLL_MOD_SET getScrollModSet()
SCROLL_MOD_SET m_currentScrollMod
bool isScrollModSetValid(const SCROLL_MOD_SET &aSet)
bool TransferDataToWindow() override
void onTrackpadDefaults(wxCommandEvent &event) override
void OnScrollRadioButton(wxCommandEvent &event) override
PANEL_MOUSE_SETTINGS(PAGED_DIALOG *aDialog, wxWindow *aParent)