X-Git-Url: https://mograsim.net/gitweb/?a=blobdiff_plain;f=LogicUI%2Fsrc%2Fera%2Fmi%2Fgui%2Fcomponents%2FBasicGUIComponent.java;fp=LogicUI%2Fsrc%2Fera%2Fmi%2Fgui%2Fcomponents%2FBasicGUIComponent.java;h=fa753e18499172733f1377a490bf4efb9b42718a;hb=873c7cd58e0a035e68b5af352260da9f4d667c96;hp=29696e13914c47976a1366436bb620722f1c7f8c;hpb=340eb95b6ab64f2c1a784d1dc36002537b1cbd15;p=Mograsim.git diff --git a/LogicUI/src/era/mi/gui/components/BasicGUIComponent.java b/LogicUI/src/era/mi/gui/components/BasicGUIComponent.java index 29696e13..fa753e18 100644 --- a/LogicUI/src/era/mi/gui/components/BasicGUIComponent.java +++ b/LogicUI/src/era/mi/gui/components/BasicGUIComponent.java @@ -11,30 +11,32 @@ public interface BasicGUIComponent * Render this component to the given gc, at coordinates (0, 0). */ public void render(GeneralGC gc); + /** - * Returns the bounds of this component. - * Used for calculating which component is clicked. + * Returns the bounds of this component. Used for calculating which component is clicked. */ public Rectangle getBounds(); + /** - * Called when this component is clicked. Relative coordinates of the click are given. - * Returns true if this component has to be redrawn. + * Called when this component is clicked. Relative coordinates of the click are given. Returns true if this component has to be redrawn. */ public default boolean clicked(double x, double y) { return false; } - //TODO this code will be replaced by code in BasicComponent. + // TODO this code will be replaced by code in BasicComponent. /** - * Returns how many wire arrays are connected to this component. - * (Connections are static - they can't be removed and no new ones can be added) + * Returns how many wire arrays are connected to this component. (Connections are static - they can't be removed and no new ones can be + * added) */ public int getConnectedWireArraysCount(); + /** * Returns the n-th wire array connected to this component. */ public WireArray getConnectedWireArray(int connectionIndex); + /** * Returns relative coordinates where the n-th wire array is connected to this component. */