I couldn't get it to run either the first dozen times. For some inexplicable reason after a few rounds of getting rid of the old .class files and retyping parts of the code that weren't being executed and rebuilding, it started to work. I then had a similar problem with responding to the MouseEvent. Several (clean, retype and recompile)s later it started to work. I didn't find any bugs or typos it just started working. Managed to get all the way though it but I am slightly balder now because of it.
I really hope this is stab it the dark method is not typical of Java development. What kind of tools are there for debugging? There would obviously be something that comes with an IDE so using a generic text editor can be a problem, but there must be some cli tools.