#5549 HIGH Update.: In rotated mode, game keys retain original orientation

Zarro Boogs per Child bugtracker at laptop.org
Wed Jun 4 11:25:40 EDT 2008


#5549: In rotated mode, game keys retain original orientation
------------------------------+---------------------------------------------
  Reporter:  blahedo          |       Owner:  erikg           
      Type:  defect           |      Status:  new             
  Priority:  high             |   Milestone:  Update.2 (8.2.0)
 Component:  x window system  |     Version:  Build 650       
Resolution:                   |    Keywords:                  
  Verified:  0                |    Blocking:                  
 Blockedby:                   |  
------------------------------+---------------------------------------------

Comment(by tomeu):

 Only some style nitpicks to mention, from
 http://wiki.laptop.org/go/Python_Style_Guide:

 {{{
 +        actual_keycodes =
 keycodes[self._screen_rotation:self._screen_rotation+4]
 }}}

 Please use spaces around operators.

 {{{
 +        argv = ['xmodmap']
 }}}

 What about s/argv/xmodmap_command?

 {{{
 +        for arg in [('-e', 'keycode %i = %s' % p) for p in code_pairs]:
 +            argv.extend(arg)
 }}}

 Cannot think of anything clearer myself, but would be great if you could
 make it easier to understand for the casual reader.

 {{{
 +            import errno
 }}}

 imports should go at the top of the file

 > If the keys become desyncronized (the call to xrandr fails) the attached
 code will resync them on the next press of the rotation key.

 Can't we just rotate if the call to xrandr succeeds?

 Tried but didn't managed to crash anymore by rotating, so this looks to
 fix that indeed.

 Please get an account in the sugar group in dev.l.o and push it yourself.
 Thanks!

-- 
Ticket URL: <http://dev.laptop.org/ticket/5549#comment:10>
One Laptop Per Child <http://laptop.org/>
OLPC bug tracking system


More information about the Bugs mailing list