1 package org.simantics.charts.editor;
3 import org.eclipse.jface.action.Action;
4 import org.eclipse.jface.resource.ImageDescriptor;
5 import org.simantics.g2d.canvas.ICanvasContext;
6 import org.simantics.g2d.utils.CanvasUtils;
7 import org.simantics.scenegraph.g2d.events.command.Command;
10 * @author Tuukka Lehtonen
12 public class SendCommandAction extends Action {
14 private final ICanvasContext ctx;
15 private final Command command;
17 public SendCommandAction(String name, ImageDescriptor image, ICanvasContext ctx, Command command) {
20 this.command = command;
25 CanvasUtils.sendCommand(ctx, command);