Skip to content

Commit

Permalink
Fix quick shortcuts in npc dialogs (#45400)
Browse files Browse the repository at this point in the history
* Fix quick shortcuts in npc dialogs

Co-authored-by: Mark Langsdorf <[email protected]>
  • Loading branch information
ZhilkinSerg and mlangsdorf authored Dec 27, 2020
1 parent c02829c commit 6e9125d
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/npctalk.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1482,10 +1482,11 @@ talk_topic dialogue::opt( dialogue_window &d_win, const std::string &npc_name,
response_hotkeys.clear();
input_event evt = ctxt.first_unassigned_hotkey( queue );
for( talk_response &response : responses ) {
response_lines.emplace_back( response.create_option_line( *this, evt ) );
const talk_data &td = response.create_option_line( *this, evt );
response_lines.emplace_back( td );
response_hotkeys.emplace_back( evt );
#if defined(__ANDROID__)
ctxt.register_manual_key( evt.get_first_input() );
ctxt.register_manual_key( evt.get_first_input(), td.text );
#endif
evt = ctxt.next_unassigned_hotkey( queue, evt );
}
Expand Down

0 comments on commit 6e9125d

Please sign in to comment.