Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
View | Details | Raw Unified | Return to bug 280409 | Differences between
and this patch

Collapse All | Expand All

(-)src/org/eclipse/rap/internal/design/example/business/managers/BusinessCoolBarManager.java (-1 / +5 lines)
Lines 17-22 Link Here
17
import org.eclipse.core.commands.Command;
17
import org.eclipse.core.commands.Command;
18
import org.eclipse.core.commands.ExecutionEvent;
18
import org.eclipse.core.commands.ExecutionEvent;
19
import org.eclipse.core.commands.ExecutionException;
19
import org.eclipse.core.commands.ExecutionException;
20
import org.eclipse.core.commands.IHandler;
20
import org.eclipse.core.runtime.Assert;
21
import org.eclipse.core.runtime.Assert;
21
import org.eclipse.jface.action.Action;
22
import org.eclipse.jface.action.Action;
22
import org.eclipse.jface.action.ActionContributionItem;
23
import org.eclipse.jface.action.ActionContributionItem;
Lines 688-694 Link Here
688
        public void widgetSelected( final SelectionEvent e ) {
689
        public void widgetSelected( final SelectionEvent e ) {
689
          try {
690
          try {
690
            Command buttonCommand = ( Command ) button.getData();
691
            Command buttonCommand = ( Command ) button.getData();
691
            buttonCommand.getHandler().execute( new ExecutionEvent() );
692
            IHandler handler = buttonCommand.getHandler();
693
            if( handler != null ) {
694
              handler.execute( new ExecutionEvent() );
695
            }
692
          } catch( ExecutionException e1 ) {
696
          } catch( ExecutionException e1 ) {
693
            e1.printStackTrace();
697
            e1.printStackTrace();
694
          }
698
          }
(-)src/org/eclipse/rap/internal/design/example/business/CommandUtil.java (-1 / +5 lines)
Lines 13-18 Link Here
13
import org.eclipse.core.commands.CommandManager;
13
import org.eclipse.core.commands.CommandManager;
14
import org.eclipse.core.commands.ExecutionEvent;
14
import org.eclipse.core.commands.ExecutionEvent;
15
import org.eclipse.core.commands.ExecutionException;
15
import org.eclipse.core.commands.ExecutionException;
16
import org.eclipse.core.commands.IHandler;
16
import org.eclipse.jface.action.Action;
17
import org.eclipse.jface.action.Action;
17
import org.eclipse.jface.action.IAction;
18
import org.eclipse.jface.action.IAction;
18
import org.eclipse.jface.action.MenuManager;
19
import org.eclipse.jface.action.MenuManager;
Lines 107-113 Link Here
107
        Command command = param.getCommand();
108
        Command command = param.getCommand();
108
        if( command != null ) {
109
        if( command != null ) {
109
          try {
110
          try {
110
            command.getHandler().execute( new ExecutionEvent() );
111
            IHandler handler = command.getHandler();
112
            if( handler != null ) {
113
              handler.execute( new ExecutionEvent() );
114
            }
111
          } catch( final ExecutionException e ) {
115
          } catch( final ExecutionException e ) {
112
            e.printStackTrace();
116
            e.printStackTrace();
113
          }
117
          }

Return to bug 280409