Massage an earlier fix so that mouse-clicks in tools update the highlighting.
This commit is contained in:
parent
44734dc059
commit
a3b855ac6c
|
@ -173,13 +173,13 @@ const std::string TOOL_EVENT_LIST::Format() const
|
||||||
|
|
||||||
bool TOOL_EVENT::IsClick( int aButtonMask ) const
|
bool TOOL_EVENT::IsClick( int aButtonMask ) const
|
||||||
{
|
{
|
||||||
return m_actions == TA_MOUSE_CLICK && ( m_mouseButtons & aButtonMask ) == aButtonMask;
|
return m_actions == TA_MOUSE_CLICK && ( m_mouseButtons & aButtonMask ) == m_mouseButtons;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool TOOL_EVENT::IsDblClick( int aButtonMask ) const
|
bool TOOL_EVENT::IsDblClick( int aButtonMask ) const
|
||||||
{
|
{
|
||||||
return m_actions == TA_MOUSE_DBLCLICK && ( m_mouseButtons & aButtonMask ) == aButtonMask;
|
return m_actions == TA_MOUSE_DBLCLICK && ( m_mouseButtons & aButtonMask ) == m_mouseButtons;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -966,7 +966,7 @@ void TOOL_MANAGER::UpdateUI( const TOOL_EVENT& aEvent )
|
||||||
{
|
{
|
||||||
frame->UpdateStatusBar();
|
frame->UpdateStatusBar();
|
||||||
|
|
||||||
if( !aEvent.IsMouseAction() )
|
if( !aEvent.IsMotion() && !aEvent.IsDrag() )
|
||||||
frame->SyncToolbars();
|
frame->SyncToolbars();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -285,12 +285,12 @@ public:
|
||||||
|
|
||||||
bool IsDrag( int aButtonMask = BUT_ANY ) const
|
bool IsDrag( int aButtonMask = BUT_ANY ) const
|
||||||
{
|
{
|
||||||
return m_actions == TA_MOUSE_DRAG && ( m_mouseButtons & aButtonMask ) == aButtonMask;
|
return m_actions == TA_MOUSE_DRAG && ( m_mouseButtons & aButtonMask ) == m_mouseButtons;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool IsMouseUp( int aButtonMask = BUT_ANY ) const
|
bool IsMouseUp( int aButtonMask = BUT_ANY ) const
|
||||||
{
|
{
|
||||||
return m_actions == TA_MOUSE_UP && ( m_mouseButtons & aButtonMask ) == aButtonMask;
|
return m_actions == TA_MOUSE_UP && ( m_mouseButtons & aButtonMask ) == m_mouseButtons;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool IsMotion() const
|
bool IsMotion() const
|
||||||
|
|
Loading…
Reference in New Issue