Package org.springframework.richclient.command

Examples of org.springframework.richclient.command.TargetableActionCommand


    else {
      commandManager = appWindow.getCommandManager();
    }
    for (int i = 0; i < COMMANDS.length; i++) {
      if (!commandManager.containsActionCommand(COMMANDS[i])) {
        commandManager.registerCommand(new TargetableActionCommand(COMMANDS[i], null));
      }
    }
    return commandManager;
  }
View Full Code Here


    public void componentFocusGained(PageComponent component) {
        super.componentFocusGained(component);
        PageComponentContext context = component.getContext();
        for (Iterator i = window.getSharedCommands(); i.hasNext();) {
            TargetableActionCommand globalCommand = (TargetableActionCommand)i.next();
            globalCommand.setCommandExecutor(context.getLocalCommandExecutor(globalCommand.getId()));
        }
    }
View Full Code Here

     */
    public void setTargetableActionCommandExecutor(String commandId, ActionCommandExecutor executor) {
       
        Assert.required(commandId, "commandId");
       
        TargetableActionCommand command
                = (TargetableActionCommand) getCommand(commandId, TargetableActionCommand.class);
           
        if (command != null) {
            command.setCommandExecutor(executor);
        }
       
    }
View Full Code Here

        this.commandRegistry.removeCommandRegistryListener(l);
    }

    public TargetableActionCommand createTargetableActionCommand(String commandId, ActionCommandExecutor delegate) {
        Assert.notNull(commandId, "Registered targetable action commands must have an id.");
        TargetableActionCommand newCommand = new TargetableActionCommand(commandId, delegate);
        registerCommand(newCommand);
        return newCommand;
    }
View Full Code Here

TOP

Related Classes of org.springframework.richclient.command.TargetableActionCommand

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.