AFreeplaneAction action = new ExecuteScriptAction(scriptName, title, scriptPath, executionMode,
metaData.cacheContent(), metaData.getPermissions());
ResizableIcon icon = ActionUtils.getActionIcon(action);
final JCommandMenuButton scriptEntry = new JCommandMenuButton(title, icon);
scriptEntry.setActionRichTooltip(createRichTooltip(title, metaData));
scriptEntry.addActionListener(action);
scriptEntry.setFocusable(false);
scriptEntry.setEnabled(metaData.getExecutionModes().contains(executionMode));
return scriptEntry;
}