Make toolbar paragraph/header icon active even when already
in a paragraph/header.
description = gettext('Switch to') + ' ' + createParams.to.name;
return _.extend(state, {
description = gettext('Switch to') + ' ' + createParams.to.name;
return _.extend(state, {
+ allowed: !!toSwitch || alreadyInTarget,
toggled: alreadyInTarget,
description: description,
execute: alreadyInTarget ? function() {} : function(callback) {
toggled: alreadyInTarget,
description: description,
execute: alreadyInTarget ? function() {} : function(callback) {