ResumeStack message... bug?
klaus at major-k.de
Tue Nov 13 12:57:48 EST 2007
Hi Jaqueline, hi Mark,
> On Nov 12, 2007, at 8:00 PM, J. Landman Gay wrote:
>> Mark Swindell wrote:
>>> At the stack level of each of the sub stacks place this script:
>>> on resumeStack
>>> go stack "AAA"
>>> put "hello"&return after field 1 end resumeStack
>>> Now, toggle back and forth, slowly, between the two substack
>>> windows so that each alternately comes to the front.
>>> What I experience (and another list member confirmed) is this:
>>> On the first two toggles a resumestack message is sent and
>>> "hello" appears in field 1 of stack "AAA".
>>> On the next two toggles a resumeStack message appears NOT to be
>>> sent and no "hello" appears.
>>> Then two more "hellos"
>>> Then two "no hellos."
>> I can't quite work out the repercussions entirely, but I think the
>> problem may be due to nested resumeStack messages. The script is
>> opening another stack during its own resumeStack handler, which
>> will trigger the same message in the newly-opened stack. Since that
>> one also has a resumeStack handler with a "go" in it, I think you
>> are getting some kind of recursion as the two bounce back and forth.
> Thank you for the suggestion.
> There is no go command in the stack that is being visited, only in
> the two substacks that call the visit to the third (the main
> stack). But yes, it seems there could be some kind of
> recursion. I just don't know why or where, or why it only happens
> alternately, and then functions as it should.
>> Try locking messages before issuing the "go" command to see if that
> Unfortunately lock messages has no effect. ????
I have the feeling that "resume-/suspendstack" is not send reliably.
I have routines that change the menus/menubarbar(s) of my stacks
dynamically (maybe you remember my problem, Jaque)
and sometimes this simply does not work, but I still did not find any
recipe/legality for this phenomenon.
klaus at major-k.de
More information about the Use-livecode