Marcel Taeumel uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-mt.1016.mcz
==================== Summary ====================
Name: System-mt.1016
Author: mt
Time: 8 April 2018, 12:04:43.52839 pm
UUID: c790b5f0-2bf7-eb47-ab42-0e1762236535
Ancestors: System-mt.1015
Now that we have cleaned-up the state of SoundService, we can simplify #defaultOrNil again.
=============== Diff against System-mt.1015 ===============
Item was changed:
----- Method: SoundService class>>defaultOrNil (in category 'accessing') -----
defaultOrNil
+ "This app registry returns instances instead of classes."
+
+ ^ super defaultOrNil ifNotNil: [:default | default new]!
-
- ^ super defaultOrNil ifNotNil: [:default |
- default isBehavior ifTrue: [default new] ifFalse: [default]]
- !
Marcel Taeumel uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-mt.1015.mcz
==================== Summary ====================
Name: System-mt.1015
Author: mt
Time: 8 April 2018, 12:01:31.43839 pm
UUID: 42c64965-b457-4c45-962c-85944be8e436
Ancestors: System-mt.1014
Etoys tests could have messed with your SoundService app registry. This commit and script cleans that up.
=============== Diff against System-mt.1014 ===============
Item was changed:
----- Method: SoundService class>>default (in category 'accessing') -----
default
+ "This app registry returns instances instead of classes."
+
-
| cls |
cls := super default.
^ cls new!
Item was added:
+ ----- Method: SoundService class>>default: (in category 'accessing') -----
+ default: aClassOrNil
+ "See #default. This app registry returns instances instead of classes. Yet, make sure to only store classes so that always fresh instances will be returned."
+
+ ^ super default: (aClassOrNil ifNotNil: [:obj |
+ obj isBehavior
+ ifTrue: [obj]
+ ifFalse: [obj class]])!
Item was changed:
+ (PackageInfo named: 'System') postscript: '"Ensure that only classes are stored in the SoundService app registry."
+ SoundService default: SoundService defaultOrNil.'!
- (PackageInfo named: 'System') postscript: '(Smalltalk specialSelectorNames includes: #~~) ifFalse:
- ["Re-create the specialObjectsArray to let the jit optimize #~~. Also add the new primitive error codes if they are not there yet."
- | senders |
- senders := #(#~~ #blockCopy:) gather: [ :selector |
- "Recompile senders blockCopy: too, just in case."
- SystemNavigation default allCallsOn: selector ].
- Smalltalk recreateSpecialObjectsArray.
- VariableNode initialize.
- Decompiler initialize.
- senders
- do: [ :methodReference |
- | class |
- class := methodReference actualClass.
- class recompile: methodReference selector from: class ]
- displayingProgress: ''Recompiling...''].
- "If PrimitiveError is not in the primitiveErrorTable, or if an instance
- of a different class is there, then add it."
- (Smalltalk primitiveErrorTable size < 21
- or: [(Smalltalk primitiveErrorTable at: 21) class ~~ PrimitiveError]) ifTrue:
- [Smalltalk recreateSpecialObjectsArray]'!
Chris Muller uploaded a new version of ToolBuilder-Morphic to project The Trunk:
http://source.squeak.org/trunk/ToolBuilder-Morphic-cmm.212.mcz
==================== Summary ====================
Name: ToolBuilder-Morphic-cmm.212
Author: cmm
Time: 7 April 2018, 7:19:41.653494 pm
UUID: 66f83f51-b978-4030-be9c-fce2ca2491f0
Ancestors: ToolBuilder-Morphic-cmm.211
Fix minor code inelegance.
=============== Diff against ToolBuilder-Morphic-cmm.211 ===============
Item was changed:
----- Method: FileSaverDialog>>selectFilename: (in category 'filename') -----
selectFilename: aText
"The user has entered a potential filename in the text field. Check it against the current pattern; if it is ok we can accept it and then if it is a file in the current list, highlight it. If it would not match the pattern, alert the user."
fileName := aText asString.
^ self selectExistingFilename
ifTrue:
[ self changed: #fileListIndex.
true ]
ifFalse:
[ suffixList size = 1
ifTrue:
[ | suffix |
((suffix := '.' , suffixList anyOne)
compare: (fileName last: suffix size)
+ caseSensitive: FileDirectory default isCaseSensitive) = 2 ifFalse: [ fileName := fileName , suffix ].
- caseSensitive: FileDirectory default isCaseSensitive) = 2 ifFalse: [ fileName := fileName , '.' , suffixList first ].
true ]
ifFalse:
[ suffixList
at:
(UIManager default
chooseFrom: suffixList
title: 'Please choose the type of file to save.')
ifPresent:
[ : choice | fileName := fileName , '.' , choice.
true ]
ifAbsent:
[ suffixList isEmpty or:
[ UIManager default inform: 'WARNING: File not saved!! A filename matching one of ' , patternList asArray asString , ' patterns is required.'.
false ] ] ] ]!
Chris Muller uploaded a new version of ToolBuilder-Morphic to project The Trunk:
http://source.squeak.org/trunk/ToolBuilder-Morphic-cmm.211.mcz
==================== Summary ====================
Name: ToolBuilder-Morphic-cmm.211
Author: cmm
Time: 7 April 2018, 7:16:02.444544 pm
UUID: e0ee1d62-8009-4ece-9e9a-8a781b7a8407
Ancestors: ToolBuilder-Morphic-cmm.210
Fix the FileSaverDialog case where the file is named .extension.extension and the user wishes to remove the double-extension. #selectExistingFilename was not enough to filter that case.
=============== Diff against ToolBuilder-Morphic-cmm.210 ===============
Item was changed:
----- Method: FileSaverDialog>>selectFilename: (in category 'filename') -----
selectFilename: aText
"The user has entered a potential filename in the text field. Check it against the current pattern; if it is ok we can accept it and then if it is a file in the current list, highlight it. If it would not match the pattern, alert the user."
fileName := aText asString.
^ self selectExistingFilename
ifTrue:
[ self changed: #fileListIndex.
true ]
ifFalse:
[ suffixList size = 1
ifTrue:
+ [ | suffix |
+ ((suffix := '.' , suffixList anyOne)
+ compare: (fileName last: suffix size)
+ caseSensitive: FileDirectory default isCaseSensitive) = 2 ifFalse: [ fileName := fileName , '.' , suffixList first ].
- [ fileName := fileName , '.' , suffixList first.
true ]
ifFalse:
[ suffixList
at:
(UIManager default
chooseFrom: suffixList
title: 'Please choose the type of file to save.')
ifPresent:
[ : choice | fileName := fileName , '.' , choice.
true ]
ifAbsent:
[ suffixList isEmpty or:
[ UIManager default inform: 'WARNING: File not saved!! A filename matching one of ' , patternList asArray asString , ' patterns is required.'.
false ] ] ] ]!
Chris Muller uploaded a new version of ToolBuilder-Morphic to project The Trunk:
http://source.squeak.org/trunk/ToolBuilder-Morphic-cmm.210.mcz
==================== Summary ====================
Name: ToolBuilder-Morphic-cmm.210
Author: cmm
Time: 7 April 2018, 3:54:49.043193 pm
UUID: 72fd894c-8465-4889-b0af-604220f410c8
Ancestors: ToolBuilder-Morphic-cmm.209
FileSaverDialog support default names with no extension. Allows saving files without an extension.
=============== Diff against ToolBuilder-Morphic-cmm.209 ===============
Item was changed:
----- Method: FileSaverDialog>>selectFilename: (in category 'filename') -----
selectFilename: aText
"The user has entered a potential filename in the text field. Check it against the current pattern; if it is ok we can accept it and then if it is a file in the current list, highlight it. If it would not match the pattern, alert the user."
fileName := aText asString.
^ self selectExistingFilename
ifTrue:
[ self changed: #fileListIndex.
true ]
ifFalse:
[ suffixList size = 1
ifTrue:
[ fileName := fileName , '.' , suffixList first.
true ]
ifFalse:
[ suffixList
at:
(UIManager default
chooseFrom: suffixList
title: 'Please choose the type of file to save.')
ifPresent:
[ : choice | fileName := fileName , '.' , choice.
true ]
ifAbsent:
+ [ suffixList isEmpty or:
+ [ UIManager default inform: 'WARNING: File not saved!! A filename matching one of ' , patternList asArray asString , ' patterns is required.'.
+ false ] ] ] ]!
- [ fileName := nil.
- UIManager default inform: 'WARNING: File not saved!! A filename matching one of ' , patternList asArray asString , ' patterns is required.'.
- false ] ] ]!
Nicolas Cellier uploaded a new version of Files to project The Trunk:
http://source.squeak.org/trunk/Files-nice.180.mcz
==================== Summary ====================
Name: Files-nice.180
Author: nice
Time: 6 April 2018, 11:42:51.959975 pm
UUID: 8c7f5f6d-f3db-4d3e-afd3-e47351332573
Ancestors: Files-tpr.179
Fix typo according to http://bugs.squeak.org/view.php?id=7854
=============== Diff against Files-tpr.179 ===============
Item was changed:
----- Method: FileStream class>>encodeAndDecodeStdioFiles (in category 'stdio') -----
encodeAndDecodeStdioFiles
<preference: 'Encode and decode the contents of stdio files.'
category: 'Files'
+ description: 'If true, then the contents of stdin, stdout and stderr are encoded/decoded using the system default text converter.'
- description: 'It true, then the contents of stdin, stdout and stderr are encoded/decoded using the system default text converter.'
type: #Boolean>
^EncodeAndDecodeStdioFiles ifNil: [ true ]!
Nicolas Cellier uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-nice.1412.mcz
==================== Summary ====================
Name: Morphic-nice.1412
Author: nice
Time: 6 April 2018, 11:39:20.148358 pm
UUID: 9fec9c6d-77db-4708-ab00-15746432945b
Ancestors: Morphic-nice.1411
Fix one typo and one preference description according to http://bugs.squeak.org/view.php?id=7854
=============== Diff against Morphic-nice.1411 ===============
Item was changed:
----- Method: FontImporterTool>>import (in category 'actions') -----
import
| megaSize filenames fonts |
fonts := self currentSelection.
filenames := fonts allFilenames.
megaSize := ((filenames inject: 0 into: [ :sum :fn |
sum + (FileStream readOnlyFileNamed: fn do: [:file | file size])]) / (1024 * 1024)) asFloat.
(UIManager default confirm: (
+ 'About to import {1}{2}.\\This is at least {3} MB of space required in the image.\
- 'About to import {1}{2}.\\This is at least {3} MB of space required int the image.\
Please respect the copyright and embedding restrictions of the font.\
Proceed?'
withCRs format: {
self currentParent
ifNotNil: [:p| p fontname, ' ', self currentSelection fontname]
ifNil: [self currentSelection fontname].
filenames size > 1 ifTrue: [' (', filenames size, ' font files)'] ifFalse: [''].
megaSize printShowingDecimalPlaces: 2}))
ifTrue: [
filenames do: [:filename | | readFonts |
readFonts := TTCFontDescription addFromTTFile: filename.
readFonts isCollection
ifFalse: [TTCFont newTextStyleFromTT: readFonts]
ifTrue: [self importFontFamily: readFonts]]].
self allFonts: nil. "force redraw"
!
Item was changed:
----- Method: PluggableListMorph class>>menuRequestUpdatesSelection (in category 'preferences') -----
menuRequestUpdatesSelection
<preference: 'Menu request updates list/tree selection'
category: #Morphic
+ description: 'When invoking a menu, the action is applied to the current selection in the list. If the mouse cursor it at a different location, however, this preference will update the selection before showing the menu if enabled.'
- description: 'When invoking a menu, this will for the current selection by default. If the mouse cursor it at a different location, however, this preference will update the selection before showing the menu if enabled.'
type: #Boolean>
^ MenuRequestUpdatesSelection ifNil: [ false ]!