--- a/MenuEditor.st Thu Feb 26 17:36:35 1998 +0100
+++ b/MenuEditor.st Thu Feb 26 20:10:50 1998 +0100
@@ -240,7 +240,6 @@
'Selector returning an image.'
)
-
! !
!MenuEditor class methodsFor:'interface specs'!
@@ -976,7 +975,7 @@
#'name:' 'infoBarSubSpec'
#'layout:' #(#LayoutFrame 0 0.0 -24 1 0 1.0 0 1.0)
#'majorKey:' #ToolApplicationModel
- #'minorKey:' #windowSpecForInfoBarWithClock
+ #'minorKey:' #windowSpecForInfoBar
)
)
)
@@ -1004,103 +1003,103 @@
#(
#(#MenuItem
- #'label:' 'About'
- #'activeHelpKey:' #about
- #'accessCharacterPosition:' 1
- #'labelImage:' #(#ResourceRetriever nil #menuIcon)
- #'submenuChannel:' #menuAbout
+ #label: 'About'
+ #activeHelpKey: #about
+ #accessCharacterPosition: 1
+ #labelImage: #(#ResourceRetriever nil #menuIcon)
+ #submenuChannel: #menuAbout
)
#(#MenuItem
- #'label:' 'File'
- #'translateLabel:' true
- #'activeHelpKey:' #file
- #'submenu:'
+ #label: 'File'
+ #translateLabel: true
+ #activeHelpKey: #file
+ #submenu:
#(#Menu
#(
#(#MenuItem
- #'label:' 'New'
- #'value:' #doNew
- #'activeHelpKey:' #fileNew
+ #label: 'New'
+ #value: #doNew
+ #activeHelpKey: #fileNew
)
#(#MenuItem
- #'label:' '-'
+ #label: '-'
)
#(#MenuItem
- #'label:' 'Load...'
- #'translateLabel:' true
- #'value:' #doLoad
- #'activeHelpKey:' #fileLoad
- #'enabled:' #isStandAlone
+ #label: 'Load...'
+ #translateLabel: true
+ #value: #doLoad
+ #activeHelpKey: #fileLoad
+ #enabled: #isStandAlone
)
#(#MenuItem
- #'label:' '-'
+ #label: '-'
)
#(#MenuItem
- #'label:' 'Save'
- #'value:' #doSave
- #'activeHelpKey:' #fileSave
+ #label: 'Save'
+ #value: #doSave
+ #activeHelpKey: #fileSave
)
#(#MenuItem
- #'label:' 'Save As...'
- #'value:' #doSaveAs
- #'activeHelpKey:' #fileSaveAs
+ #label: 'Save As...'
+ #value: #doSaveAs
+ #activeHelpKey: #fileSaveAs
)
#(#MenuItem
- #'label:' '-'
+ #label: '-'
)
#(#MenuItem
- #'label:' 'Pick A Menu...'
- #'value:' #doPickAMenu
- #'activeHelpKey:' #filePickAMenu
- #'enabled:' #isStandAlone
+ #label: 'Pick A Menu...'
+ #value: #doPickAMenu
+ #activeHelpKey: #filePickAMenu
+ #enabled: #isStandAlone
)
#(#MenuItem
- #'label:' '-'
+ #label: '-'
)
#(#MenuItem
- #'label:' 'Browse Class'
- #'value:' #doBrowseClass
- #'activeHelpKey:' #fileBrowseClass
+ #label: 'Browse Class'
+ #value: #doBrowseClass
+ #activeHelpKey: #fileBrowseClass
)
#(#MenuItem
- #'label:' '-'
+ #label: '-'
)
#(#MenuItem
- #'label:' 'Exit'
- #'translateLabel:' true
- #'value:' #closeRequest
- #'activeHelpKey:' #fileExit
+ #label: 'Exit'
+ #translateLabel: true
+ #value: #closeRequest
+ #activeHelpKey: #fileExit
)
) nil
nil
)
)
#(#MenuItem
- #'label:' 'Edit'
- #'activeHelpKey:' #edit
- #'submenuChannel:' #menuEdit
+ #label: 'Edit'
+ #activeHelpKey: #edit
+ #submenuChannel: #menuEdit
)
#(#MenuItem
- #'label:' 'Add'
- #'activeHelpKey:' #add
- #'submenuChannel:' #menuAdd
+ #label: 'Add'
+ #activeHelpKey: #add
+ #submenuChannel: #menuAdd
)
#(#MenuItem
- #'label:' 'Test'
- #'activeHelpKey:' #test
- #'submenuChannel:' #submenuTest
+ #label: 'Test'
+ #activeHelpKey: #test
+ #submenuChannel: #submenuTest
)
#(#MenuItem
- #'label:' 'History'
- #'activeHelpKey:' #history
- #'submenuChannel:' #menuHistory
+ #label: 'History'
+ #activeHelpKey: #history
+ #submenuChannel: #menuHistory
)
#(#MenuItem
- #'label:' 'Help'
- #'startGroup:' #right
- #'activeHelpKey:' #help
- #'submenuChannel:' #menuHelp
+ #label: 'Help'
+ #startGroup: #right
+ #activeHelpKey: #help
+ #submenuChannel: #menuHelp
)
) nil
nil
@@ -1223,6 +1222,13 @@
#shortcutKeyCharacter: #Paste
)
#(#MenuItem
+ #label: 'Delete'
+ #value: #doDelete
+ #activeHelpKey: #editDelete
+ #enabled: #hasValidSelection
+ #shortcutKeyCharacter: #Delete
+ )
+ #(#MenuItem
#label: '-'
)
#(#MenuItem
@@ -1230,28 +1236,24 @@
#value: #doStepUp
#activeHelpKey: #editMoveUp
#enabled: #valueOfEnableMovingUpOrDown
- #labelImage: #(#ResourceRetriever #ToolApplicationModel #upIcon 'Move Up')
)
#(#MenuItem
#label: 'Move Down'
#value: #doStepDown
#activeHelpKey: #editMoveDown
#enabled: #valueOfEnableMovingUpOrDown
- #labelImage: #(#ResourceRetriever #ToolApplicationModel #downIcon 'Move Down')
)
#(#MenuItem
#label: 'Move In'
#value: #doStepIn
#activeHelpKey: #editMoveIn
#enabled: #valueOfEnableMovingIn
- #labelImage: #(#ResourceRetriever #ToolApplicationModel #downRightIcon 'Move In')
)
#(#MenuItem
#label: 'Move Out'
#value: #doStepOut
#activeHelpKey: #editMoveOut
#enabled: #valueOfEnableMovingOut
- #labelImage: #(#ResourceRetriever #ToolApplicationModel #leftDownIcon 'Move Out')
)
) nil
nil
@@ -1301,6 +1303,41 @@
#label: ''
)
#(#MenuItem
+ #label: 'Cut'
+ #isButton: true
+ #value: #doCut
+ #activeHelpKey: #editCut
+ #enabled: #hasValidSelection
+ #labelImage: #(#ResourceRetriever nil #cutIcon)
+ )
+ #(#MenuItem
+ #label: 'Copy'
+ #isButton: true
+ #value: #doCopy
+ #activeHelpKey: #editCopy
+ #enabled: #hasValidSelection
+ #labelImage: #(#ResourceRetriever nil #copyIcon)
+ )
+ #(#MenuItem
+ #label: 'Paste'
+ #isButton: true
+ #value: #doPaste
+ #activeHelpKey: #editPaste
+ #enabled: #hasAnySingleSelection
+ #labelImage: #(#ResourceRetriever nil #pasteIcon)
+ )
+ #(#MenuItem
+ #label: 'Delete'
+ #isButton: true
+ #value: #doDelete
+ #activeHelpKey: #editDelete
+ #enabled: #hasValidSelection
+ #labelImage: #(#ResourceRetriever nil #deleteIcon)
+ )
+ #(#MenuItem
+ #label: ''
+ )
+ #(#MenuItem
#label: 'Add Item'
#isButton: true
#value: #doCreateItem
@@ -1317,9 +1354,6 @@
#labelImage: #(#ResourceRetriever nil #menuSeparatorImage)
)
#(#MenuItem
- #label: ''
- )
- #(#MenuItem
#label: 'Add Submenu'
#isButton: true
#value: #doCreateMenu
@@ -1387,7 +1421,7 @@
^Icon
constantNamed:#'MenuEditor linkSubmenuImage'
- ifAbsentPut:[(Depth4Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@ADQDQDQDQDQDQH@D"H"H"H"H"H"K0@RH"H"H"H"H"H/@A????????????<@D@@@@@@@@@@@C0@PL3L0DQDQDQD_@A@3L3LBH"H"H"<@DCL3L3@"H"H"K0@PL3L3L0??????@A@@@@L3L@@@@@<@DQDQDCL3@PLAG0@RH"H"@3L0@3@/@AH"H"H L3L3L0<@G?????<CL3L3L@@P@@@@@@@3L3LO@ADQDQDQDP@CLA<@D"H"H"H"H LBK0@RH"H"H"H"@BH/@B????????????<@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@b'); colorMap:((OrderedCollection new add:(Color black); add:(Color white); add:(Color grey:66.9978); add:(Color red:100.0 green:0.0 blue:0.0); add:(Color red:0.0 green:100.0 blue:0.0); add:(Color red:0.0 green:0.0 blue:100.0); add:(Color red:0.0 green:100.0 blue:100.0); add:(Color red:100.0 green:100.0 blue:0.0); add:(Color red:100.0 green:0.0 blue:100.0); add:(Color red:49.9962 green:0.0 blue:0.0); add:(Color red:0.0 green:49.9962 blue:0.0); add:(Color red:0.0 green:0.0 blue:49.9962); add:(Color red:0.0 green:49.9962 blue:49.9962); add:(Color red:49.9962 green:49.9962 blue:0.0); add:(Color red:49.9962 green:0.0 blue:49.9962); add:(Color grey:49.9962); yourself)); mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a'); yourself); yourself]!
+ ifAbsentPut:[(Depth4Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@ADQDQDQDQDQDQH@D"H"H"H"H"H"K0@RH"H"H"H"H"H/@A????????????<@D@@@@@@@@@@@C0@PL3L0DQDQDQD_@A@3L3LBH"H"H"<@DCL3L3@"H"H"K0@PL3L3L0??????@A@@@@L3L@@@@@<@DQDQDCL3@PLAG0@RH"H"@3L0@3@/@AH"H"H L3L3L0<@G?????<CL3L3L@@P@@@@@@@3L3LO@ADQDQDQDP@CLA<@D"H"H"H"H LBK0@RH"H"H"H"@BH/@B????????????<@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 255 255 170 170 170 255 0 0 0 255 0 0 0 255 0 255 255 255 255 0 255 0 255 127 0 0 0 127 0 0 0 127 0 127 127 127 127 0 127 0 127 127 127 127]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a') ; yourself); yourself]!
menuItemImage
"Generated by the Image Editor"
@@ -1399,7 +1433,7 @@
^Icon
constantNamed:#'MenuEditor menuItemImage'
- ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'UUUUUUUQUUUUUUUPUUUUUUU_UUUUUUUPUUUUUUUP@@@@@@@@EUUUUUVAF*****+HF:?+::;@F:.+*?;@F:.+::;@F:.+*:;@F:.+::;@F*****+DK??????A@@@@@@@@UUUUUUUPUUUUUUUXUUUUUUUPUUUUUUUPUUUUUUUPUUUUUUUX'); colorMap:(((Array new:4) at:1 put:((Color black)); at:2 put:((Color white)); at:3 put:((Color grey:66.9978)); at:4 put:((Color grey:49.9962)); yourself)); mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@???<???<???<???<???<???<???<???<???<???<???<@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a'); yourself); yourself]!
+ ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'UUUUUUUQUUUUUUUPUUUUUUU_UUUUUUUPUUUUUUUP@@@@@@@@EUUUUUVAF*****+HF:?+::;@F:.+*?;@F:.+::;@F:.+*:;@F:.+::;@F*****+DK??????A@@@@@@@@UUUUUUUPUUUUUUUXUUUUUUUPUUUUUUUPUUUUUUUPUUUUUUUX') ; colorMapFromArray:#[0 0 0 255 255 255 170 170 170 127 127 127]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@???<???<???<???<???<???<???<???<???<???<???<@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a') ; yourself); yourself]!
menuSeparatorImage
"Generated by the Image Editor"
@@ -1411,7 +1445,7 @@
^Icon
constantNamed:#'MenuEditor menuSeparatorImage'
- ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'UUUUUUURUUUUUUUPUUUUUUUPUUUUUUUPUUUUUUUP@@@@@@@@EUUUUUV@F*****+DF*****+CF?????+@F0@@@@[@F%UUUU[HF*****+@F*****+@K??????N@@@@@@@HUUUUUUUPUUUUUUUPUUUUUUUWUUUUUUUXUUUUUUUPUUUUUUUP'); colorMap:(((Array new:4) at:1 put:((Color black)); at:2 put:((Color white)); at:3 put:((Color grey:66.9978)); at:4 put:((Color grey:49.9962)); yourself)); mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@???<???<???<???<???<???<???<???<???<???<???<@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a'); yourself); yourself]!
+ ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'UUUUUUURUUUUUUUPUUUUUUUPUUUUUUUPUUUUUUUP@@@@@@@@EUUUUUV@F*****+DF*****+CF?????+@F0@@@@[@F%UUUU[HF*****+@F*****+@K??????N@@@@@@@HUUUUUUUPUUUUUUUPUUUUUUUWUUUUUUUXUUUUUUUPUUUUUUUP') ; colorMapFromArray:#[0 0 0 255 255 255 170 170 170 127 127 127]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@???<???<???<???<???<???<???<???<???<???<???<@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a') ; yourself); yourself]!
submenuImage
"Generated by the Image Editor"
@@ -1423,7 +1457,7 @@
^Icon
constantNamed:#'MenuEditor submenuImage'
- ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@EUUUUUV@F*****+@F*****+@G??????GD@@@@@C@EUUUUUWLF*****+@F*****+@G??????HD@@@@@C@EUUUUUW@F*****+@F*****+OG??????@D@@@@@C@EUUUUUW@F*****+@F*****+@K??????@@@@@@@@@@@@@@@@@'); colorMap:(((Array new:4) at:1 put:((Color black)); at:2 put:((Color white)); at:3 put:((Color grey:66.9978)); at:4 put:((Color grey:49.9962)); yourself)); mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a'); yourself); yourself]! !
+ ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@EUUUUUV@F*****+@F*****+@G??????GD@@@@@C@EUUUUUWLF*****+@F*****+@G??????HD@@@@@C@EUUUUUW@F*****+@F*****+OG??????@D@@@@@C@EUUUUUW@F*****+@F*****+@K??????@@@@@@@@@@@@@@@@@') ; colorMapFromArray:#[0 0 0 255 255 255 170 170 170 127 127 127]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<???<@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a') ; yourself); yourself]! !
!MenuEditor class methodsFor:'slices'!
@@ -1796,7 +1830,8 @@
ifTrue:
[
self helpTool accept.
- node contents activeHelpKey: self helpTool helpKey
+ node contents activeHelpKey: self helpTool helpKey.
+ self valueOfEnablingCommitButtons value: false.
]
ifFalse:
[
@@ -2190,7 +2225,7 @@
iconFor: aNode
- aNode hasChildren
+ (aNode hasChildren or: [aNode parent isNil])
ifTrue:
[
^MenuEditor submenuImage
@@ -2406,8 +2441,8 @@
<resource: #keyboard (#Delete #BackSpace #Cut #Copy #Paste)>
- (key == #Cut or:[key == #Delete or:[key == #BackSpace]]) ifTrue: [^self doCut].
-
+ (key == #Delete or:[key == #BackSpace]) ifTrue: [^self doDelete].
+ key == #Cut ifTrue:[^self doCut].
key == #Copy ifTrue:[^self doCopy].
key == #Paste ifTrue:[^self doPaste].
@@ -2475,7 +2510,7 @@
doCut
- self askForItemModification
+ (self topView application hasValidSelection value and: [self askForItemModification])
ifTrue:
[
|selectedNodes|
@@ -2488,6 +2523,20 @@
!
+doDelete
+
+ (self topView application hasValidSelection value and: [self askForItemModification])
+ ifTrue:
+ [
+ |selectedNodes|
+ selectedNodes := self selection asSortedCollection.
+ self selectedNodesRemove.
+ self selection: selectedNodes first - 1.
+ self setModified.
+ ]
+
+!
+
doPaste
(self application clipboard notNil and:[self selectedNode notNil]) ifTrue:[