diff --git a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/contents.st b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/contents.st index d99e3ac0e..0af13143b 100644 --- a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/contents.st +++ b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/contents.st @@ -16,7 +16,9 @@ contents selectedMessageCategory isNil ifTrue: [ "class definition" - self selectedClass definition ] + (self selectedClass respondsTo: #definitionString) + ifTrue: [ self selectedClass definitionString ] + ifFalse: [ self selectedClass definition ] ] ifFalse: [ "method template" self selectedClass sourceCodeTemplate ] ] ] diff --git a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/messageCategoryList.st b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/messageCategoryList.st index 487ce9acf..d99cebc66 100644 --- a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/messageCategoryList.st +++ b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/messageCategoryList.st @@ -4,7 +4,9 @@ messageCategoryList | all categories unclassified | all := #'-- all --'. "AllProtocol defaultName is fucked in Pharo 2.0" self selectedClass ifNil: [ ^ Array with: all ]. - categories := self selectedClass organization categories. + categories := (self selectedClass respondsTo: #protocolNames) + ifTrue: [ self selectedClass protocolNames ] + ifFalse: [ self selectedClass organization categories ]. (categories notEmpty and: [ categories first = all ]) ifFalse: [ "all is only in 3.0+" categories := (Array with: all) , categories ]. unclassified := Protocol unclassified. "#unclassified only in 3.0+" diff --git a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/messageList.st b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/messageList.st index 8a3c18d9c..6e14f70d5 100644 --- a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/messageList.st +++ b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/messageList.st @@ -6,12 +6,15 @@ messageList ifTrue: [ #() ] ifFalse: [ self selectedClass selectors ] ] ifFalse: [ - | organization organizer | - organization := self selectedClass organization. - organizer := (organization respondsTo: #protocolOrganizer) "Only in Pharo 3.0+" - ifTrue: [ organization protocolOrganizer ] - ifFalse: [ - | classOrganization | - classOrganization := Smalltalk globals class name hasClassNamed: 'ClassOrganization'. - (classOrganization importFrom: self selectedClass organization) protocolOrganizer ]. - organizer methodsInProtocolNamed: selectedMessageCategory ]) sorted \ No newline at end of file + (self selectedClass respondsTo: #selectorsInProtocol:) + ifTrue: [ self selectedClass selectorsInProtocol: selectedMessageCategory ] + ifFalse: [ + | organization organizer | + organization := self selectedClass organization. + organizer := (organization respondsTo: #protocolOrganizer) "Only in Pharo 3.0+" + ifTrue: [ organization protocolOrganizer ] + ifFalse: [ + | classOrganization | + classOrganization := Smalltalk globals class name classNamed: 'ClassOrganization'. + (classOrganization importFrom: self selectedClass organization) protocolOrganizer ]. + organizer methodsInProtocolNamed: selectedMessageCategory ] ]) sorted \ No newline at end of file diff --git a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/packageNameOf..st b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/packageNameOf..st new file mode 100644 index 000000000..dff783bad --- /dev/null +++ b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/packageNameOf..st @@ -0,0 +1,5 @@ +private +packageNameOf: aPackage + ^ (aPackage respondsTo: #name) + ifTrue: [ aPackage name ] + ifFalse: [ aPackage packageName ] \ No newline at end of file diff --git a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/packages.st b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/packages.st index 15d383a54..cce7c8a92 100644 --- a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/packages.st +++ b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/packages.st @@ -1,3 +1,7 @@ private packages - ^ (Smalltalk at: #RPackage) organizer packages \ No newline at end of file + | rPackage | + rPackage := Smalltalk at: #RPackage. + ^ ((rPackage respondsTo: #packageOrganizer) + ifTrue: [ rPackage packageOrganizer ] + ifFalse: [ rPackage organizer ]) packages \ No newline at end of file diff --git a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/selectedClass.st b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/selectedClass.st index 293923181..32613fa22 100644 --- a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/selectedClass.st +++ b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/selectedClass.st @@ -3,5 +3,7 @@ selectedClass | class | class := selectedClass. (class notNil and: [ showInstance not ]) ifTrue: [ - class := class theMetaClass ]. + class := (class respondsTo: #classSide) + ifTrue: [ class classSide ] + ifFalse: [ class theMetaClass ] ]. ^ class \ No newline at end of file diff --git a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/systemCategoryList.st b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/systemCategoryList.st index 387dfe89c..39a5f34c5 100644 --- a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/systemCategoryList.st +++ b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/systemCategoryList.st @@ -1,5 +1,4 @@ accessing systemCategoryList - ^ (self packages - collect: [ :each | each packageName ]) - sorted \ No newline at end of file + + ^ (self packages collect: [ :each | (self packageNameOf: each) ]) sorted \ No newline at end of file diff --git a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/systemCategoryListIndex..st b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/systemCategoryListIndex..st index 11ec9feb6..5f56e3bf8 100644 --- a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/systemCategoryListIndex..st +++ b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/systemCategoryListIndex..st @@ -1,7 +1,7 @@ accessing systemCategoryListIndex: anInteger selectedPackage := ((self packages - sorted: [ :a :b | a packageName <= b packageName ]) at: anInteger). + sorted: [ :a :b | (self packageNameOf: a) <= (self packageNameOf: b) ]) at: anInteger). selectedClass := nil. self clearMessageAndProtoclSelection. self changed: #systemCategoryListIndex \ No newline at end of file diff --git a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/systemCategoryListIndex.st b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/systemCategoryListIndex.st index 8f4b39645..fee001396 100644 --- a/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/systemCategoryListIndex.st +++ b/repository/Seaside-Pharo-Development.package/WARPackageBasedBrowser.class/instance/systemCategoryListIndex.st @@ -1,5 +1,5 @@ accessing systemCategoryListIndex ^ (self packages - sorted: [ :a :b | a packageName <= b packageName ]) + sorted: [ :a :b | (self packageNameOf: a) <= (self packageNameOf: b) ]) indexOf: selectedPackage \ No newline at end of file diff --git a/repository/Seaside-Pharo-Development.package/monticello.meta/categories.st b/repository/Seaside-Pharo-Development.package/monticello.meta/categories.st index c6ffbf061..bc1692a3b 100644 --- a/repository/Seaside-Pharo-Development.package/monticello.meta/categories.st +++ b/repository/Seaside-Pharo-Development.package/monticello.meta/categories.st @@ -1,4 +1 @@ -SystemOrganization addCategory: #'Seaside-Pharo-Development'! -SystemOrganization addCategory: #'Seaside-Pharo-Development-Core'! -SystemOrganization addCategory: #'Seaside-Pharo-Development-Core-Plugins'! -SystemOrganization addCategory: #'Seaside-Pharo-Development-Core-Profiler'! +self packageOrganizer ensurePackage: #'Seaside-Pharo-Development' withTags: #(#Core #'Core-Plugins' #'Core-Profiler')!