예제 #1
0
 /**
  * Handles the componentRemoved container event by invoking the componentRemoved methods on
  * listener-a and listener-b.
  *
  * @param e the component event
  */
 public void componentRemoved(ContainerEvent e) {
   ((ContainerListener) a).componentRemoved(e);
   ((ContainerListener) b).componentRemoved(e);
 }
예제 #2
0
 /**
  * Fires an items changed event.
  *
  * @param slots The slots that changed.
  */
 public void fireItemsChanged(int[] slots) {
   for (ContainerListener listener : listeners) {
     listener.itemsChanged(this, slots);
   }
 }
예제 #3
0
 /**
  * Adds a listener.
  *
  * @param listener The listener to add.
  */
 public void addListener(ContainerListener listener) {
   listeners.add(listener);
   listener.itemsChanged(this);
 }
예제 #4
0
 /** Fires an items changed event. */
 public void fireItemsChanged() {
   for (ContainerListener listener : listeners) {
     listener.itemsChanged(this);
   }
 }