+ // @formatter:off
+ public void addComponentChangedListener (Consumer<GUIComponent> listener) {componentChangedListeners.add (listener);}
+ public void addComponentMovedListener (Consumer<GUIComponent> listener) {componentMovedListeners .add (listener);}
+ public void addPinAddedListener (Consumer<Pin > listener) {pinAddedListeners .add (listener);}
+ public void addPinRemovedListener (Consumer<Pin > listener) {pinRemovedListeners .add (listener);}
+
+ public void removeComponentChangedListener(Consumer<GUIComponent> listener) {componentChangedListeners.remove(listener);}
+ public void removeComponentMovedListener (Consumer<GUIComponent> listener) {componentMovedListeners .remove(listener);}
+ public void removePinAddedListener (Consumer<Pin > listener) {pinAddedListeners .remove(listener);}
+ public void removePinRemovedListener (Consumer<Pin > listener) {pinRemovedListeners .remove(listener);}
+
+ private void callComponentChangedListeners( ) {componentChangedListeners.forEach(l -> l.accept(this));}
+ private void callComponentMovedListeners ( ) {componentMovedListeners .forEach(l -> l.accept(this));}
+ private void callPinAddedListeners (Pin p) {pinAddedListeners .forEach(l -> l.accept(p ));}
+ private void callPinRemovedListeners (Pin p) {pinRemovedListeners .forEach(l -> l.accept(p ));}
+ // @formatter:on
+