Browse Source

Helios: Improved command registration in menus

Nicolas Petton 11 years ago
parent
commit
f60a3f9e9e

+ 28 - 15
js/Helios-Browser.deploy.js

@@ -274,6 +274,19 @@ smalltalk.HLBrowser.klass);
 
 
 smalltalk.addClass('HLBrowserListWidget', smalltalk.HLNavigationListWidget, ['model'], 'Helios-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "commandCategory",
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+var $1;
+$1=_st(self)._label();
+return $1;
+}, function($ctx1) {$ctx1.fill(self,"commandCategory",{},smalltalk.HLBrowserListWidget)})},
+messageSends: ["label"]}),
+smalltalk.HLBrowserListWidget);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "label",
@@ -293,16 +306,22 @@ var self=this;
 function $HLBrowserCommand(){return smalltalk.HLBrowserCommand||(typeof HLBrowserCommand=="undefined"?nil:HLBrowserCommand)}
 return smalltalk.withContext(function($ctx1) { 
 var $1;
-$1=_st(_st(_st($HLBrowserCommand())._concreteClasses())._select_((function(each){
-return smalltalk.withContext(function($ctx2) {
-return _st(each)._isValidFor_(_st(self)._selectedItem());
-}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})})))._collect_((function(each){
+$1=_st(_st(_st($HLBrowserCommand())._concreteClasses())._collect_((function(each){
 return smalltalk.withContext(function($ctx2) {
 return _st(each)._for_(_st(self)._model());
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})})))._select_((function(each){
+return smalltalk.withContext(function($ctx2) {
+return _st(_st(_st(each)._category()).__eq(_st(self)._commandCategory()))._and_((function(){
+return smalltalk.withContext(function($ctx3) {
+return _st(_st(each)._isAction())._and_((function(){
+return smalltalk.withContext(function($ctx4) {
+return _st(each)._isActive();
+}, function($ctx4) {$ctx4.fillBlock({},$ctx1)})}));
+}, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
 }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
 return $1;
 }, function($ctx1) {$ctx1.fill(self,"menuCommands",{},smalltalk.HLBrowserListWidget)})},
-messageSends: ["collect:", "for:", "model", "select:", "isValidFor:", "selectedItem", "concreteClasses"]}),
+messageSends: ["select:", "and:", "isActive", "isAction", "=", "commandCategory", "category", "collect:", "for:", "model", "concreteClasses"]}),
 smalltalk.HLBrowserListWidget);
 
 smalltalk.addMethod(
@@ -1337,17 +1356,11 @@ selector=_st(aMethod)._selector();
 } else {
 selector=nil;
 };
-_st(self)._selectedItem_(selector);
-$2=selector;
-if(($receiver = $2) == nil || $receiver == undefined){
-$3=self;
-return $3;
-} else {
-$2;
-};
-_st(self)._activateItem_(selector);
+$2=self;
+_st($2)._selectedItem_(selector);
+$3=_st($2)._activateItem_(selector);
 return self}, function($ctx1) {$ctx1.fill(self,"onMethodSelected:",{aMethod:aMethod,selector:selector},smalltalk.HLMethodsListWidget)})},
-messageSends: ["ifTrue:ifFalse:", "selector", "isCompiledMethod", "selectedItem:", "ifNil:", "activateItem:"]}),
+messageSends: ["ifTrue:ifFalse:", "selector", "isCompiledMethod", "selectedItem:", "activateItem:"]}),
 smalltalk.HLMethodsListWidget);
 
 smalltalk.addMethod(

+ 35 - 17
js/Helios-Browser.js

@@ -359,6 +359,24 @@ smalltalk.HLBrowser.klass);
 
 
 smalltalk.addClass('HLBrowserListWidget', smalltalk.HLNavigationListWidget, ['model'], 'Helios-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "commandCategory",
+category: 'accessing',
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+var $1;
+$1=_st(self)._label();
+return $1;
+}, function($ctx1) {$ctx1.fill(self,"commandCategory",{},smalltalk.HLBrowserListWidget)})},
+args: [],
+source: "commandCategory\x0a\x09^ self label",
+messageSends: ["label"],
+referencedClasses: []
+}),
+smalltalk.HLBrowserListWidget);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "label",
@@ -384,18 +402,24 @@ var self=this;
 function $HLBrowserCommand(){return smalltalk.HLBrowserCommand||(typeof HLBrowserCommand=="undefined"?nil:HLBrowserCommand)}
 return smalltalk.withContext(function($ctx1) { 
 var $1;
-$1=_st(_st(_st($HLBrowserCommand())._concreteClasses())._select_((function(each){
-return smalltalk.withContext(function($ctx2) {
-return _st(each)._isValidFor_(_st(self)._selectedItem());
-}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})})))._collect_((function(each){
+$1=_st(_st(_st($HLBrowserCommand())._concreteClasses())._collect_((function(each){
 return smalltalk.withContext(function($ctx2) {
 return _st(each)._for_(_st(self)._model());
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})})))._select_((function(each){
+return smalltalk.withContext(function($ctx2) {
+return _st(_st(_st(each)._category()).__eq(_st(self)._commandCategory()))._and_((function(){
+return smalltalk.withContext(function($ctx3) {
+return _st(_st(each)._isAction())._and_((function(){
+return smalltalk.withContext(function($ctx4) {
+return _st(each)._isActive();
+}, function($ctx4) {$ctx4.fillBlock({},$ctx1)})}));
+}, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
 }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
 return $1;
 }, function($ctx1) {$ctx1.fill(self,"menuCommands",{},smalltalk.HLBrowserListWidget)})},
 args: [],
-source: "menuCommands\x0a\x09\x22Answer a collection of commands to be put in the cog menu\x22\x0a\x09\x0a\x09^ (HLBrowserCommand concreteClasses \x0a\x09\x09select: [ :each | each isValidFor: self selectedItem ])\x0a\x09\x09collect: [ :each | each for: self model ]",
-messageSends: ["collect:", "for:", "model", "select:", "isValidFor:", "selectedItem", "concreteClasses"],
+source: "menuCommands\x0a\x09\x22Answer a collection of commands to be put in the cog menu\x22\x0a\x09\x0a\x09^ (HLBrowserCommand concreteClasses \x0a\x09\x09collect: [ :each | each for: self model ])\x0a\x09\x09select: [ :each | \x0a\x09\x09\x09each category = self commandCategory and: [ \x0a\x09\x09\x09\x09each isAction and: [ each isActive ] ] ]",
+messageSends: ["select:", "and:", "isActive", "isAction", "=", "commandCategory", "category", "collect:", "for:", "model", "concreteClasses"],
 referencedClasses: ["HLBrowserCommand"]
 }),
 smalltalk.HLBrowserListWidget);
@@ -1693,19 +1717,13 @@ selector=_st(aMethod)._selector();
 } else {
 selector=nil;
 };
-_st(self)._selectedItem_(selector);
-$2=selector;
-if(($receiver = $2) == nil || $receiver == undefined){
-$3=self;
-return $3;
-} else {
-$2;
-};
-_st(self)._activateItem_(selector);
+$2=self;
+_st($2)._selectedItem_(selector);
+$3=_st($2)._activateItem_(selector);
 return self}, function($ctx1) {$ctx1.fill(self,"onMethodSelected:",{aMethod:aMethod,selector:selector},smalltalk.HLMethodsListWidget)})},
 args: ["aMethod"],
-source: "onMethodSelected: aMethod\x0a\x09| selector |\x0a\x09selector := aMethod isCompiledMethod \x0a\x09\x09ifTrue: [ aMethod selector ]\x0a\x09\x09ifFalse: [ nil ].\x0a\x09\x09\x0a\x09self selectedItem: selector.\x0a\x09\x0a\x09selector ifNil: [ ^ self ].\x0a    \x0a\x09self activateItem: selector",
-messageSends: ["ifTrue:ifFalse:", "selector", "isCompiledMethod", "selectedItem:", "ifNil:", "activateItem:"],
+source: "onMethodSelected: aMethod\x0a\x09| selector |\x0a\x09selector := aMethod isCompiledMethod \x0a\x09\x09ifTrue: [ aMethod selector ]\x0a\x09\x09ifFalse: [ nil ].\x0a\x09\x09\x0a\x09self \x0a\x09\x09selectedItem: selector;\x0a\x09\x09activateItem: selector",
+messageSends: ["ifTrue:ifFalse:", "selector", "isCompiledMethod", "selectedItem:", "activateItem:"],
 referencedClasses: []
 }),
 smalltalk.HLMethodsListWidget);

+ 88 - 0
js/Helios-Commands-Browser.deploy.js

@@ -1,5 +1,16 @@
 smalltalk.addPackage('Helios-Commands-Browser');
 smalltalk.addClass('HLBrowserCommand', smalltalk.HLModelCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return nil;
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLBrowserCommand)})},
+messageSends: []}),
+smalltalk.HLBrowserCommand);
+
 
 smalltalk.addMethod(
 smalltalk.method({
@@ -224,6 +235,17 @@ smalltalk.HLGoToSourceCodeCommand.klass);
 
 
 smalltalk.addClass('HLCommitPackageCommand', smalltalk.HLBrowserCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Packages";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLCommitPackageCommand)})},
+messageSends: []}),
+smalltalk.HLCommitPackageCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "execute",
@@ -309,6 +331,17 @@ smalltalk.HLCopyCommand.klass);
 
 
 smalltalk.addClass('HLCopyClassCommand', smalltalk.HLCopyCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Classes";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLCopyClassCommand)})},
+messageSends: []}),
+smalltalk.HLCopyClassCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "displayLabel",
@@ -574,6 +607,17 @@ smalltalk.HLMoveClassToCommand.klass);
 
 
 smalltalk.addClass('HLMoveClassToPackageCommand', smalltalk.HLMoveClassToCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Classes";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLMoveClassToPackageCommand)})},
+messageSends: []}),
+smalltalk.HLMoveClassToPackageCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "displayLabel",
@@ -680,6 +724,17 @@ smalltalk.HLMoveClassToPackageCommand.klass);
 
 
 smalltalk.addClass('HLMoveMethodToCommand', smalltalk.HLMoveToCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Methods";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLMoveMethodToCommand)})},
+messageSends: []}),
+smalltalk.HLMoveMethodToCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "isActive",
@@ -955,6 +1010,17 @@ smalltalk.HLRemoveCommand.klass);
 
 
 smalltalk.addClass('HLRemoveClassCommand', smalltalk.HLRemoveCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Classes";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLRemoveClassCommand)})},
+messageSends: []}),
+smalltalk.HLRemoveClassCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "execute",
@@ -1028,6 +1094,17 @@ smalltalk.HLRemoveClassCommand.klass);
 
 
 smalltalk.addClass('HLRemoveMethodCommand', smalltalk.HLRemoveCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Methods";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLRemoveMethodCommand)})},
+messageSends: []}),
+smalltalk.HLRemoveMethodCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "execute",
@@ -1126,6 +1203,17 @@ smalltalk.HLRenameCommand.klass);
 
 
 smalltalk.addClass('HLRenameClassCommand', smalltalk.HLRenameCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Classes";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLRenameClassCommand)})},
+messageSends: []}),
+smalltalk.HLRenameClassCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "displayLabel",

+ 128 - 0
js/Helios-Commands-Browser.js

@@ -1,5 +1,21 @@
 smalltalk.addPackage('Helios-Commands-Browser');
 smalltalk.addClass('HLBrowserCommand', smalltalk.HLModelCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+category: 'accessing',
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return nil;
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLBrowserCommand)})},
+args: [],
+source: "category\x0a\x09^ nil",
+messageSends: [],
+referencedClasses: []
+}),
+smalltalk.HLBrowserCommand);
+
 
 smalltalk.addMethod(
 smalltalk.method({
@@ -314,6 +330,22 @@ smalltalk.HLGoToSourceCodeCommand.klass);
 
 
 smalltalk.addClass('HLCommitPackageCommand', smalltalk.HLBrowserCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+category: 'accessing',
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Packages";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLCommitPackageCommand)})},
+args: [],
+source: "category\x0a\x09^ 'Packages'",
+messageSends: [],
+referencedClasses: []
+}),
+smalltalk.HLCommitPackageCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "execute",
@@ -434,6 +466,22 @@ smalltalk.HLCopyCommand.klass);
 
 
 smalltalk.addClass('HLCopyClassCommand', smalltalk.HLCopyCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+category: 'accessing',
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Classes";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLCopyClassCommand)})},
+args: [],
+source: "category\x0a\x09^ 'Classes'",
+messageSends: [],
+referencedClasses: []
+}),
+smalltalk.HLCopyClassCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "displayLabel",
@@ -809,6 +857,22 @@ smalltalk.HLMoveClassToCommand.klass);
 
 
 smalltalk.addClass('HLMoveClassToPackageCommand', smalltalk.HLMoveClassToCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+category: 'accessing',
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Classes";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLMoveClassToPackageCommand)})},
+args: [],
+source: "category\x0a\x09^ 'Classes'",
+messageSends: [],
+referencedClasses: []
+}),
+smalltalk.HLMoveClassToPackageCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "displayLabel",
@@ -960,6 +1024,22 @@ smalltalk.HLMoveClassToPackageCommand.klass);
 
 
 smalltalk.addClass('HLMoveMethodToCommand', smalltalk.HLMoveToCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+category: 'accessing',
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Methods";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLMoveMethodToCommand)})},
+args: [],
+source: "category\x0a\x09^ 'Methods'",
+messageSends: [],
+referencedClasses: []
+}),
+smalltalk.HLMoveMethodToCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "isActive",
@@ -1350,6 +1430,22 @@ smalltalk.HLRemoveCommand.klass);
 
 
 smalltalk.addClass('HLRemoveClassCommand', smalltalk.HLRemoveCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+category: 'accessing',
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Classes";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLRemoveClassCommand)})},
+args: [],
+source: "category\x0a\x09^ 'Classes'",
+messageSends: [],
+referencedClasses: []
+}),
+smalltalk.HLRemoveClassCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "execute",
@@ -1453,6 +1549,22 @@ smalltalk.HLRemoveClassCommand.klass);
 
 
 smalltalk.addClass('HLRemoveMethodCommand', smalltalk.HLRemoveCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+category: 'accessing',
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Methods";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLRemoveMethodCommand)})},
+args: [],
+source: "category\x0a\x09^ 'Methods'",
+messageSends: [],
+referencedClasses: []
+}),
+smalltalk.HLRemoveMethodCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "execute",
@@ -1591,6 +1703,22 @@ smalltalk.HLRenameCommand.klass);
 
 
 smalltalk.addClass('HLRenameClassCommand', smalltalk.HLRenameCommand, [], 'Helios-Commands-Browser');
+smalltalk.addMethod(
+smalltalk.method({
+selector: "category",
+category: 'accessing',
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+return "Classes";
+}, function($ctx1) {$ctx1.fill(self,"category",{},smalltalk.HLRenameClassCommand)})},
+args: [],
+source: "category\x0a\x09^ 'Classes'",
+messageSends: [],
+referencedClasses: []
+}),
+smalltalk.HLRenameClassCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "displayLabel",

+ 13 - 0
js/Helios-Commands-Core.deploy.js

@@ -136,6 +136,19 @@ return $1;
 messageSends: ["label"]}),
 smalltalk.HLCommand);
 
+smalltalk.addMethod(
+smalltalk.method({
+selector: "isAction",
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+var $1;
+$1=_st(_st(self)._isBindingGroup())._not();
+return $1;
+}, function($ctx1) {$ctx1.fill(self,"isAction",{},smalltalk.HLCommand)})},
+messageSends: ["not", "isBindingGroup"]}),
+smalltalk.HLCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "isActive",

+ 18 - 0
js/Helios-Commands-Core.js

@@ -186,6 +186,24 @@ referencedClasses: []
 }),
 smalltalk.HLCommand);
 
+smalltalk.addMethod(
+smalltalk.method({
+selector: "isAction",
+category: 'testing',
+fn: function (){
+var self=this;
+return smalltalk.withContext(function($ctx1) { 
+var $1;
+$1=_st(_st(self)._isBindingGroup())._not();
+return $1;
+}, function($ctx1) {$ctx1.fill(self,"isAction",{},smalltalk.HLCommand)})},
+args: [],
+source: "isAction\x0a\x09^ self isBindingGroup not",
+messageSends: ["not", "isBindingGroup"],
+referencedClasses: []
+}),
+smalltalk.HLCommand);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "isActive",

+ 11 - 7
st/Helios-Browser.st

@@ -119,6 +119,10 @@ HLNavigationListWidget subclass: #HLBrowserListWidget
 
 !HLBrowserListWidget methodsFor: 'accessing'!
 
+commandCategory
+	^ self label
+!
+
 label
 	^ 'List'
 !
@@ -127,8 +131,10 @@ menuCommands
 	"Answer a collection of commands to be put in the cog menu"
 	
 	^ (HLBrowserCommand concreteClasses 
-		select: [ :each | each isValidFor: self selectedItem ])
-		collect: [ :each | each for: self model ]
+		collect: [ :each | each for: self model ])
+		select: [ :each | 
+			each category = self commandCategory and: [ 
+				each isAction and: [ each isActive ] ] ]
 !
 
 model
@@ -601,11 +607,9 @@ onMethodSelected: aMethod
 		ifTrue: [ aMethod selector ]
 		ifFalse: [ nil ].
 		
-	self selectedItem: selector.
-	
-	selector ifNil: [ ^ self ].
-    
-	self activateItem: selector
+	self 
+		selectedItem: selector;
+		activateItem: selector
 !
 
 onMethodsFocusRequested

+ 42 - 0
st/Helios-Commands-Browser.st

@@ -3,6 +3,12 @@ HLModelCommand subclass: #HLBrowserCommand
 	instanceVariableNames: ''
 	package: 'Helios-Commands-Browser'!
 
+!HLBrowserCommand methodsFor: 'accessing'!
+
+category
+	^ nil
+! !
+
 !HLBrowserCommand class methodsFor: 'instance creation'!
 
 for: aBrowserModel
@@ -129,6 +135,12 @@ HLBrowserCommand subclass: #HLCommitPackageCommand
 	instanceVariableNames: ''
 	package: 'Helios-Commands-Browser'!
 
+!HLCommitPackageCommand methodsFor: 'accessing'!
+
+category
+	^ 'Packages'
+! !
+
 !HLCommitPackageCommand methodsFor: 'executing'!
 
 execute
@@ -178,6 +190,10 @@ HLCopyCommand subclass: #HLCopyClassCommand
 
 !HLCopyClassCommand methodsFor: 'accessing'!
 
+category
+	^ 'Classes'
+!
+
 displayLabel
 	^ 'New class name:'
 ! !
@@ -312,6 +328,10 @@ HLMoveClassToCommand subclass: #HLMoveClassToPackageCommand
 
 !HLMoveClassToPackageCommand methodsFor: 'accessing'!
 
+category
+	^ 'Classes'
+!
+
 displayLabel
 	^ 'select a package'
 !
@@ -360,6 +380,12 @@ HLMoveToCommand subclass: #HLMoveMethodToCommand
 	instanceVariableNames: ''
 	package: 'Helios-Commands-Browser'!
 
+!HLMoveMethodToCommand methodsFor: 'accessing'!
+
+category
+	^ 'Methods'
+! !
+
 !HLMoveMethodToCommand methodsFor: 'testing'!
 
 isActive
@@ -494,6 +520,12 @@ HLRemoveCommand subclass: #HLRemoveClassCommand
 	instanceVariableNames: ''
 	package: 'Helios-Commands-Browser'!
 
+!HLRemoveClassCommand methodsFor: 'accessing'!
+
+category
+	^ 'Classes'
+! !
+
 !HLRemoveClassCommand methodsFor: 'executing'!
 
 execute
@@ -530,6 +562,12 @@ HLRemoveCommand subclass: #HLRemoveMethodCommand
 	instanceVariableNames: ''
 	package: 'Helios-Commands-Browser'!
 
+!HLRemoveMethodCommand methodsFor: 'accessing'!
+
+category
+	^ 'Methods'
+! !
+
 !HLRemoveMethodCommand methodsFor: 'executing'!
 
 execute
@@ -582,6 +620,10 @@ HLRenameCommand subclass: #HLRenameClassCommand
 
 !HLRenameClassCommand methodsFor: 'accessing'!
 
+category
+	^ 'Classes'
+!
+
 displayLabel
 	^ 'Rename class to:'
 ! !

+ 4 - 0
st/Helios-Commands-Core.st

@@ -80,6 +80,10 @@ registerOn: aBinding
 
 !HLCommand methodsFor: 'testing'!
 
+isAction
+	^ self isBindingGroup not
+!
+
 isActive
 	^ true
 !