1 Reply Latest reply: Sep 28, 2011 9:27 PM by EJP RSS

    JApplet's stop() not called

    882296
      Hi All,

      My JApplet's stop() method is not called from IE, Chrome or Safari when I switch tabs, but is called along with the destroy() method when I close the tab that includes the applet.

      Could you please let me know why this behavior occurs? In the tutorials, it is mentioned that stop() will be called to release resources when the user is not viewing the applet (hence when he/she switches tabs) and I need it for the applet.

      Any links or workarounds are very welcome. Thank you.

      Kind Regards,
      S. Gokhan Topcu
        • 1. Re: JApplet's stop() not called
          EJP
          In the tutorials, it is mentioned that stop() will be called to release resources when the user is not viewing the applet (hence when he/she switches tabs) and I need it for the applet.
          No, that isn't mentioned at all.

          What it actually says is this: 'When the user leaves the page, for example, to go to another page, the browser stops and destroys the applet.'

          That's not the same thing as 'when the user is not viewing the applet', by a long shot.

          In the Javadoc for stop() it says 'It is called when the Web page that contains this applet has been replaced by another page, [my emphasis] and also just before the applet is to be destroyed.'