MCPcopy Create free account
hub / github.com/deathkiller/jazz2-native / OnBackInvoked

Method OnBackInvoked

Sources/Main.cpp:529–539  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

527}
528
529void GameEventHandler::OnBackInvoked()
530{
531 if (_currentHandler != nullptr && _backInvokedTimeLeft <= 0) {
532 // The back button needs to be pressed for at least 2 frames
533 _backInvokedTimeLeft = 2;
534
535 KeyboardEvent event{};
536 event.sym = Keys::Back;
537 _currentHandler->OnKeyPressed(event);
538 }
539}
540
541void GameEventHandler::OnKeyPressed(const KeyboardEvent& event)
542{

Callers

nothing calls this directly

Calls 1

OnKeyPressedMethod · 0.45

Tested by

no test coverage detected