The hang is a known issue in stop applet.
Plugin suspends GrayBoxPainter during appletStop(). This happens on the browser main thread. GrayBoxPainter suspendPainting() need remove the graybox panel from the panel which need acquire Awt TreeLock. While waiting to get the TreeLock, the main thread may need process windows messages sent to it. There is no message pumping during java wait for an Object monitor. That's why the deadlock happens.
To fix it, we can invokeLater the suspendPaiting() on the event dispatcher thread.