CodeView.st
changeset 2046 3593143e38e3
parent 1749 0d0f27322523
child 2097 66d564e3752a
equal deleted inserted replaced
2045:4796486fc00a 2046:3593143e38e3
   177     "return the popUpMenu;
   177     "return the popUpMenu;
   178      to make this independent from what is defined in superclasses,
   178      to make this independent from what is defined in superclasses,
   179      get the superclass menu and add my functions."
   179      get the superclass menu and add my functions."
   180 
   180 
   181     <resource: #keyboard (#CommentSelection #UncommentSelection 
   181     <resource: #keyboard (#CommentSelection #UncommentSelection 
   182                           #Accept #Explain)>
   182                           #Accept #Explain #Format)>
   183     <resource: #programMenu>
   183     <resource: #programMenu>
   184 
   184 
   185     |m sub sensor|
   185     |m sub sensor|
   186 
   186 
   187     m := super editMenu.
   187     m := super editMenu.
   208         sub notNil ifTrue:[
   208         sub notNil ifTrue:[
   209             sub addLabels:(resources array:#('-' 'explain'))
   209             sub addLabels:(resources array:#('-' 'explain'))
   210                 selectors:#(nil explain)
   210                 selectors:#(nil explain)
   211                 accelerators:#(nil Explain)
   211                 accelerators:#(nil Explain)
   212                 after:#gotoLine.
   212                 after:#gotoLine.
       
   213 
       
   214             formatAction notNil ifTrue:[
       
   215                 sub addLabels:(resources array:#('format'))
       
   216                     selectors:#(format)
       
   217                     accelerators:#(Format)
       
   218                     after:#indent.
       
   219             ].
   213 
   220 
   214             (self hasSelection not
   221             (self hasSelection not
   215             or:[explainAction isNil]) ifTrue:[
   222             or:[explainAction isNil]) ifTrue:[
   216                 sub disable:#explain 
   223                 sub disable:#explain 
   217             ].
   224             ].
   218         ].
   225         ].
   219     ].
   226     ].
   220     ^ m.
   227     ^ m.
   221 
   228 
   222     "Modified: / 29.7.1998 / 16:14:52 / cg"
   229     "Modified: / 22.11.1999 / 11:41:40 / cg"
   223 !
   230 !
   224 
   231 
   225 explain
   232 explain
   226     "explain action;
   233     "explain action;
   227      evaluate the explainBlock passing whole contents and 
   234      evaluate the explainBlock passing whole contents and 
   255 ! !
   262 ! !
   256 
   263 
   257 !CodeView class methodsFor:'documentation'!
   264 !CodeView class methodsFor:'documentation'!
   258 
   265 
   259 version
   266 version
   260     ^ '$Header: /cvs/stx/stx/libwidg/CodeView.st,v 1.41 1999-02-19 18:11:03 cg Exp $'
   267     ^ '$Header: /cvs/stx/stx/libwidg/CodeView.st,v 1.42 1999-11-22 10:44:27 cg Exp $'
   261 ! !
   268 ! !