From: <ste...@us...> - 2015-03-15 21:53:31
|
Revision: 3150 http://sourceforge.net/p/stella/code/3150 Author: stephena Date: 2015-03-15 21:53:28 +0000 (Sun, 15 Mar 2015) Log Message: ----------- Snapshots now work in PAUSE mode. Modified Paths: -------------- trunk/Changes.txt trunk/src/emucore/EventHandler.cxx Modified: trunk/Changes.txt =================================================================== --- trunk/Changes.txt 2015-03-15 17:58:16 UTC (rev 3149) +++ trunk/Changes.txt 2015-03-15 21:53:28 UTC (rev 3150) @@ -32,6 +32,8 @@ * Fixed bug when running ROMs using AtariVox controllers; the app would crash upon exiting the ROM. + * Snapshot functionality now works while the emulation is paused. + * Certain textfields in the UI now have filtering enabled, preventing insertion of illegal characters. This will be extended throughout the code in future releases. Modified: trunk/src/emucore/EventHandler.cxx =================================================================== --- trunk/src/emucore/EventHandler.cxx 2015-03-15 17:58:16 UTC (rev 3149) +++ trunk/src/emucore/EventHandler.cxx 2015-03-15 21:53:28 UTC (rev 3150) @@ -551,10 +551,20 @@ return; // Otherwise, let the event handler deal with it - if(myState == S_EMULATE) - handleEvent(myKeyTable[key][kEmulationMode], state); - else if(myOverlay != nullptr) - myOverlay->handleKeyEvent(key, mod, state); + switch(myState) + { + case S_EMULATE: + handleEvent(myKeyTable[key][kEmulationMode], state); + break; + case S_PAUSE: + if(myKeyTable[key][kEmulationMode] == Event::TakeSnapshot) + handleEvent(myKeyTable[key][kEmulationMode], state); + break; + default: + if(myOverlay != nullptr) + myOverlay->handleKeyEvent(key, mod, state); + break; + } } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -812,10 +822,10 @@ { switch(e) { -#if 0 case EVENT_WINDOW_EXPOSED: - myOSystem.frameBuffer().refresh(); + myOSystem.frameBuffer().update(); break; +#if 0 case EVENT_WINDOW_MINIMIZED: if(myState == S_EMULATE) enterMenuMode(S_MENU); break; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |