Status: Accepted
Owner:
[hidden email]
Labels: Milestone-1.3 Type-Squeak
New issue 3664 by
[hidden email]: MacUnicodeInputInterpreter use
utf32 keycode unconditionally
http://code.google.com/p/pharo/issues/detail?id=3664Name: Multilingual-bf.136
Author: bf
Time: 31 January 2011, 5:03:34.511 pm
UUID: c2e685e7-a73c-44b6-93b8-1bf6319972eb
Ancestors: Multilingual-ul.135
- make MacUnicodeInputInterpreter use utf32 keycode unconditionally, since
VMs older than 4.x are not supported anymore anyway.
=============== Diff against Multilingual-ul.135 ===============
Item was removed:
- ----- Method: MacUnicodeInputInterpreter>>initialize (in
category 'initialization') -----
- initialize
- | satisfiesVersion |
- satisfiesVersion := self
- majorMinorBuildFrom: SmalltalkImage current
vmVersion
- satisfies: [:major :minor :build |
- major >= 4 or: [
- major >= 3 and: [minor >= 8 and:
[build >= 7]]]].
- satisfiesVersion
- ifTrue: [keyValueIndex := 6]
- ifFalse: [keyValueIndex := 3]!
Item was removed:
- ----- Method: MacUnicodeInputInterpreter>>keyValueIndex (in
category 'accessing') -----
- keyValueIndex
- ^ keyValueIndex!
Item was removed:
- ----- Method: MacUnicodeInputInterpreter>>majorMinorBuildFrom:satisfies:
(in category 'version check') -----
- majorMinorBuildFrom: aString satisfies: aBlock
- | v |
- v := aString
- ifNil: [^ false].
- v := ((v copyAfter: $])
- findTokens: $ ) last findTokens: $..
- v size = 3
- ifFalse: [^ false].
- v := v
- collect: [:s | s initialIntegerOrNil
- ifNil: [^ false]].
- ^ aBlock valueWithArguments: v asArray!
Item was changed:
----- Method: MacUnicodeInputInterpreter>>nextCharFrom:firstEvt: (in
category 'keyboard') -----
nextCharFrom: sensor firstEvt: evtBuf
| keyValue mark |
+ keyValue := evtBuf at: 6.
- keyValue := evtBuf at: self keyValueIndex.
mark := self japaneseSpecialMark: keyValue.
mark notNil
ifTrue: [^ mark].
keyValue < 256
ifTrue: [^ (Character value: keyValue) squeakToIso].
"Smalltalk systemLanguage charsetClass charFromUnicode: keyValue."
^ Unicode value: keyValue!