Upgraded to java 7, got a new problem:
java 7 introduced the URLConnection.getContentLengthLong() method, which i want to use (for those wonderful 2gb+ downloads)
Anyway, the problem is that jprogressbar and all the ancillary classes is only prepared to accept ints. This is not so critical considering it’s almost all view classes (taking care to be careful around the edges since we don’t want it to look “not started” or “done” when it’s not) - but the long needs to be compressed into a int
I was thinking of something like:
0L is int 0
1L … (totalL -1L) is int mapping(1L) … mapping(totalL -1L) where some number of contiguous mappings give the same int value
totalL is int mapping(total) that is unique (to make JProgressBar look full only at the end)
I’m terrible at maths. Help?