]> gerrit.simantics Code Review - simantics/district.git/blob
e8b8337b72845aed2b75fa119b34c7483c0c9818
[simantics/district.git] /
1 package org.simantics.district.network.ui.participants;\r
2 \r
3 import java.awt.geom.Point2D;\r
4 import java.util.Set;\r
5 \r
6 import org.simantics.g2d.canvas.ICanvasParticipant;\r
7 import org.simantics.g2d.diagram.participant.pointertool.PointerInteractor;\r
8 import org.simantics.g2d.diagram.participant.pointertool.TerminalUtil.TerminalInfo;\r
9 import org.simantics.g2d.element.IElement;\r
10 \r
11 public class DNPointerInteractor extends PointerInteractor {\r
12 \r
13     @Override\r
14     protected ICanvasParticipant createConnectTool(TerminalInfo ti, int mouseId, Point2D startCanvasPos) {\r
15         return super.createConnectTool(ti, mouseId, startCanvasPos);\r
16     }\r
17     \r
18     @Override\r
19     protected ICanvasParticipant createTranslateTool(int mouseId, Point2D startCanvasPos, Point2D curCanvasPos, Set<IElement> elementsToDrag) {\r
20         return new DNTranslateMode(startCanvasPos, curCanvasPos, mouseId, elementsToDrag);\r
21     }\r
22 }\r