fixed for Mac in examples

This commit is contained in:
Erwin Coumans
2015-04-16 15:52:30 -07:00
parent ffb0cab2e7
commit b2ba615874
9 changed files with 46 additions and 13 deletions

View File

@@ -222,6 +222,35 @@ MacOpenGLWindow::~MacOpenGLWindow()
}
bool MacOpenGLWindow::isModifiedKeyPressed(int key)
{
bool isPressed = false;
switch (key)
{
case B3G_ALT:
{
isPressed = ((m_modifierFlags && NSAlternateKeyMask)!=0);
break;
};
case B3G_SHIFT:
{
isPressed = ((m_modifierFlags && NSShiftKeyMask)!=0);
break;
};
case B3G_CONTROL:
{
isPressed = ((m_modifierFlags && NSControlKeyMask )!=0);
break;
};
default:
{
}
};
return isPressed;
}
float MacOpenGLWindow::getTimeInSeconds()
{
return 0.f;