[jsword-svn] common/java/core/org/crosswire/common/history s
jswordcvs at crosswire.org
jswordcvs at crosswire.org
Tue Apr 5 21:07:38 MST 2005
Update of /cvs/jsword/common/java/core/org/crosswire/common/history
In directory www.crosswire.org:/tmp/cvs-serv21909/java/core/org/crosswire/common/history
Modified Files:
History.java
Log Message:
Added morphology (like strongs)
Added first pass for history.
Index: History.java
===================================================================
RCS file: /cvs/jsword/common/java/core/org/crosswire/common/history/History.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** History.java 1 Apr 2005 17:09:33 -0000 1.1
--- History.java 6 Apr 2005 04:07:36 -0000 1.2
***************
*** 46,49 ****
--- 46,50 ----
nav = new ArrayList();
history = new HashMap();
+ listeners = new EventListenerList();
}
***************
*** 59,63 ****
{
// Adjust to be 1 based
- i++;
int size = nav.size();
if (i > size)
--- 60,63 ----
***************
*** 65,71 ****
i = size;
}
! else if (i < 0)
{
! i = 0;
}
backCount = i;
--- 65,71 ----
i = size;
}
! else if (i < 1)
{
! i = 1;
}
backCount = i;
***************
*** 102,106 ****
if (backCount > 0)
{
! return Collections.unmodifiableList(nav.subList(0, backCount + 1));
}
return Collections.EMPTY_LIST;
--- 102,106 ----
if (backCount > 0)
{
! return Collections.unmodifiableList(nav.subList(0, backCount));
}
return Collections.EMPTY_LIST;
***************
*** 115,119 ****
if (backCount < nav.size())
{
! return Collections.unmodifiableList(nav.subList(backCount + 1, nav.size()));
}
return Collections.EMPTY_LIST;
--- 115,119 ----
if (backCount < nav.size())
{
! return Collections.unmodifiableList(nav.subList(backCount, nav.size()));
}
return Collections.EMPTY_LIST;
***************
*** 140,146 ****
public Object getCurrent()
{
! if (nav.size() > 0)
{
! return nav.get(backCount);
}
return null;
--- 140,146 ----
public Object getCurrent()
{
! if (nav.size() > 0 && backCount > 0)
{
! return nav.get(backCount - 1);
}
return null;
More information about the jsword-svn
mailing list