KiCad PCB EDA Suite
Loading...
Searching...
No Matches
cvpcb_fpviewer_selection_tool.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 The KiCad Developers, see AUTHORS.txt for contributors.
5 *
6 * This program is free software: you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License as published by the
8 * Free Software Foundation, either version 3 of the License, or (at your
9 * option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful, but
12 * WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License along
17 * with this program. If not, see <http://www.gnu.org/licenses/>.
18 */
19
20#ifndef CVPCB_FOOTPRINT_VIEWER_SELECTION_TOOL_H_
21#define CVPCB_FOOTPRINT_VIEWER_SELECTION_TOOL_H_
22
24
25#include <tool/action_menu.h>
26#include <tool/selection.h>
28#include <tool/tool_menu.h>
29
30
35{
36public:
39
41 bool Init() override;
42
44 void Reset( RESET_REASON aReason ) override;
45
49 int Main( const TOOL_EVENT& aEvent );
50
55 {
56 return m_selection;
57 }
58
60
66 int UpdateMenu( const TOOL_EVENT& aEvent );
67
69 void setTransitions() override;
70
71private:
74
77};
78
79#endif
Selection tool for the footprint viewer in CvPcb.
DISPLAY_FOOTPRINTS_FRAME * m_frame
Pointer to the parent frame.
void setTransitions() override
Set up handlers for various events.
bool Init() override
Init() is called once upon a registration of the tool.
SELECTION m_selection
Current state of selection (not really used: no selection in display footprints frame).
int UpdateMenu(const TOOL_EVENT &aEvent)
Update the menu to reflect the current tool states.
int Main(const TOOL_EVENT &aEvent)
The main loop.
SELECTION & GetSelection()
Selections aren't currently supported in the footprint viewer.
RESET_REASON
Determine the reason of reset for a tool.
Definition: tool_base.h:78
Generic, UI-independent tool event.
Definition: tool_event.h:168
void Reset() override