all repos — mgba @ 388c94a56930447b575bd1a8776f18357171f194

mGBA Game Boy Advance Emulator

Qt: Fix some cases where key mapping can break if focus is adjusted
Jeffrey Pfau jeffrey@endrift.com
Sun, 04 Jan 2015 22:30:23 -0800
commit

388c94a56930447b575bd1a8776f18357171f194

parent

d99a58a857af32d3b57765ef0cf8b10c69325750

2 files changed, 3 insertions(+), 4 deletions(-)

jump to
M CHANGESCHANGES

@@ -24,6 +24,7 @@ - GBA Video: Fix sprite boundary conditions with mosaic

- Video: Fix FFmpeg crashing when the file extension is wrong - GBA Audio: Fix GB audio channels being too quiet (fixes #159) - Qt: Fix a race condition when a game crashes immediately + - Qt: Fix some cases where key mapping can break if focus is adjusted Misc: - Qt: Disable sync to video by default - GBA: Exit cleanly on FATAL if the port supports it
M src/platform/qt/GBAKeyEditor.cppsrc/platform/qt/GBAKeyEditor.cpp

@@ -151,12 +151,10 @@ painter.drawPicture(0, 0, m_background);

} void GBAKeyEditor::setNext() { + findFocus(); + if (m_currentKey == m_keyOrder.end()) { return; - } - - if (!(*m_currentKey)->hasFocus()) { - m_currentKey = m_keyOrder.end(); } ++m_currentKey;