Re: bug or feature?
Re: bug or feature?
- Subject: Re: bug or feature?
- From: Jon Pugh <email@hidden>
- Date: Wed, 17 Oct 2001 20:47:51 -0700
At 9:07 PM -0600 10/17/2001, Donald S. Hall wrote:
>
I was under the impression that global variables were not persistent from run to run, only properties were.
You were wrong.
>
I was surprised to discover that global variables seem in fact to also be persistent.
Now you are enlightened.
>
I wanted to use the fact that 'x' was undefined to determine if my applet was already running when its open handler was invoked by drag and drop.
You can detect if you were launched without a d&d in the run handler. The open handler will be called directly if you are launched with a d&d. You can uninitialize your variable in the quit handler for the next launch. You can tell when you are double clicked while running with the reopen handler.
I don't know why you would care, so I can't be more precise about a technique to use.
Jon