dynamic mover
This commit is contained in:
parent
f36d061ba2
commit
f0b1ed2fca
29 changed files with 3078 additions and 432 deletions
|
|
@ -160,6 +160,17 @@ static void OnEvent( const sapp_event* e )
|
|||
s_context.camera.OnEvent( e );
|
||||
}
|
||||
|
||||
// Releases go to the key table even when the UI captures them. Otherwise Ctrl let go
|
||||
// while the Ctrl+O picker is open stays down in the next sample.
|
||||
if ( e->type == SAPP_EVENTTYPE_KEY_UP )
|
||||
{
|
||||
SetKeyDown( e->key_code, false );
|
||||
}
|
||||
else if ( e->type == SAPP_EVENTTYPE_UNFOCUSED )
|
||||
{
|
||||
ClearKeysDown();
|
||||
}
|
||||
|
||||
if ( uiCaptured )
|
||||
{
|
||||
return;
|
||||
|
|
@ -267,10 +278,6 @@ static void OnEvent( const sapp_event* e )
|
|||
}
|
||||
break;
|
||||
|
||||
case SAPP_EVENTTYPE_KEY_UP:
|
||||
SetKeyDown( e->key_code, false );
|
||||
break;
|
||||
|
||||
case SAPP_EVENTTYPE_CHAR:
|
||||
// ? toggles the controls window. Read the typed character so it works
|
||||
// on any layout and a text field can still type a literal ?, since the
|
||||
|
|
|
|||
Loading…
Reference in a new issue