--- a/UIPainter.st Mon Sep 08 14:11:15 2003 +0200
+++ b/UIPainter.st Wed Sep 10 13:02:18 2003 +0200
@@ -167,14 +167,20 @@
#editInspectSpec
'Inspect spec'
+#editBrowseViewClass
+'Browse widgets class'
+
#editInspectView
-'Onspect view'
+'Inspect widget'
#editOpenSpecDocumentation
'WidgetDocumentation'
+#fileBrowseClass
+'Browse applications class'
+
#fileBrowseAspectMethods
-'Browse aspects'
+'Browse applications aspect methods'
#fileLoad
'Load spec'
@@ -332,14 +338,20 @@
#editInspectSpec
'Opens an inspector on the spec of the selected widget.'
+#editBrowseViewClass
+'Opens a browser on the class of the selected widget.'
+
#editInspectView
-'Opens an inspector on the view of the selected widget.'
+'Opens an inspector on the selected widget.'
#editOpenSpecDocumentation
'Opens the documentation of the selected widget.'
+#fileBrowseClass
+'Open a System Browser on the applications class.'
+
#fileBrowseAspectMethods
-'Opens a System Browser on the aspect methods.'
+'Opens a System Browser on the applications aspect methods.'
#fileLoad
'Opens a dialog to load a window specification from a classes spec method.'
@@ -1040,14 +1052,14 @@
#(#MenuItem
#activeHelpKey: #fileBrowseClass
#enabled: #hasSpecClass
- #label: 'Browse Class'
+ #label: 'Browse Applications Class'
#itemValue: #doBrowseClass
#translateLabel: true
)
#(#MenuItem
#activeHelpKey: #fileBrowseAspectMethods
#enabled: #hasSpecClass
- #label: 'Browse Aspect Methods'
+ #label: 'Browse Applications Aspect Methods'
#itemValue: #doBrowseAspectMethods
#translateLabel: true
)
@@ -1611,7 +1623,14 @@
#label: '-'
)
#(#MenuItem
- #label: 'Inspect View'
+ #label: 'Browse Widget Class'
+ #translateLabel: true
+ #value: #doBrowseViewClass
+ #activeHelpKey: #editBrowseViewClass
+ #enabled: #hasOneSelectionOtherThanCanvas
+ )
+ #(#MenuItem
+ #label: 'Inspect Widget'
#translateLabel: true
#value: #doInspectView
#activeHelpKey: #editInspectView
@@ -3428,6 +3447,18 @@
UserPreferences systemBrowserClass openInClass:(self resolveName:specClass)
!
+doBrowseViewClass
+ "opens a browser on the selected widgets class"
+
+ |selection|
+
+ ((selection := self painter selection) isCollection and: [selection size >= 1]) ifTrue:[
+ selection first class browse
+ ] ifFalse: [
+ selection class browse
+ ]
+!
+
doDefineClassAndSelector
"launches a dialog for defining class, superclass, and selector of the application"