KiCad PCB EDA Suite
Loading...
Searching...
No Matches
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 The 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
18 * along with this program. If not, see <https://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;
29enum class TOUCHPAD_MODE;
30
31
33{
34 int zoom;
35 int panh;
36 int panv;
39};
40
41
43{
44public:
45 PANEL_MOUSE_SETTINGS( wxWindow* aParent );
46
48
49 void ResetPanel() override;
50
51protected:
52 bool TransferDataFromWindow() override;
53
54 bool TransferDataToWindow() override;
55
56 void OnScrollRadioButton( wxCommandEvent& event ) override;
57 void onMouseDefaults( wxCommandEvent& event ) override;
58 void onTrackpadDefaults( wxCommandEvent& event ) override;
59
60private:
61 void applySettingsToPanel( const COMMON_SETTINGS& aSettings );
62
64
66
68
69 bool isScrollModSetValid( const SCROLL_MOD_SET& aSet );
70
71private:
74};
75
76
77#endif
PANEL_MOUSE_SETTINGS_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxTAB_TRAVERSAL, const wxString &name=wxEmptyString)
void onMouseDefaults(wxCommandEvent &event) override
bool TransferDataFromWindow() override
void ResetPanel() override
Reset the contents of this panel.
void applySettingsToPanel(const COMMON_SETTINGS &aSettings)
TOUCHPAD_MODE getTouchpadMode() const
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(wxWindow *aParent)
TOUCHPAD_MODE