* Updates the widgets of the instrument.
* @param executedAction The action currently executed. Can be null.
* @since 3.0
*/
protected void updateWidgets(final Action executedAction) {
final SelectShapes sa = ActionsRegistry.INSTANCE.getAction(SelectShapes.class);
final boolean validSelectAction = sa!=null && !sa.shapes().isEmpty();
copyMenu.setEnabled(activated && validSelectAction);
cutMenu.setEnabled(activated && copyMenu.isEnabled());
pasteMenu.setEnabled(activated && (executedAction instanceof CopyShapes ||
ActionsRegistry.INSTANCE.getAction(CopyShapes.class)!=null || ActionsRegistry.INSTANCE.getAction(CutShapes.class)!=null));