fixed duplicate events (menu + emulation) in debugger

This commit is contained in:
thrust26 2023-08-16 07:28:35 +02:00
parent 58c12ca254
commit 8f0ea1a70b
3 changed files with 95 additions and 78 deletions

View File

@ -4942,7 +4942,7 @@ Ms Pac-Man (Stella extended codes):
<tr><td>UASW </td><td>8K UA Ltd. (swapped banks)</td><td>.UASW </td></tr>
<tr><td>WD </td><td>Wickstead Design (Pink Panther) </td><td>.WD </td></tr>
<tr><td>WDSW </td><td>Wickstead Design (Pink Panther) (bad)</td><td>.WDSW </td></tr>
<tr><td>X07 &#185;</td><td>64K AtariAge </td><td>.X07 </td></tr>
<tr><td>X07</td><td>64K AtariAge </td><td>.X07 </td></tr>
</table></td>
</tr>

View File

@ -137,9 +137,12 @@ void DebuggerDialog::handleKeyDown(StellaKey key, StellaMod mod, bool repeated)
}
}
// Do not handle emulation events which have the same mapping as menu events
if(instance().eventHandler().eventForKey(EventMode::kMenuMode, key, mod) == Event::NoType)
{
// handle emulation keys second (can be remapped)
const Event::Type event = instance().eventHandler().eventForKey(EventMode::kEmulationMode, key, mod);
switch (event)
switch(event)
{
case Event::ExitMode:
// make consistent, exit debugger on key UP
@ -168,7 +171,7 @@ void DebuggerDialog::handleKeyDown(StellaKey key, StellaMod mod, bool repeated)
case Event::SaveState:
case Event::SaveAllStates:
case Event::PreviousState :
case Event::PreviousState:
case Event::NextState:
case Event::LoadState:
case Event::LoadAllStates:
@ -220,7 +223,7 @@ void DebuggerDialog::handleKeyDown(StellaKey key, StellaMod mod, bool repeated)
default:
break;
}
}
Dialog::handleKeyDown(key, mod);
}

View File

@ -797,7 +797,9 @@
<ClCompile Include="..\..\debugger\gui\Cart0840Widget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\gui\Cart0FA0Widget.cxx" />
<ClCompile Include="..\..\debugger\gui\Cart0FA0Widget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\gui\Cart2KWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
@ -831,7 +833,9 @@
<ClCompile Include="..\..\debugger\gui\CartBFWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\gui\CartBUSInfoWidget.cxx" />
<ClCompile Include="..\..\debugger\gui\CartBUSInfoWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\gui\CartBUSWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
@ -868,7 +872,9 @@
<ClCompile Include="..\..\debugger\gui\CartE0Widget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\gui\CartE7Widget.cxx" />
<ClCompile Include="..\..\debugger\gui\CartE7Widget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\gui\CartEFSCWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
@ -911,14 +917,18 @@
<ClCompile Include="..\..\debugger\gui\CartFEWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\gui\CartGLWidget.cxx" />
<ClCompile Include="..\..\debugger\gui\CartGLWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\gui\CartMDMWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\gui\CartRamWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\gui\Cart03E0Widget.cxx" />
<ClCompile Include="..\..\debugger\gui\Cart03E0Widget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\gui\CartTVBoyWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
@ -949,7 +959,9 @@
<ClCompile Include="..\..\debugger\gui\GenesisWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\gui\Joy2BPlusWidget.cxx" />
<ClCompile Include="..\..\debugger\gui\Joy2BPlusWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\gui\JoystickWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
@ -977,7 +989,9 @@
<ClCompile Include="..\..\debugger\gui\TrakBallWidget.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\debugger\TimerMap.cxx" />
<ClCompile Include="..\..\debugger\TimerMap.cxx">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug-NoDebugger|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\..\emucore\Bankswitch.cxx" />
<ClCompile Include="..\..\emucore\Cart03E0.cxx" />
<ClCompile Include="..\..\emucore\Cart3EPlus.cxx" />