60 m_frame = getEditFrame<EDA_DRAW_FRAME>();
66 ctxMenu.AddSeparator( 1 );
80 std::string tool = *aEvent.
Parameter<std::string*>();
100 if( evt->IsCancelInteractive() || evt->IsActivate() )
106 (*m_cancelHandler)();
108 catch( std::exception& )
115 if( evt->IsActivate() )
121 evt->SetPassEvent(
false );
130 bool getNext =
false;
138 getNext = (*m_clickHandler)( *m_picked );
140 catch( std::exception& )
156 else if( evt->IsMotion() )
162 (*m_motionHandler)( cursorPos );
164 catch( std::exception& )
188 (*m_finalizeHandler)( finalize_state );
190 catch( std::exception& )
static bool ShowAlways(const SELECTION &aSelection)
The default condition function (always returns true).
void AddStandardSubMenus(TOOL_MENU &aMenu)
Construct a "basic" menu for a tool, containing only items that apply to all tools (e....
virtual EDA_DRAW_PANEL_GAL * GetCanvas() const
Return a pointer to GAL-based canvas of given EDA draw frame.
static TOOL_ACTION cancelInteractive
void SetCurrentCursor(KICURSOR cursor)
Set the current cursor shape for this panel.
static TOOL_ACTION pickerTool
bool IsGridVisible() const
virtual void CaptureCursor(bool aEnabled)
Force the cursor to stay within the drawing panel area.
An interface for classes handling user events controlling the view behavior such as zooming,...
virtual void ForceCursorPosition(bool aEnabled, const VECTOR2D &aPosition=VECTOR2D(0, 0))
Place the cursor immediately at a given point.
virtual void SetAutoPan(bool aEnabled)
Turn on/off auto panning (this feature is used when there is a tool active (eg.
VECTOR2D GetCursorPosition() const
Return the current cursor position in world coordinates.