Fix compile on Java 8.

The original code was causing javac to throw an AssertionError. Working
around the labelled break (by using a flag) seems to fix this fine.
Trying to minimize differences against the original code.
jai: Remove commented-out jj2000 breaks
Merge pull request #1261 from rleigh-dundee/jj2000-jdk8

jj2000: Fix compile on Java 8