[squeak-dev] The Trunk: Kernel-ar.443.mcz

commits at source.squeak.org commits at source.squeak.org
Sat Apr 17 18:20:51 UTC 2010

Andreas Raab uploaded a new version of Kernel to project The Trunk:

==================== Summary ====================

Name: Kernel-ar.443
Author: ar
Time: 17 April 2010, 11:19:52.132 am
UUID: 36dc17fd-f2de-d54d-b33f-435c2f08d6bb
Ancestors: Kernel-tbn.442

Fix handling of duplicate/swap control and alt keys.

=============== Diff against Kernel-tbn.442 ===============

Item was changed:
  ----- Method: EventSensor>>processEvent: (in category 'private-I/O') -----
  processEvent: evt 
  	"Process a single event. This method is run at high priority."
  	| type |
  	type := evt at: 1.
  	"Tackle mouse events first"
  	type = EventTypeMouse
  		ifTrue: [evt
  				at: 5
  				put: (ButtonDecodeTable at: (evt at: 5)
  							+ 1). 
  				self queueEvent: evt.
  				self processMouseEvent: evt . 
  	"Store the event in the queue if there's any"
  	type = EventTypeKeyboard
  		ifTrue: [ "Check if the event is a user interrupt"
  			((evt at: 4) = 0
  				and: [((evt at: 3)
  						bitOr: (((evt at: 5)
  							bitAnd: 8)
  							bitShift: 8))
  							= interruptKey])
  					ifTrue: ["interrupt key is meta - not reported as event"
  							^ interruptSemaphore signal].
+ 			"Else swap ctrl/alt keys if neeeded.
+ 			Look at the Unicode char first, then ascii."
- 			"Else swap ctrl/alt keys if neeeded.wi"
+ 				at: {evt at: 6. evt at: 5}
+ 				ifPresent: [:a | evt at: 6 put: a first;
+ 						 at: 5 put: a second]. 
+ 			KeyDecodeTable
  				at: {evt at: 3. evt at: 5}
  				ifPresent: [:a | evt at: 3 put: a first;
  						 at: 5 put: a second]. 
  			self queueEvent: evt. 
  			self processKeyboardEvent: evt . 
  			^self ].
  	"Handle all events other than Keyborad or Mouse."
  	self queueEvent: evt.

More information about the Squeak-dev mailing list