Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!olivea!uunet!van-bc!ubc-cs!alberta!arcsun.arc.ab.ca!arcsun!kenw From: kenw@skyler.arc.ab.ca (Ken Wallewein) Newsgroups: comp.sys.mac.hypercard Subject: Re: How to tell when really idle? Message-ID: Date: 26 Apr 91 16:54:52 GMT References: <1991Apr23.153901.5618@informix.com> Sender: nobody@arc.ab.ca (Absolutely Nobody) Distribution: comp.sys.mac.hypercard Organization: Alberta Research Council, Calgary Alberta, Canada Lines: 36 In-Reply-To: robertw@informix.com's message of 23 Apr 91 15:39:01 GMT In article <1991Apr23.153901.5618@informix.com> robertw@informix.com (Robert Weinberg) writes: > One of the things that's always bugged me about HyperCard is that, >although it updates most stuff to disk automatically, it won't do the same >for the current card -- at least, not doing the things I do. A person can >loose a lot of text in a hurry if you crash without saving first. I think your text will be saved to disk whenever you click out lf the field you are working in. Nope, it doesn't. > A while ago I decided to try to address that by writing an idle handler >that would detect how long HyperCard had been sitting idle, and if it was >longer than, say, five minutes, it would execute a "keep" (custom, of >course). >.... How about an idle handler that just checks the number of ticks since the last time it was invoked? Like: "if the ticks - SavedTicks > whatever, then IdleWasInterrupted; put the ticks into SavedTicks." I'd prefer not to have it try to save when I'm in the middle of doing stuff. You can figure out how long the handler takes, and determine the proper constant to let you know if something else has happened between invocations of your handler. Love to. Got any ideas how I can check if "something else has happened"? Like a somethingWasChanged message? -- /kenw Ken Wallewein A L B E R T A kenw@noah.arc.ab.ca <-- replies (if mailed) here, please R E S E A R C H (403)297-2660 C O U N C I L