X-Git-Url: https://mograsim.net/gitweb/?a=blobdiff_plain;f=LogicUI%2Fsrc%2Fera%2Fmi%2Fgui%2Fmodel%2Fwires%2FWireCrossPoint.java;h=724de54bd96ce49804e56112c6a2e4869a9de759;hb=bedef06cf9b3fdd815dd8cf8925aeb159381d59d;hp=7c19c13eef953968f57972317ac7d8444de5ccb3;hpb=53db506919cb378f8f3e2584491ddbc5357ccd8c;p=Mograsim.git diff --git a/LogicUI/src/era/mi/gui/model/wires/WireCrossPoint.java b/LogicUI/src/era/mi/gui/model/wires/WireCrossPoint.java index 7c19c13e..724de54b 100644 --- a/LogicUI/src/era/mi/gui/model/wires/WireCrossPoint.java +++ b/LogicUI/src/era/mi/gui/model/wires/WireCrossPoint.java @@ -10,13 +10,17 @@ import net.haspamelodica.swt.helper.swtobjectwrappers.Rectangle; public class WireCrossPoint extends GUIComponent { + private final Pin pin; + private ReadEnd end; + private final int logicWidth; - public WireCrossPoint(ViewModel model) + public WireCrossPoint(ViewModel model, int logicWidth) { super(model); + this.logicWidth = logicWidth; setSize(0, 0); - addPin(new Pin(this, 0, 0)); + addPin(this.pin = new Pin(this, logicWidth, 0, 0)); } @Override @@ -30,4 +34,14 @@ public class WireCrossPoint extends GUIComponent this.end = end; end.addObserver((i, o) -> callComponentLookChangedListeners()); } + + public int getLogicWidth() + { + return logicWidth; + } + + public Pin getPin() + { + return pin; + } } \ No newline at end of file