This commit is contained in:
Bane Stojkovic
2025-03-16 22:36:24 +01:00
parent 1c48d7c31f
commit 896a623c7c
4 changed files with 11 additions and 30 deletions
@@ -28,7 +28,7 @@ import java.awt.*;
*
* @author Branislav Stojkovic
*/
public interface ISwitch {
public interface ISwitch extends IContinuity {
Color[] POLE_COLORS = new Color[] {
Color.decode("#FFD1DC"), // Pastel Pink
@@ -74,4 +74,11 @@ public interface ISwitch {
default Boolean getHighlightConnectedTerminals() {
return false;
}
default boolean arePointsConnected(int index1, int index2) {
if (getSelectedPosition() == null) {
return false;
}
return arePointsConnected(index1, index2, getSelectedPosition());
}
}