Skip to content
Snippets Groups Projects
Commit 4bdc56e1 authored by Florian Hölzl's avatar Florian Hölzl
Browse files

fixed

refs 479
parent 30daa189
No related branches found
No related tags found
No related merge requests found
......@@ -44,7 +44,7 @@ import org.fortiss.tooling.kernel.ui.util.EObjectSelectionUtils;
* @author hoelzlf
* @author $Author$
* @version $Rev$
* @ConQAT.Rating GREEN Hash: AD3510F022C7F60F7224DB8647BF804E
* @ConQAT.Rating GREEN Hash: 3C35B6E429C4125AC1BFBE642B13A3AC
*/
public class ActionService implements IActionService,
IPersistencyServiceListener, CommandStackListener {
......@@ -117,10 +117,23 @@ public class ActionService implements IActionService,
/** {@inheritDoc} */
@Override
public void registerGlobalActions(IActionBars actionBars) {
registerGlobalEditingActions(actionBars);
registerGlobalUndoRedoActions(actionBars);
actionBars.updateActionBars();
}
/** Registers the global unde/redo action with the given action bar. */
@Override
public void registerGlobalUndoRedoActions(IActionBars actionBars) {
registerGlobalAction(globalUndoAction, ActionFactory.UNDO.getId(),
ActionFactory.UNDO.getCommandId(), actionBars);
registerGlobalAction(globalRedoAction, ActionFactory.REDO.getId(),
ActionFactory.REDO.getCommandId(), actionBars);
}
/** Registers the global editing action with the given action bar. */
@Override
public void registerGlobalEditingActions(IActionBars actionBars) {
registerGlobalAction(globalCopyAction, ActionFactory.COPY.getId(),
ActionFactory.COPY.getCommandId(), actionBars);
registerGlobalAction(globalCutAction, ActionFactory.CUT.getId(),
......@@ -129,8 +142,6 @@ public class ActionService implements IActionService,
ActionFactory.PASTE.getCommandId(), actionBars);
registerGlobalAction(globalDeleteAction, ActionFactory.DELETE.getId(),
ActionFactory.DELETE.getCommandId(), actionBars);
actionBars.updateActionBars();
}
/** Registers the given action globally. */
......
......@@ -28,16 +28,24 @@ import org.fortiss.tooling.kernel.ui.internal.ActionService;
* @author hoelzl
* @author $Author$
* @version $Rev$
* @ConQAT.Rating GREEN Hash: 1A74804C1159AF1F6F0C09FCE5ACB010
* @ConQAT.Rating GREEN Hash: B12A8EF1D028E82503F0BF59DBAF9398
*/
public interface IActionService {
/** Returns the singleton instance of the service. */
public static final IActionService INSTANCE = new ActionService();
/** Registers global actions with the given {@link IActionBars}. */
/** Registers all global actions with the given {@link IActionBars}. */
void registerGlobalActions(IActionBars actionBars);
/**
* Registers the global unde/redo action with the given {@link IActionBars}.
*/
public void registerGlobalUndoRedoActions(IActionBars actionBars);
/** Registers the global editing action with the given {@link IActionBars}. */
public void registerGlobalEditingActions(IActionBars actionBars);
/**
* Adds the global default actions to the given context menu. Currently the
* default are the editing actions as provided by #
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment