What message come from "quit"

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am

What message come from "quit"

Post by Simon » Sat Jun 14, 2014 12:39 am

Hello everyone,
I'd like to know what messages follow closeCard during a quit. I need to process some final information.
We've got:
closeCard
shutDown
closeStack
closeStackRequest
probably others. I guess I want the order these messages (others) come in.
I caught a glimpse of closeStack but I'm guessing it's no place for a post command (I'm posting data) as the data never got posted.

Thanks for info.
Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Re: What message come from "quit"

Post by Mark » Sat Jun 14, 2014 11:18 pm

Hi Simon,

Have you tried shutDownRequest already?

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am

Re: What message come from "quit"

Post by Simon » Sun Jun 15, 2014 2:05 am

Hi Mark,
Thanks, I'll try that.
But now I'm interested in that actual order of messages after "quit". As I just found out (I Think) that preOpenCard may come before preOpenStack(?).
Wait...Am I crazy to think that the message path is Always active? If I have a button with "on preOpenStack answer "HELLO"" it will trigger before a card or stack script that says "on preOpenStack answer "Im a stack script""?

Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 4172
Joined: Sun Jan 07, 2007 9:12 pm

Re: What message come from "quit"

Post by bn » Sun Jun 15, 2014 2:28 pm

Hi Simon,

From what I see in the message watcher it is:
preOpentStack
preOpenCard
openStack
openCard

And the receiver is the actual card and from there on the message passes through the message hierarchy.
If I have a button with "on preOpenStack answer "HELLO"" it will trigger before a card or stack script that says "on preOpenStack answer "Im a stack script""?
the button is not in the message path and it would not get "preOpenStack". When you press a button it starts a message path where the first receiver is the button and then on. (Not considering a front script)

Kind regards
Bernd

[-hh]
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2262
Joined: Thu Feb 28, 2013 11:52 pm

Re: What message come from "quit"

Post by [-hh] » Sun Jun 15, 2014 3:34 pm

..........
Last edited by [-hh] on Wed Aug 13, 2014 2:19 pm, edited 1 time in total.
shiftLock happens

Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am

Re: What message come from "quit"

Post by Simon » Sun Jun 15, 2014 9:10 pm

Wow Hermann,
shutdownRequest Card 1402861353474
shutdownRequest Stack 1402861353477
shutDown Card 1402861353479
closeCard Card 1402861353479
closeStack Card 1402861353479
focusOut Card 1402861353480
Note the shutdownRequest Stack only works when using "quit" not the titlebar "X".

Now this was a very brute method of tracking messages, I couldn't figure out a way to record the messages watcher. Is there a way?

Thanks both of you.

Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10052
Joined: Sat Apr 08, 2006 7:05 am
Contact:

Re: What message come from "quit"

Post by FourthWorld » Sun Jun 15, 2014 9:40 pm

4W Flight Recorder (available through RevNet) offers more flexible options for tracking messages than the Message Watcher, with a more readable display.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am

Re: What message come from "quit"

Post by Simon » Sun Jun 15, 2014 9:49 pm

Hi Richard,
When is RevNet going to return? It's still the Special Edition.

Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10052
Joined: Sat Apr 08, 2006 7:05 am
Contact:

Re: What message come from "quit"

Post by FourthWorld » Sun Jun 15, 2014 9:58 pm

Oops, my bad- yes, I need to post the new one ASAP (no one else had noticed and with my client work is just forgotten).

I'm the meantime, here's the direct link to that and more:
http://fourthworld.net/revnet/devolution/
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

[-hh]
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2262
Joined: Thu Feb 28, 2013 11:52 pm

Re: What message come from "quit"

Post by [-hh] » Sun Jun 15, 2014 11:05 pm

..........
Last edited by [-hh] on Wed Aug 13, 2014 2:18 pm, edited 1 time in total.
shiftLock happens

Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am

Re: What message come from "quit"

Post by Simon » Sun Jun 15, 2014 11:25 pm

Hi Hermann,
Yeah, that's is just about the way I did it.
I think I have my answer now. closeStack comes after closeCard but doesn't like to do anything. Maybe I had it set up wrong.

Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!

[-hh]
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2262
Joined: Thu Feb 28, 2013 11:52 pm

Re: What message come from "quit"

Post by [-hh] » Mon Jun 16, 2014 12:02 am

..........
Last edited by [-hh] on Wed Aug 13, 2014 2:18 pm, edited 1 time in total.
shiftLock happens

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7393
Joined: Sat Apr 08, 2006 8:31 pm
Contact:

Re: What message come from "quit"

Post by jacque » Mon Jun 16, 2014 4:53 pm

With very few exceptions, almost all engine messages are sent to the current card.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

[-hh]
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2262
Joined: Thu Feb 28, 2013 11:52 pm

Re: What message come from "quit"

Post by [-hh] » Mon Jun 16, 2014 8:52 pm

..........
Last edited by [-hh] on Wed Aug 13, 2014 2:18 pm, edited 1 time in total.
shiftLock happens

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7393
Joined: Sat Apr 08, 2006 8:31 pm
Contact:

Re: What message come from "quit"

Post by jacque » Tue Jun 17, 2014 4:45 pm

All messages sent to the card will traverse the message hierarchy until they are intercepted. That includes all the pre- and open- messages.

The only messages I can think of offhand that don't go to the card are callback messages which are sent to a player control. (A script needs to set this up specifically.) It's noted in the dictionary. There may be others I can't think of right now, and that's why I was vague about it. ☺
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

Post Reply