#FEATURE by cg
authorClaus Gittinger <cg@exept.de>
Wed, 16 Aug 2017 13:58:23 +0200
changeset 34573f3ea99e8af5
parent 3456 4d4297bad4fa
child 3458 159bab42fdbb
#FEATURE by cg
class: Tools::ViewTreeInspectorApplication
more menu-item menu actions
comment/format in: #selectedView
changed:
#objectToInspectOrBrowse:
#submenuMenuItemInterface:

class: Tools::ViewTreeInspectorApplication class
changed: #middleButtonMenuForMenuItems
Tools__ViewTreeApplication.st
     1.1 --- a/Tools__ViewTreeApplication.st	Wed Aug 16 13:52:20 2017 +0200
     1.2 +++ b/Tools__ViewTreeApplication.st	Wed Aug 16 13:58:23 2017 +0200
     1.3 @@ -771,16 +771,16 @@
     1.4          (
     1.5           (MenuItem
     1.6              label: 'Browse Menu Item''s Class'
     1.7 -            itemValue: doBrowseMenuItem:
     1.8 -            argument: view
     1.9 +            itemValue: doBrowse:
    1.10 +            argument: menuItem
    1.11            )
    1.12           (MenuItem
    1.13              label: '-'
    1.14            )
    1.15           (MenuItem
    1.16              label: 'Inspect Menu Item'
    1.17 -            itemValue: doInspectMenuItem:
    1.18 -            argument: view
    1.19 +            itemValue: doInspect:
    1.20 +            argument: menuItem
    1.21            )
    1.22           (MenuItem
    1.23              label: '-'
    1.24 @@ -1886,7 +1886,13 @@
    1.25  
    1.26      list := OrderedCollection new.
    1.27  
    1.28 -    list add:(MenuDesc title:'itemValue'  value:(item itemValue)).
    1.29 +    list add:(MenuDesc 
    1.30 +                title:'itemValue' 
    1.31 +                value:(item itemValue)
    1.32 +                action:[ 
    1.33 +                    UserPreferences systemBrowserClass
    1.34 +                        browseImplementorsOf:item itemValue
    1.35 +                ]).
    1.36  
    1.37      ^ MenuDesc buildFromList:list onGC:aMenu
    1.38  
    1.39 @@ -2083,7 +2089,9 @@
    1.40  
    1.41      item := model selectedItem.
    1.42      item notNil ifTrue:[ ^ item widget ].
    1.43 -  ^ nil
    1.44 +    ^ nil
    1.45 +
    1.46 +    "Modified (format): / 16-08-2017 / 13:57:30 / cg"
    1.47  ! !
    1.48  
    1.49  !ViewTreeInspectorApplication methodsFor:'testing'!
    1.50 @@ -2318,16 +2326,21 @@
    1.51  
    1.52  objectToInspectOrBrowse:what
    1.53      "return one of:
    1.54 -        #view           inspect view/widget
    1.55 -        #group          inspect windowGroup
    1.56 -        #model          inspect model
    1.57 -        #application    inspect application
    1.58 -        #controller     inspect controller
    1.59 -        #process        inspect application's process
    1.60 -        #widgetClass    browse widget's class
    1.61 +        #view           for inspect/browse view/widget
    1.62 +        #group          for inspect/browse windowGroup
    1.63 +        #model          for inspect/browse model
    1.64 +        #application    for inspect/browse application
    1.65 +        #controller     for inspect/browse controller
    1.66 +        #process        for inspect/browse application's process
    1.67 +        #widgetClass    for inspect/browse widget's class
    1.68 +        #menuItem       for inspect/browse menuItem
    1.69      "
    1.70      |view|
    1.71  
    1.72 +    what == #menuItem       ifTrue:[ 
    1.73 +        ^ model selectedItem menuItem
    1.74 +    ].
    1.75 +
    1.76      view := self selectedView.
    1.77      view isNil ifTrue:[^ nil].
    1.78  
    1.79 @@ -2341,7 +2354,7 @@
    1.80  
    1.81      ^ view
    1.82  
    1.83 -    "Modified: / 28-08-2013 / 23:58:27 / cg"
    1.84 +    "Modified: / 16-08-2017 / 13:57:36 / cg"
    1.85  !
    1.86  
    1.87  openDocumentation