mirror of
https://github.com/scratchfoundation/bgfx.git
synced 2024-11-28 10:35:43 -05:00
Temporary solution for middle click.
This commit is contained in:
parent
9a23cf7b42
commit
97e9d2db6c
1 changed files with 7 additions and 1 deletions
|
@ -247,7 +247,12 @@ namespace entry
|
|||
{
|
||||
int x, y;
|
||||
getMousePos(&x, &y);
|
||||
m_eventQueue.postMouseEvent(s_defaultWindow, x, y, m_scroll, MouseButton::Left, true);
|
||||
|
||||
// TODO: remove!
|
||||
// Shift + Left Mouse Button acts as middle! This just a temporary solution!
|
||||
// This is becase the average OSX user doesn't have middle mouse click.
|
||||
MouseButton::Enum mb = ([event modifierFlags] & NSShiftKeyMask) ? MouseButton::Middle : MouseButton::Left;
|
||||
m_eventQueue.postMouseEvent(s_defaultWindow, x, y, m_scroll, mb, true);
|
||||
break;
|
||||
}
|
||||
|
||||
|
@ -256,6 +261,7 @@ namespace entry
|
|||
int x, y;
|
||||
getMousePos(&x, &y);
|
||||
m_eventQueue.postMouseEvent(s_defaultWindow, x, y, m_scroll, MouseButton::Left, false);
|
||||
m_eventQueue.postMouseEvent(s_defaultWindow, x, y, m_scroll, MouseButton::Middle, false); // TODO: remove!
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue