Wires connected to a component now get deleted with the component
[Mograsim.git] / net.mograsim.logic.model.am2900 / src / net / mograsim / logic / model / am2900 / components / Modeldff12.java
index a3ec2f5..59aaf84 100644 (file)
@@ -24,9 +24,9 @@ public class Modeldff12 extends SimpleRectangularHardcodedModelComponent
        {
                super(model, "dff12", name, "D flip flop\n12 bits");
                setSize(40, 20);
-               addPin(new Pin(this, "D", 12, PinUsage.INPUT, 20, 20), Position.TOP);
-               addPin(new Pin(this, "C", 1, PinUsage.INPUT, 0, 10), Position.RIGHT);
-               addPin(new Pin(this, "Y", 12, PinUsage.OUTPUT, 20, 0), Position.BOTTOM);
+               addPin(new Pin(model, this, "D", 12, PinUsage.INPUT, 20, 20), Position.TOP);
+               addPin(new Pin(model, this, "C", 1, PinUsage.INPUT, 0, 10), Position.RIGHT);
+               addPin(new Pin(model, this, "Y", 12, PinUsage.OUTPUT, 20, 0), Position.BOTTOM);
        }
 
        @Override