[Scummvm-devel] Simplifying keyboard repeat

Marcus Comstedt marcus at mc.pp.se
Sun Sep 24 15:54:05 CEST 2006


Max Horn <max at quendi.de> writes:

>> So keyboard access is available at least for the DC, some SDL  
>> ports, and the X11 port.
>>
>> The original question on this thread was keyboard repeat.  
>> Implementing keyboard repeat in a platform independent way is what  
>> the GUI code currently tries to do, with mixed success. As David  
>> Given pointed out, this may cause problems on e.g. X11.
>> So, the natural way to handle this is to use the native keyboard  
>> repeat when available, and to emulate it otherwise. To this end, we  
>> could either add a kFeatureKeyboardRepeat flag. Or, we could  
>> *require* backends to implement/emulate keyboard repeat, but  
>> provide the code required for that. Maybe it would even be possible  
>> to add the code require for that directly into OSystem, thus  
>> letting porters implement this with a minimal amount of work.
>>
>> The latter approach has the nice benefit that it would require the  
>> least changes to client code. With the former, we'd have to change  
>> all event loops to use some kind of new encapsulation API.
>
>
>
> I still would do it that way. But let's see whether there are any  
> objections.


I agree with all this.  Oops, that wasn't an objection...  :-)


  // Marcus






More information about the Scummvm-devel mailing list