},
getState: function(params) {
var state = {
- label: this.config.label
+ label: createParams.to.name
},
f = params.fragment,
description;
toSwitch = toSwitch.getParent(createParams.from);
}
- description = 'Switch to ' + createParams.to.name;
+ description = gettext('Switch to') + ' ' + createParams.to.name;
return _.extend(state, {
- allowed: !!toSwitch,
+ allowed: !!toSwitch || alreadyInTarget,
toggled: alreadyInTarget,
description: description,
execute: alreadyInTarget ? function() {} : function(callback) {