public synchronized void remove(Class t,EventListener l){
  if (!t.isInstance(l)) {
    throw new IllegalArgumentException("Listener " + l + " is not of type "+ t);
  }
  if (l == null) {
    throw new IllegalArgumentException("Listener " + l + " is null");
  }
  int index=-1;
  for (int i=listenerList.length - 2; i >= 0; i-=2) {
    if ((listenerList[i] == t) && (listenerList[i + 1] == l)) {
      index=i;
      break;
    }
  }
  if (index != -1) {
    Object[] tmp=new Object[listenerList.length - 2];
    System.arraycopy(listenerList,0,tmp,0,index);
    if (index < tmp.length)     System.arraycopy(listenerList,index + 2,tmp,index,tmp.length - index);
    listenerList=(tmp.length == 0) ? NULL_ARRAY : tmp;
  }
}

public synchronized void remove ( Class t , EventListener l ) { if ( ! t . isInstance ( l ) ) { throw new IllegalArgumentException ( "Listener " + l + " is not of type " + t ) ; } if ( l == null ) { throw new IllegalArgumentException ( "Listener " + l + " is null" ) ; } int index = - 1 ; for ( int i = listenerList . length - 2 ; i >= 0 ; i -= 2 ) { if ( ( listenerList [ i ] == t ) && ( listenerList [ i + 1 ] == l ) ) { index = i ; break ; } } if ( index != - 1 ) { Object [ ] tmp = new Object [ listenerList . length - 2 ] ; System . arraycopy ( listenerList , 0 , tmp , 0 , index ) ; if ( index < tmp . length ) System . arraycopy ( listenerList , index + 2 , tmp , index , tmp . length - index ) ; listenerList = ( tmp . length == 0 ) ? NULL_ARRAY : tmp ; } }
remove the listener as a listener of the specified type .
