Skip to content

Commit

Permalink
Hearts: Ignore unhandled keydown events
Browse files Browse the repository at this point in the history
This makes Action shortcuts work again. :^)
  • Loading branch information
AtkinsSJ authored and linusg committed Dec 14, 2022
1 parent faf30ed commit 10c4c55
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Userland/Games/Hearts/Game.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -580,8 +580,11 @@ void Game::keydown_event(GUI::KeyEvent& event)
} else if (event.key() == KeyCode::Key_Space) {
if (m_human_can_play && m_state == State::Play)
play_card(m_players[0], pick_first_card_ltr(m_players[0]));
} else if (event.shift() && event.key() == KeyCode::Key_F11)
} else if (event.shift() && event.key() == KeyCode::Key_F11) {
dump_state();
} else {
event.ignore();
}
}

void Game::play_card(Player& player, size_t card_index)
Expand Down

0 comments on commit 10c4c55

Please sign in to comment.