David T. Lewis uploaded a new version of ST80 to project The Trunk:
http://source.squeak.org/trunk/ST80-dtl.93.mcz ==================== Summary ==================== Name: ST80-dtl.93 Author: dtl Time: 6 February 2010, 5:36:47.988 pm UUID: 5ad2aad3-f5e9-4ec6-9b4b-83a12845bd1f Ancestors: ST80-dtl.92 Move PluggableFileListView from package Morphic-FileList to ST80-Views Move ModalSystemWindowView from package Morphic-FileList to ST80-Views =============== Diff against ST80-dtl.92 =============== Item was added: + ----- Method: ModalSystemWindowView>>update: (in category 'model access') ----- + update: aSymbol + aSymbol = #close + ifTrue: [^self controller close]. + ^super update: aSymbol! Item was added: + ----- Method: ModalSystemWindowView>>doModalDialog (in category 'modal dialog') ----- + doModalDialog + + | savedArea | + self resizeInitially. + self resizeTo: + ((self windowBox) + align: self windowBox center + with: Display boundingBox aboveCenter). + savedArea := Form fromDisplay: self windowBox. + self displayEmphasized. + self controller startUp. + self release. + savedArea displayOn: Display at: self windowOrigin. + ! Item was added: + ModalSystemWindowView subclass: #PluggableFileListView + instanceVariableNames: 'acceptButtonView' + classVariableNames: '' + poolDictionaries: '' + category: 'ST80-Views'! + + !PluggableFileListView commentStamp: '<historical>' prior: 0! + I provide aview for PluggableFileList! Item was added: + ----- Method: ModalSystemWindowView>>borderWidth: (in category 'initialize-release') ----- + borderWidth: anObject + + modalBorder := false. + ^super borderWidth: anObject! Item was added: + ----- Method: PluggableFileListView>>label: (in category 'as yet unclassified') ----- + label: aString + + super label: aString. + self noLabel! Item was added: + ----- Method: ModalSystemWindowView>>displayBorder (in category 'displaying') ----- + displayBorder + "Display the receiver's border (using the receiver's borderColor)." + + modalBorder ifFalse: [^super displayBorder]. + + Display + border: self displayBox + widthRectangle: (1@1 corner: 2@2) + rule: Form over + fillColor: Color black. + Display + border: (self displayBox insetBy: (1@1 corner: 2@2)) + widthRectangle: (4@4 corner: 3@3) + rule: Form over + fillColor: (Color r: 16rEA g: 16rEA b: 16rEA). + ! Item was added: + ----- Method: ModalSystemWindowView>>display (in category 'displaying') ----- + display + + super display. + self displayLabelBackground: false. + self displayLabelText. + ! Item was added: + ----- Method: ModalSystemWindowView>>backgroundColor (in category 'label access') ----- + backgroundColor + ^Color lightYellow! Item was added: + ----- Method: PluggableFileListView>>updateAcceptButton (in category 'as yet unclassified') ----- + updateAcceptButton + + self model canAccept + ifTrue: + [acceptButtonView + backgroundColor: Color green; + borderWidth: 3; + controller: acceptButtonView defaultController] + ifFalse: + [acceptButtonView + backgroundColor: Color lightYellow; + borderWidth: 1; + controller: NoController new]. + acceptButtonView display.! Item was added: + ----- Method: PluggableFileListView>>acceptButtonView: (in category 'as yet unclassified') ----- + acceptButtonView: aView + + ^acceptButtonView := aView! Item was added: + ----- Method: ModalSystemWindowView>>initialize (in category 'initialize-release') ----- + initialize + "Refer to the comment in View|initialize." + super initialize. + self borderWidth: 5. + self noLabel. + modalBorder := true.! Item was added: + ----- Method: ModalSystemWindowView>>displayLabelBoxes (in category 'displaying') ----- + displayLabelBoxes + "Modal dialogs don't have closeBox or growBox." + ! Item was added: + ----- Method: PluggableFileListView>>update: (in category 'as yet unclassified') ----- + update: aSymbol + (aSymbol = #volumeListIndex or: [aSymbol = #fileListIndex]) + ifTrue: [self updateAcceptButton]. + ^super update: aSymbol! Item was added: + ----- Method: ModalSystemWindowView>>defaultControllerClass (in category 'controller access') ----- + defaultControllerClass + + ^Smalltalk at: #ModalController! Item was added: + StandardSystemView subclass: #ModalSystemWindowView + instanceVariableNames: 'modalBorder' + classVariableNames: '' + poolDictionaries: '' + category: 'ST80-Views'! + + !ModalSystemWindowView commentStamp: '<historical>' prior: 0! + I am a view for a Modal System Window. I vary from StandardSystemView, of which I am a subclass in a few ways: + + (1) I use ModalController as my default controller; + (2) When asked to update with the symbol #close, I direct the controller to close; + (3) I display a slightly different title bar with no control boxes.! |
Free forum by Nabble | Edit this page |