Eliot Miranda uploaded a new version of PackageInfo-Base to project The Trunk:
http://source.squeak.org/trunk/PackageInfo-Base-eem.58.mcz
==================== Summary ====================
Name: PackageInfo-Base-eem.58
Author: eem
Time: 31 March 2012, 11:18:05.586 am
UUID: cf7c7997-bb45-4000-afaa-33bf1666ed82
Ancestors: PackageInfo-Base-bf.57
Move generally useful parts of MethodReference into base
System.
=============== Diff against PackageInfo-Base-bf.57 ===============
Item was removed:
- ----- Method: MethodReference>>sourceCode (in category '*packageinfo-base') -----
- sourceCode
- ^ self actualClass sourceCodeAt: methodSymbol!
Eliot Miranda uploaded a new version of MonticelloConfigurations to project The Trunk:
http://source.squeak.org/trunk/MonticelloConfigurations-eem.102.mcz
==================== Summary ====================
Name: MonticelloConfigurations-eem.102
Author: eem
Time: 31 March 2012, 11:09:54.154 am
UUID: 86b77a9c-2aa7-4be4-a7b3-e7b9e3d4e8cb
Ancestors: MonticelloConfigurations-bf.101
Add some help text to the MCConfigurationsBrowser cuz I
always forget hot to create the current configuration.
=============== Diff against MonticelloConfigurations-bf.101 ===============
Item was changed:
----- Method: MCConfigurationBrowser>>description (in category 'description') -----
description
+ self selectedDependency ifNotNil:
+ [:dep |
+ ^ ('Package: ', dep package name, String cr, dep versionInfo summary) asText].
+ self selectedRepository ifNotNil:
+ [:repo |
+ ^repo creationTemplate
+ ifNotNil: [repo creationTemplate asText]
+ ifNil: [repo asCreationTemplate asText addAttribute: TextColor red]].
+ ^'A configuration is a set of particular versions of packages. These can be used to manage multiple dependencies amongst packages when an update requires changes to multiple packages. One stores the current configuration and then modifies the various packages needing modification.\\To create a new configuration first load the most up-to-date configuration in your repository (e.g. http://source.squeak.org/trunk), open that repository in the Monticello browser, scroll down to the "update" package, select the first entry in the list on the right hand side and click Browse, which will open the configuration in a new MCConfigurationBrowser. Then in the new MCConfigurationBrowser click Update, and choose "update from image" from the pop-up menu. Click Store to save back to the repository.' withCRs!
- self selectedDependency ifNotNil: [:dep | ^ ('Package: ', dep package name, String cr,
- dep versionInfo summary) asText].
- self selectedRepository ifNotNil: [:repo | ^repo creationTemplate
- ifNotNil: [repo creationTemplate asText]
- ifNil: [repo asCreationTemplate asText addAttribute: TextColor red]].
- ^ ''
- !
Nicolas Cellier uploaded a new version of GetText to project The Trunk:
http://source.squeak.org/trunk/GetText-nice.23.mcz
==================== Summary ====================
Name: GetText-nice.23
Author: nice
Time: 31 March 2012, 3:01:23.958 pm
UUID: 45328fae-3176-4dab-b10f-f008856d3d8b
Ancestors: GetText-edc.22
Remove 2 underscore assignment.
They were not detected automatically because not separated by space.
Apply this minimal formatting rule : indent the method body.
Whithout this, reading code really hurts my feeling.
=============== Diff against GetText-edc.22 ===============
Item was changed:
----- Method: MOFile>>load1:localeID: (in category 'experimental') -----
load1: aFileName localeID: id
"CASE1:
all of strings are loaded.
translation strings are converted to Squeak format on load time.
original-string/index pairs are registerd to Dictionary on load time.
hash search can't be used"
| strm originalTable translatedTable |
localeID := id.
+ strm := FileStream readOnlyFileNamed: aFileName.
- strm_ FileStream readOnlyFileNamed: aFileName.
fileName := aFileName.
[
self loadHeader: strm.
originalTable := self loadStringPointers: strm
offset: originalTableOffset.
originalStrings := self loadStrings: strm
pointers: originalTable.
translatedTable := self loadStringPointers: strm
offset: translatedTableOffset.
translatedStrings := self loadStrings: strm
pointers: translatedTable
encoding: 'utf8'
languageEnvironment: (Locale localeID: localeID) languageEnvironment .
translations := Dictionary new.
1 to: nStrings do: [:index |
| key |
key := originalStrings at: index.
translations at: key put: index.
].
originalTable := nil.
] ensure: [strm close].!
Item was changed:
----- Method: MOFile>>load4:localeID: (in category 'experimental') -----
load4: aFileName localeID: id
"CASE4:
all of strings are loaded.
loading and conversion of translation strings to Squeak format is executed on initialization time.
only hash search can be used"
| strm originalTable translatedTable |
localeID := id.
+ strm := FileStream readOnlyFileNamed: aFileName.
- strm_ FileStream readOnlyFileNamed: aFileName.
fileName := aFileName.
[
self loadHeader: strm.
self loadHashTable: strm.
originalTable := self loadStringPointers: strm
offset: originalTableOffset.
originalStrings := self loadStrings: strm
pointers: originalTable.
translatedTable := self loadStringPointers: strm
offset: translatedTableOffset.
translatedStrings := self loadStrings: strm
pointers: translatedTable
encoding: 'utf-8'
languageEnvironment: (Locale localeID: localeID) languageEnvironment .
] ensure: [strm close].!
Item was changed:
----- Method: MOFile>>load:localeID: (in category 'public') -----
load: aFileName localeID: id
"all of original/translated strings are loaded.
but conversion of translation string (in utf-8 bytestring) to Squeak format will be defered.
original-string/index pairs are registerd to Dictionary on load time.
hash search can't be used"
| strm originalTable translatedTable |
localeID := id.
+ strm := FileStream readOnlyFileNamed: aFileName.
- strm_ FileStream readOnlyFileNamed: aFileName.
fileName := aFileName.
[
self loadHeader: strm.
originalTable := self loadStringPointers: strm
offset: originalTableOffset.
originalStrings := self loadStrings: strm
pointers: originalTable.
translatedTable := self loadStringPointers: strm
offset: translatedTableOffset.
translatedStrings := self loadStrings: strm
pointers: translatedTable.
translations := Dictionary new: nStrings * 2. "make too enough room to avoid #grow"
1 to: nStrings do: [:index |
| key |
key := originalStrings at: index.
translations at: key put: index.
].
originalStrings := nil.
] ensure: [strm close].!
Item was changed:
----- Method: TextDomainManager class>>allKnownDomains (in category 'accessing') -----
allKnownDomains
+ "Every package has it's own text domain now so it's not necessary to keep a registry of all domains, we can simply return all the packages in the image.
+ PROBLEM: If a package doesn't contain translations, it won't have a mo file but the GetTextTranslator will try to load it anyway. This happens when we switch languages. So far I tested it briefly and it seems to work..."
+ ^PackageOrganizer default packageNames , {'Etoys-Tiles'}!
- "Every package has it's own text domain now so it's not necessary to keep a registry of all domains, we can simply return all the packages in the image.
- PROBLEM: If a package doesn't contain translations, it won't have a mo file but the GetTextTranslator will try to load it anyway. This happens when we switch languages. So far I tested it briefly and it seems to work..."
- ^PackageOrganizer default packageNames , {'Etoys-Tiles'}!
Item was changed:
----- Method: TextDomainManager class>>allMethodsWithTranslations (in category 'accessing') -----
allMethodsWithTranslations
+ "Look for #translated calls"
+ | methodsWithTranslations |
+ methodsWithTranslations := TranslatedReceiverFinder new stringReceiversWithContext: #translated.
+ methodsWithTranslations := methodsWithTranslations ,
+ (TranslatedReceiverFinder new stringReceiversWithContext: #translatedNoop).
- "Look for #translated calls"
- | methodsWithTranslations |
- methodsWithTranslations := TranslatedReceiverFinder new stringReceiversWithContext: #translated.
- methodsWithTranslations := methodsWithTranslations, (TranslatedReceiverFinder new
- stringReceiversWithContext: #translatedNoop).
+ methodsWithTranslations := methodsWithTranslations collect: [:each | each key compiledMethod].
- methodsWithTranslations := methodsWithTranslations collect: [:each | each key compiledMethod].
+ "Look for Etoys tiles and vocabularies"
+ methodsWithTranslations := methodsWithTranslations , (EToyVocabulary allPhrasesWithContextToTranslate collect: [:r |
+ (MethodReference new setStandardClass: r second methodSymbol: r third) compiledMethod]).
- "Look for Etoys tiles and vocabularies"
- methodsWithTranslations := methodsWithTranslations, (EToyVocabulary allPhrasesWithContextToTranslate collect: [:r |
- (MethodReference new setStandardClass: r second methodSymbol: r third) compiledMethod.
- ]).
+ ^methodsWithTranslations!
- ^methodsWithTranslations!
Item was changed:
----- Method: TextDomainManager class>>defaultDomain (in category 'accessing') -----
defaultDomain
+ "I'm not sure we still need a default domain, AFAIK the default domain will only be used when no domain is found. In that case, wouldn't it be better to just look for a translation in all domains?"
- "I'm not sure we still need a default domain, AFAIK the default domain will only be used when no domain is found. In that case, wouldn't it be better to just look for a translation in all domains?"
^defaultDomain!
Item was changed:
----- Method: TextDomainManager class>>domainForClass: (in category 'accessing') -----
domainForClass: aClass
+ ^'etoys'!
- ^'etoys'!
Item was changed:
----- Method: TextDomainManager class>>domainForPackage: (in category 'accessing') -----
domainForPackage: aPackageInfo
+ "Package names and text domains are synonyms now"
- "Package names and text domains are synonyms now"
^aPackageInfo name!
Item was changed:
----- Method: TextDomainManager class>>textDomainProperty (in category 'private') -----
textDomainProperty
+ ^#textDomain!
- ^#textDomain!
Item was changed:
----- Method: TextDomainManager class>>updateDomainOfAllMethodsWithTranslations (in category 'private') -----
updateDomainOfAllMethodsWithTranslations
+ self allMethodsWithTranslations do: [:each |
+ self updateDomainOfMethod: each]!
- self allMethodsWithTranslations do: [:each|
- self updateDomainOfMethod: each
- ]!
Nicolas Cellier uploaded a new version of Collections to project The Trunk:
http://source.squeak.org/trunk/Collections-nice.470.mcz
==================== Summary ====================
Name: Collections-nice.470
Author: nice
Time: 31 March 2012, 2:34:33.567 pm
UUID: 1612b1dd-7b3c-43fa-81d2-46da0eb098eb
Ancestors: Collections-dtl.469
Republish without the #translated* messages which have been moved in GetText
=============== Diff against Collections-dtl.469 ===============
Item was removed:
- ----- Method: String>>translated (in category 'translating') -----
- translated
- "answer the receiver translated to the default language"
- ^ NaturalLanguageTranslator current translate: self!
Item was removed:
- ----- Method: String>>translatedIfCorresponds (in category 'translating') -----
- translatedIfCorresponds
- "answer the receiver translated to the default language only if
- the receiver begins and ends with an underscore (_)"
- ^ ('_*_' match: self)
- ifTrue: [(self copyFrom: 2 to: self size - 1) translated]
- ifFalse: [self]!
Item was removed:
- ----- Method: String>>translatedTo: (in category 'translating') -----
- translatedTo: localeID
- "answer the receiver translated to the given locale id"
- ^ localeID translator translate: self!
Edgar J. De Cleene uploaded a new version of GetText to project The Trunk:
http://source.squeak.org/trunk/GetText-edc.22.mcz
==================== Summary ====================
Name: GetText-edc.22
Author: edc
Time: 31 March 2012, 7:21:02.951 am
UUID: 1f0d26ae-cff4-4a01-adb1-6c9773731cda
Ancestors: GetText-edc.21
Revert method to right version of Diego Gomez Deck
=============== Diff against GetText-edc.21 ===============
Item was changed:
----- Method: String>>translatedIfCorresponds (in category '*gettext') -----
translatedIfCorresponds
"answer the receiver translated to the default language only if
+ the receiver begins and ends with an underscore (_)"
+ ^ ('_*_' match: self)
- the receiver begins and ends with an underscore (:=)"
- ^ (':=*:=' match: self)
ifTrue: [(self copyFrom: 2 to: self size - 1) translated]
ifFalse: [self]!
Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours:
http://lists.squeakfoundation.org/pipermail/packages/2012-March/005252.html
Name: System-dtl.476
Ancestors: System-edc.475
Nil out some unreferenced slots in the special objects array. Slots 32, 33 and 34 were originally used to hold instances of Float, LargePositiveInteger and Point that could be used as prototypes for fast initialization of these objects. This usage is no longer required in any current VM, so the slots in the special objects array are set to nil and marked as available for future use.
=============================================
http://lists.squeakfoundation.org/pipermail/packages/2012-March/005253.html
Name: Morphic-cmm.606
Ancestors: Morphic-laza.605
Pick up halo to behave the same as a red-button grab.
=============================================
http://lists.squeakfoundation.org/pipermail/packages/2012-March/005254.html
Name: Morphic-cmm.614
Ancestors: Morphic-eem.613, Morphic-cmm.606
- Merged cmm.606.
- Separate UI from domain function so exporting Morphs as graphics can be done programmatically.
=============================================
http://lists.squeakfoundation.org/pipermail/packages/2012-March/005255.html
Name: System-ul.477
Ancestors: System-dtl.476
- restored the original behavior of SystemNavigation >> #allCallsOn:from:, so it returns calls in subclasses too
- temporarily restored NaturalLanguageTranslator class >> #translationSuffix so FileList can be used again
=============================================
http://lists.squeakfoundation.org/pipermail/packages/2012-March/005256.html
Name: Tests-ul.150
Ancestors: Tests-bp.149
- fix: FileDirectoryTest >> #testDirectoryNicknames should use FileDirectory slash instead of '/'
=============================================