~yrke/tapaal/removeNetType

« back to all changes in this revision

Viewing changes to src/pipe/gui/graphicElements/Arc.java

MergedĀ lp:~yrke/tapaal/testbranch-syntaxOnlyChanges

Show diffs side-by-side

added added

removed removed

Lines of Context:
13
13
import pipe.gui.Grid;
14
14
import pipe.gui.Pipe;
15
15
import pipe.gui.Zoomer;
16
 
import pipe.gui.handler.LabelHandler;
17
16
import dk.aau.cs.model.tapn.Weight;
18
17
import pipe.gui.handler.PlaceTransitionObjectHandler;
19
18
 
22
21
 */
23
22
public abstract class Arc extends PetriNetObjectWithLabel {
24
23
 
25
 
        private static final long serialVersionUID = 6527845538091358791L;
26
 
 
27
24
        private Shape head = null;
28
25
        private boolean fillHead = true; //If true, fill the shape when drawing, if false, fill with bg color.
29
26
 
50
47
        // Bounds of arc need to be grown in order to avoid clipping problems
51
48
        protected int zoomGrow = 10;
52
49
 
53
 
        private Arc(int nameOffsetX, int nameOffsetY) {
54
 
            super(nameOffsetX, nameOffsetY);
 
50
        private Arc() {
 
51
            super(0, 0);
55
52
 
56
53
        setHead();
57
54
    }
63
60
        public Arc(
64
61
                        PlaceTransitionObject sourceInput,
65
62
                        PlaceTransitionObject targetInput, int weightInput, String idInput) {
66
 
                this(0,0);
 
63
                this();
67
64
 
68
65
                id = idInput;
69
66
                setSource(sourceInput);
76
73
         * Create Petri-Net Arc object
77
74
         */
78
75
        public Arc(PlaceTransitionObject newSource) {
79
 
                this(0,0);
 
76
                this();
80
77
                isPrototype = true;
81
78
 
82
79
                setSource(newSource);
389
386
                this.getActionMap().clear();
390
387
        }
391
388
 
392
 
        private class DeleteAction extends AbstractAction {
 
389
        private static class DeleteAction extends AbstractAction {
393
390
                Arc arcBeingDraw;
394
391
 
395
392
                DeleteAction(Arc arc) {