|
From: <de...@us...> - 2004-01-21 11:02:22
|
Update of /cvsroot/fudaa/fudaa_devel/ebli/src/org/fudaa/ebli/commun
In directory sc8-pr-cvs1:/tmp/cvs-serv15000/commun
Modified Files:
EbliListeSelectionMulti.java
Log Message:
Maj general
Index: EbliListeSelectionMulti.java
===================================================================
RCS file: /cvsroot/fudaa/fudaa_devel/ebli/src/org/fudaa/ebli/commun/EbliListeSelectionMulti.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** EbliListeSelectionMulti.java 11 Dec 2003 12:41:52 -0000 1.5
--- EbliListeSelectionMulti.java 21 Jan 2004 11:02:18 -0000 1.6
***************
*** 71,82 ****
int idx= it.key();
EbliListeSelection e= (EbliListeSelection)it.value();
! if (e == null) {
! e= new EbliListeSelection();
! idxListSelection_.put(idx, e);
! }
! r |= e.xor((EbliListeSelection)it.value());
! if (e.isEmpty()) {
! idxListSelection_.remove(idx);
! r= true;
}
}
--- 71,88 ----
int idx= it.key();
EbliListeSelection e= (EbliListeSelection)it.value();
! if (!e.isEmpty()) {
! EbliListeSelection thisSelection= get(idx);
! if (thisSelection == null) {
! thisSelection= new EbliListeSelection(e);
! idxListSelection_.put(idx, e);
! r= true;
! } else {
! if (thisSelection.xor((EbliListeSelection)it.value())) {
! r= true;
! if (thisSelection.isEmpty()) {
! idxListSelection_.remove(idx);
! }
! }
! }
}
}
***************
*** 93,105 ****
int idx= it.key();
EbliListeSelection e= (EbliListeSelection)it.value();
! if (e == null) {
! e= new EbliListeSelection();
! idxListSelection_.put(idx, e);
}
- r |= e.add((EbliListeSelection)it.value());
}
return r;
}
!
/**
* Return the total number of selected index.
--- 99,115 ----
int idx= it.key();
EbliListeSelection e= (EbliListeSelection)it.value();
! if (!e.isEmpty()) {
! EbliListeSelection thisSelection= get(idx);
! if (thisSelection == null) {
! thisSelection= new EbliListeSelection(e);
! idxListSelection_.put(idx, thisSelection);
! r= true;
! } else
! r |= thisSelection.add(e);
}
}
return r;
}
!
/**
* Return the total number of selected index.
***************
*** 123,131 ****
it.advance();
int idx= it.key();
! EbliListeSelection e= (EbliListeSelection)it.value();
! if (e != null) {
! r |= e.remove((EbliListeSelection)it.value());
! if (e.isEmpty())
! idxListSelection_.remove(idx);
}
}
--- 133,145 ----
it.advance();
int idx= it.key();
! EbliListeSelection thisSelection= get(idx);
! if (thisSelection != null) {
! if (thisSelection.remove((EbliListeSelection)it.value())) {
! r= true;
! if (thisSelection.isEmpty())
! idxListSelection_.remove(idx);
!
! }
!
}
}
***************
*** 139,145 ****
for (int i= _m.idxListSelection_.size(); i-- > 0;) {
it.advance();
! idxListSelection_.put(
! it.key(),
! new EbliListeSelection((EbliListeSelection)it.value()));
}
return true;
--- 153,162 ----
for (int i= _m.idxListSelection_.size(); i-- > 0;) {
it.advance();
! EbliListeSelection newS=
! new EbliListeSelection((EbliListeSelection)it.value());
! if (!newS.isEmpty()) {
! idxListSelection_.put(it.key(), newS);
! }
!
}
return true;
|