1 11 package org.eclipse.debug.internal.ui.commands.actions; 12 13 import org.eclipse.debug.core.commands.IEnabledStateRequest; 14 import org.eclipse.debug.internal.core.commands.DebugCommandRequest; 15 import org.eclipse.jface.action.IAction; 16 17 24 public class UpdateActionsRequest extends DebugCommandRequest implements IEnabledStateRequest { 25 26 private IAction[] fActions; 27 private boolean fEnabled = false; 28 29 public UpdateActionsRequest(Object [] elements, IAction[] actions) { 30 super(elements); 31 fActions = actions; 32 } 33 34 37 public synchronized void setEnabled(boolean result) { 38 fEnabled = result; 39 } 40 41 44 public synchronized void done() { 45 for (int i = 0; i < fActions.length; i++) { 46 fActions[i].setEnabled(fEnabled); 47 } 48 } 49 50 } 51 | Popular Tags |