# HG changeset patch # User Claus Gittinger # Date 1373400424 -7200 # Node ID 58cc0b4028159a89959cc9875abc262fcfc8543a # Parent 272d45da727d6a6944ed4443b46d6a1b6d62c89c class: MenuEditor added: #doBrowseChoiceMethod #doBrowseIndicationMethod comment/format in: #doBrowseActionMethod changed: #doBrowseApplicationMethodFor: diff -r 272d45da727d -r 58cc0b402815 MenuEditor.st --- a/MenuEditor.st Tue Jul 09 21:55:06 2013 +0200 +++ b/MenuEditor.st Tue Jul 09 22:07:04 2013 +0200 @@ -2586,7 +2586,7 @@ ! doBrowseActionMethod - "open a browser on the callback method (create if not yet existing)" + "open a browser on the action callback method (create if not yet existing)" self doBrowseApplicationMethodFor:#itemValue @@ -2603,7 +2603,7 @@ selector := (self aspectFor:aspect) value. selector isEmptyOrNil ifTrue:[ - Dialog information:(resources string:'Please enter an action method name.'). + Dialog information:(resources string:'Missing name for the action/aspect method.'). ^ self ]. (selector = 'true' or:[selector = 'false']) ifTrue:[^ self]. @@ -2620,10 +2620,12 @@ browsedClass := cls. (cls includesSelector:selector) ifFalse:[ (implClass := cls whichClassImplements:selector) notNil ifTrue:[ - (Dialog confirm:(resources - stringWithCRs:'The application does not directly implement %1.\However it inherits this from %2.\\Create a redefinition in %1?' - with:cls name - with:implClass name)) + (Dialog + confirm:(resources + stringWithCRs:'The application does not directly implement %1.\However it inherits this from %2.\\Create a redefinition in %1?' + with:cls name + with:implClass name) + initialAnswer:false) ifTrue:[ category := UserPreferences current categoryForMenuActionsMethods. @@ -2643,6 +2645,12 @@ "Modified: / 31-01-2011 / 18:28:59 / cg" ! +doBrowseChoiceMethod + "open a browser on the choice aspect method (create if not yet existing)" + + self doBrowseApplicationMethodFor:#choice +! + doBrowseEnabledMethod "open a browser on the enabled method (create if not yet existing)" @@ -2651,6 +2659,12 @@ "Created: / 21-10-2010 / 14:09:41 / cg" ! +doBrowseIndicationMethod + "open a browser on the indicator aspect method (create if not yet existing)" + + self doBrowseApplicationMethodFor:#indication +! + doBrowseVisibilityMethod "open a browser on the visibility method (create if not yet existing)" @@ -4591,270 +4605,290 @@ - ^ + ^ #(FullSpec - name: basicsEditSpec - window: + name: basicsEditSpec + window: (WindowSpec - label: 'basicsEditSpec' - name: 'basicsEditSpec' - min: (Point 10 10) - bounds: (Rectangle 0 0 340 340) - ) - component: + label: 'basicsEditSpec' + name: 'basicsEditSpec' + min: (Point 10 10) + bounds: (Rectangle 0 0 340 340) + ) + component: (SpecCollection - collection: ( - (LabelSpec - label: 'Name Key:' - name: 'nameKeyLabel' - layout: (AlignmentOrigin 107 0 25 0 1 0.5) - activeHelpKey: basicsKey - translateLabel: true - resizeForLabel: true - adjust: right - ) - (InputFieldSpec - name: 'nameKeyField' - layout: (LayoutFrame 110 0 15 0 -5 1.0 37 0) - activeHelpKey: basicsKey - tabable: true - model: nameKey - group: inputGroup - type: symbolOrNil - immediateAccept: false - acceptOnLeave: false - acceptOnReturn: true - acceptOnTab: true - acceptOnLostFocus: false - acceptChannel: acceptChannel - modifiedChannel: modifiedChannel - acceptOnPointerLeave: false - ) - (LabelSpec - label: 'Label:' - name: 'labelLabel' - layout: (AlignmentOrigin 107 0 51 0 1 0.5) - activeHelpKey: basicsLabel - translateLabel: true - resizeForLabel: true - adjust: right - ) - (InputFieldSpec - name: 'labelField' - layout: (LayoutFrame 110 0 40 0 -5 1.0 62 0) - activeHelpKey: basicsLabel - tabable: true - model: rawLabel - group: inputGroup - immediateAccept: false - acceptOnReturn: true - acceptOnTab: true - acceptOnLostFocus: false - acceptChannel: acceptChannel - modifiedChannel: modifiedChannel - acceptOnPointerLeave: false - ) - (LabelSpec - label: 'Action:' - name: 'valueLabel' - layout: (AlignmentOrigin 107 0 82 0 1 0.5) - activeHelpKey: basicsAction - translateLabel: true - resizeForLabel: true - adjust: right - ) - (InputFieldSpec - name: 'valueField' - layout: (LayoutFrame 110 0 71 0 -25 1.0 93 0) - activeHelpKey: basicsAction - tabable: true - model: itemValue - group: inputGroup - type: symbolOrNil - immediateAccept: false - acceptOnLeave: true - acceptOnReturn: true - acceptOnTab: true - acceptOnLostFocus: true - acceptChannel: acceptChannel - modifiedChannel: modifiedChannel - acceptOnPointerLeave: true - ) - (ActionButtonSpec - label: 'browseActionImage' - name: 'Button1' - layout: (LayoutFrame -25 1 71 0 -5 1 93 0) - hasCharacterOrientedLabel: false - translateLabel: true - resizeForLabel: true - tabable: true - model: doBrowseActionMethod - activeHelpKey: browseMethod - ) - (LabelSpec - label: 'Argument:' - name: 'argumentLabel' - layout: (AlignmentOrigin 107 0 107 0 1 0.5) - activeHelpKey: basicsArgument - translateLabel: true - resizeForLabel: true - adjust: right - ) - (InputFieldSpec - name: 'argumentField' - layout: (LayoutFrame 110 0 96 0 -5 1.0 118 0) - activeHelpKey: basicsArgument - tabable: true - model: argument - group: inputGroup - type: smalltalkObjectOrNil - immediateAccept: false - acceptOnReturn: true - acceptOnTab: true - acceptOnLostFocus: false - acceptChannel: acceptChannel - modifiedChannel: modifiedChannel - acceptOnPointerLeave: false - ) - (LabelSpec - label: 'Indication:' - name: 'indicationLabel' - layout: (AlignmentOrigin 107 0 138 0 1 0.5) - activeHelpKey: basicsIndication - translateLabel: true - resizeForLabel: true - adjust: right - ) - (InputFieldSpec - name: 'indicationField' - layout: (LayoutFrame 110 0 127 0 -5 1.0 149 0) - activeHelpKey: basicsIndication - enableChannel: indicationEnabled - tabable: true - model: indication - group: inputGroup - type: symbolOrNil - immediateAccept: true - acceptOnReturn: false - acceptOnTab: false - acceptOnLostFocus: false - modifiedChannel: modifiedChannel - acceptOnPointerLeave: false - ) - (LabelSpec - label: 'Choice:' - name: 'choiceLabel' - layout: (AlignmentOrigin 107 0 163 0 1 0.5) - activeHelpKey: basicsChoice - translateLabel: true - resizeForLabel: true - adjust: right - ) - (InputFieldSpec - name: 'choiceField' - layout: (LayoutFrame 110 0 152 0 -5 1.0 174 0) - activeHelpKey: basicsChoice - enableChannel: choiceEnabled - tabable: true - model: choice - group: inputGroup - type: symbolOrNil - immediateAccept: true - acceptOnReturn: false - acceptOnTab: false - acceptOnLostFocus: false - modifiedChannel: modifiedChannel - acceptOnPointerLeave: false - ) - (LabelSpec - label: 'Value:' - name: 'choiceValueLabel' - layout: (AlignmentOrigin 107 0 188 0 1 0.5) - activeHelpKey: basicsChoiceValue - translateLabel: true - resizeForLabel: true - adjust: right - ) - (InputFieldSpec - name: 'choiceValueField' - layout: (LayoutFrame 110 0 177 0 -5 1.0 199 0) - activeHelpKey: basicsChoiceValue - enableChannel: choiceValueEnabled - tabable: true - model: choiceValue - group: inputGroup - type: smalltalkObjectOrNil - immediateAccept: false - acceptOnLeave: false - acceptOnReturn: true - acceptOnTab: true - acceptOnLostFocus: false - acceptChannel: acceptChannel - modifiedChannel: modifiedChannel - acceptOnPointerLeave: false - ) - (CheckBoxSpec - label: 'Translate Label' - name: 'translateLabelCheckBox' - layout: (AlignmentOrigin 7 0 213 0 0 0) - activeHelpKey: basicsTranslateLabel - tabable: true - model: translateLabel - translateLabel: true - ) - (CheckBoxSpec - label: 'Is Button' - name: 'isButtonCheckBox' - layout: (AlignmentOrigin 7 0 238 0 0 0) - activeHelpKey: basicsIsButton - tabable: true - model: isButton - translateLabel: true - ) - (CheckBoxSpec - label: 'Hide Menu after Activation' - name: 'hideMenuOnActivated' - layout: (AlignmentOrigin 7 0 263 0 0 0) - activeHelpKey: hideMenuOnActivated - tabable: true - model: hideMenuOnActivated - translateLabel: true - ) - (CheckBoxSpec - label: 'BusyCursor while Active' - name: 'showBusyCursorWhilePerforming' - layout: (AlignmentOrigin 7 0 288 0 0 0) - activeHelpKey: showBusyCursorWhilePerforming - tabable: true - model: showBusyCursorWhilePerforming - translateLabel: true - ) - (CheckBoxSpec - label: 'Trigger On Down' - name: 'triggerOnDown' - layout: (AlignmentOrigin 25 0.5 238 0 0 0) - activeHelpKey: triggerOnDown - enableChannel: hasNoDelayedMenuValue - tabable: true - model: triggerOnDown - translateLabel: true - ) - (CheckBoxSpec - label: 'Send To Originating Widget' - name: 'sendToOriginator' - layout: (AlignmentOrigin 7 0 313 0 0 0) - activeHelpKey: sendToOriginator - enableChannel: hasItemValue - tabable: true - model: sendToOriginator - translateLabel: true - ) - ) - - ) + collection: ( + (LabelSpec + label: 'Name Key:' + name: 'nameKeyLabel' + layout: (AlignmentOrigin 107 0 25 0 1 0.5) + activeHelpKey: basicsKey + translateLabel: true + resizeForLabel: true + adjust: right + ) + (InputFieldSpec + name: 'nameKeyField' + layout: (LayoutFrame 110 0 15 0 -5 1.0 37 0) + activeHelpKey: basicsKey + tabable: true + model: nameKey + group: inputGroup + type: symbolOrNil + immediateAccept: false + acceptOnLeave: false + acceptOnReturn: true + acceptOnTab: true + acceptOnLostFocus: false + acceptChannel: acceptChannel + modifiedChannel: modifiedChannel + acceptOnPointerLeave: false + ) + (LabelSpec + label: 'Label:' + name: 'labelLabel' + layout: (AlignmentOrigin 107 0 51 0 1 0.5) + activeHelpKey: basicsLabel + translateLabel: true + resizeForLabel: true + adjust: right + ) + (InputFieldSpec + name: 'labelField' + layout: (LayoutFrame 110 0 40 0 -5 1.0 62 0) + activeHelpKey: basicsLabel + tabable: true + model: rawLabel + group: inputGroup + immediateAccept: false + acceptOnReturn: true + acceptOnTab: true + acceptOnLostFocus: false + acceptChannel: acceptChannel + modifiedChannel: modifiedChannel + acceptOnPointerLeave: false + ) + (LabelSpec + label: 'Action:' + name: 'valueLabel' + layout: (AlignmentOrigin 107 0 82 0 1 0.5) + activeHelpKey: basicsAction + translateLabel: true + resizeForLabel: true + adjust: right + ) + (InputFieldSpec + name: 'valueField' + layout: (LayoutFrame 110 0 71 0 -25 1.0 93 0) + activeHelpKey: basicsAction + tabable: true + model: itemValue + group: inputGroup + type: symbolOrNil + immediateAccept: false + acceptOnLeave: true + acceptOnReturn: true + acceptOnTab: true + acceptOnLostFocus: true + acceptChannel: acceptChannel + modifiedChannel: modifiedChannel + acceptOnPointerLeave: true + ) + (ActionButtonSpec + label: 'browseActionImage' + name: 'Button1' + layout: (LayoutFrame -25 1 71 0 -5 1 93 0) + activeHelpKey: browseMethod + hasCharacterOrientedLabel: false + translateLabel: true + resizeForLabel: true + tabable: true + model: doBrowseActionMethod + ) + (LabelSpec + label: 'Argument:' + name: 'argumentLabel' + layout: (AlignmentOrigin 107 0 107 0 1 0.5) + activeHelpKey: basicsArgument + translateLabel: true + resizeForLabel: true + adjust: right + ) + (InputFieldSpec + name: 'argumentField' + layout: (LayoutFrame 110 0 96 0 -5 1.0 118 0) + activeHelpKey: basicsArgument + tabable: true + model: argument + group: inputGroup + type: smalltalkObjectOrNil + immediateAccept: false + acceptOnReturn: true + acceptOnTab: true + acceptOnLostFocus: false + acceptChannel: acceptChannel + modifiedChannel: modifiedChannel + acceptOnPointerLeave: false + ) + (LabelSpec + label: 'Indication:' + name: 'indicationLabel' + layout: (AlignmentOrigin 107 0 138 0 1 0.5) + activeHelpKey: basicsIndication + translateLabel: true + resizeForLabel: true + adjust: right + ) + (InputFieldSpec + name: 'indicationField' + layout: (LayoutFrame 110 0 127 0 -25 1.0 149 0) + activeHelpKey: basicsIndication + enableChannel: indicationEnabled + tabable: true + model: indication + group: inputGroup + type: symbolOrNil + immediateAccept: true + acceptOnReturn: false + acceptOnTab: false + acceptOnLostFocus: false + modifiedChannel: modifiedChannel + acceptOnPointerLeave: false + ) + (ActionButtonSpec + label: 'browseActionImage' + name: 'Button2' + layout: (LayoutFrame -25 1 127 0 -5 1 149 0) + activeHelpKey: browseMethod + hasCharacterOrientedLabel: false + translateLabel: true + resizeForLabel: true + tabable: true + model: doBrowseIndicationMethod + ) + (LabelSpec + label: 'Choice:' + name: 'choiceLabel' + layout: (AlignmentOrigin 107 0 163 0 1 0.5) + activeHelpKey: basicsChoice + translateLabel: true + resizeForLabel: true + adjust: right + ) + (InputFieldSpec + name: 'choiceField' + layout: (LayoutFrame 110 0 152 0 -25 1.0 174 0) + activeHelpKey: basicsChoice + enableChannel: choiceEnabled + tabable: true + model: choice + group: inputGroup + type: symbolOrNil + immediateAccept: true + acceptOnReturn: false + acceptOnTab: false + acceptOnLostFocus: false + modifiedChannel: modifiedChannel + acceptOnPointerLeave: false + ) + (ActionButtonSpec + label: 'browseActionImage' + name: 'Button3' + layout: (LayoutFrame -25 1 152 0 -5 1 174 0) + activeHelpKey: browseMethod + hasCharacterOrientedLabel: false + translateLabel: true + resizeForLabel: true + tabable: true + model: doBrowseChoiceMethod + ) + (LabelSpec + label: 'Value:' + name: 'choiceValueLabel' + layout: (AlignmentOrigin 107 0 188 0 1 0.5) + activeHelpKey: basicsChoiceValue + translateLabel: true + resizeForLabel: true + adjust: right + ) + (InputFieldSpec + name: 'choiceValueField' + layout: (LayoutFrame 110 0 177 0 -5 1.0 199 0) + activeHelpKey: basicsChoiceValue + enableChannel: choiceValueEnabled + tabable: true + model: choiceValue + group: inputGroup + type: smalltalkObjectOrNil + immediateAccept: false + acceptOnLeave: false + acceptOnReturn: true + acceptOnTab: true + acceptOnLostFocus: false + acceptChannel: acceptChannel + modifiedChannel: modifiedChannel + acceptOnPointerLeave: false + ) + (CheckBoxSpec + label: 'Translate Label' + name: 'translateLabelCheckBox' + layout: (AlignmentOrigin 7 0 213 0 0 0) + activeHelpKey: basicsTranslateLabel + tabable: true + model: translateLabel + translateLabel: true + ) + (CheckBoxSpec + label: 'Is Button' + name: 'isButtonCheckBox' + layout: (AlignmentOrigin 7 0 238 0 0 0) + activeHelpKey: basicsIsButton + tabable: true + model: isButton + translateLabel: true + ) + (CheckBoxSpec + label: 'Hide Menu after Activation' + name: 'hideMenuOnActivated' + layout: (AlignmentOrigin 7 0 263 0 0 0) + activeHelpKey: hideMenuOnActivated + tabable: true + model: hideMenuOnActivated + translateLabel: true + ) + (CheckBoxSpec + label: 'BusyCursor while Active' + name: 'showBusyCursorWhilePerforming' + layout: (AlignmentOrigin 7 0 288 0 0 0) + activeHelpKey: showBusyCursorWhilePerforming + tabable: true + model: showBusyCursorWhilePerforming + translateLabel: true + ) + (CheckBoxSpec + label: 'Trigger On Down' + name: 'triggerOnDown' + layout: (AlignmentOrigin 25 0.5 238 0 0 0) + activeHelpKey: triggerOnDown + enableChannel: hasNoDelayedMenuValue + tabable: true + model: triggerOnDown + translateLabel: true + ) + (CheckBoxSpec + label: 'Send To Originating Widget' + name: 'sendToOriginator' + layout: (AlignmentOrigin 7 0 313 0 0 0) + activeHelpKey: sendToOriginator + enableChannel: hasItemValue + tabable: true + model: sendToOriginator + translateLabel: true + ) + ) + + ) ) - - "Modified: / 21-10-2010 / 14:14:49 / cg" ! ! !MenuEditor::ActionItem class methodsFor:'interface-editor'!