Skip to content

Commit

Permalink
Merge pull request gmamaladze#75 from brusdev/patch-mouseupext
Browse files Browse the repository at this point in the history
Fix MouseUpExt event after MouseDownExt handled
  • Loading branch information
gmamaladze authored Feb 24, 2017
2 parents 8517f91 + 30616c8 commit f41e98b
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions MouseKeyHook/Implementation/MouseListener.cs
Original file line number Diff line number Diff line change
Expand Up @@ -119,23 +119,22 @@ protected virtual void ProcessDown(ref MouseEventExtArgs e)

protected virtual void ProcessUp(ref MouseEventExtArgs e)
{
OnUp(e);
OnUpExt(e);
if (e.Handled)
{
return;
}

if (m_SingleDown.Contains(e.Button))
{
OnUp(e);
OnUpExt(e);
if (e.Handled)
{
return;
}
OnClick(e);
m_SingleDown.Remove(e.Button);
}

if (m_DoubleDown.Contains(e.Button))
{
e = e.ToDoubleClickEventArgs();
OnUp(e);
OnUpExt(e);
OnDoubleClick(e);
m_DoubleDown.Remove(e.Button);
}
Expand Down

0 comments on commit f41e98b

Please sign in to comment.