simplified callbacks and filling of WiimoteEvent objects.

git-svn-id: http://wiiusej.googlecode.com/svn/trunk@16 ae48ae66-6a45-0410-b38e-211266189506
This commit is contained in:
guilhem.duche
2008-02-06 13:26:33 +00:00
parent 2432d8f74d
commit 0dcb6993d0
3 changed files with 130 additions and 197 deletions

View File

@@ -338,32 +338,32 @@ public class WiiUseApiManager extends Thread {
}
/**
*
* @param listener
* Add WiiUseApiListener to the listeners list.
* @param listener a WiiUseApiListener
*/
public void addWiiUseApiListener(WiiUseApiListener listener) {
listeners.add(WiiUseApiListener.class, listener);
}
/**
*
* @param listener
* Remove WiiUseApiListener from the listeners list.
* @param listener a WiiUseApiListener
*/
public void removeWiiUseApiListener(WiiUseApiListener listener) {
listeners.remove(WiiUseApiListener.class, listener);
}
/**
*
* @return
* Get the list of WiiUseApiListeners.
* @return the list of WiiUseApiListeners.
*/
public WiiUseApiListener[] getWiiUseApiListeners() {
return listeners.getListeners(WiiUseApiListener.class);
}
/**
*
* @param evt
* Notify WiiUseApiListeners that an event occured.
* @param evt WiimoteEvent occured
*/
public void notifyWiiUseApiListener(WiiMoteEvent evt) {
for (WiiUseApiListener listener : getWiiUseApiListeners()) {