--- a/MenuEditor.st Wed Jul 08 22:58:41 1998 +0200
+++ b/MenuEditor.st Mon Jul 13 16:25:31 1998 +0200
@@ -892,11 +892,11 @@
#window:
#(#WindowSpec
#name: 'Image Item'
- #layout: #(#LayoutFrame 182 0 339 0 577 0 615 0)
+ #layout: #(#LayoutFrame 182 0 348 0 577 0 624 0)
#label: 'Image Item'
#min: #(#Point 10 10)
#max: #(#Point 1280 1024)
- #bounds: #(#Rectangle 182 339 578 616)
+ #bounds: #(#Rectangle 182 348 578 625)
#usePreferredExtent: false
)
#component:
@@ -955,8 +955,9 @@
)
#(#SequenceViewSpec
#name: 'systemOrUserImagesList'
- #layout: #(#LayoutFrame 110 0 66 0 0 0.6 200 0)
+ #layout: #(#LayoutFrame 110 0 67 0 0 0.6 200 0)
#model: #selectionOfImage
+ #menu: #menuEditImage
#hasHorizontalScrollBar: true
#hasVerticalScrollBar: true
#miniScrollerHorizontal: true
@@ -1422,6 +1423,46 @@
)
!
+menuEditImage
+ "This resource specification was automatically generated
+ by the MenuEditor of ST/X."
+
+ "Do not manually edit this!! If it is corrupted,
+ the MenuEditor may not be able to read the specification."
+
+ "
+ MenuEditor new openOnClass:MenuEditor andSelector:#menuEditImage
+ (Menu new fromLiteralArrayEncoding:(MenuEditor menuEditImage)) startUp
+ "
+
+ <resource: #menu>
+
+ ^
+
+ #(#Menu
+
+ #(
+ #(#MenuItem
+ #label: 'Edit'
+ #translateLabel: true
+ #value: #doEditImage
+ #activeHelpKey: #editCut
+ #enabled: #hasValidSelection
+ #shortcutKeyCharacter: #Cut
+ )
+ #(#MenuItem
+ #label: 'Remove'
+ #translateLabel: true
+ #value: #doRemoveImage
+ #activeHelpKey: #editCopy
+ #enabled: #hasValidSelection
+ #shortcutKeyCharacter: #Copy
+ )
+ ) nil
+ nil
+ )
+!
+
menuToolbar
"This resource specification was automatically generated
by the MenuEditor of ST/X."
@@ -2048,6 +2089,8 @@
!
doEditImage
+ "opens a Image Editor on the resource retriever and the icon selector;
+ then updates the list of images and select the line of the image"
super doEditImage.
@@ -2073,6 +2116,20 @@
^ nil
!
+doRemoveImage
+ "removes the image of the selected line"
+
+ self selectionOfImage value notNil
+ ifTrue:
+ [
+ (Smalltalk at: (aspects at: #retriever) value ? specClass) class removeSelector:
+ self selectionOfImage value string.
+
+ self updateListAndSelectionOfImage.
+ (aspects at:#icon) value: nil
+ ]
+!
+
doSave
|cls treeView menu spec mthd category code excla|