Hi Pete,
The variable gRevStackStatus["Short name of a stack"] is set to true
whenever a control moves or changes as the result of user input.
Messages triggering an update or gRevStackStatus are openField and
focusIn for example. I think that moveControl and resizeControl are
monitored too. I haven't checked which messages are monitored, for a
long time.
Whenever you bring a stack with a field to the front, the IDE finds the
first field that has the lockText set to false and the traversalOn set
to true. This field gets focus and gRevStackStatus is set to edited.
Whenever you try to close a stack, or quit the IDE, LiveCode briefly
sets the focus to each of the stacks that is currently visible. The
first field gets the focus and thus the gRevStackStatus is set to true
--if it has a field.
In other words, the IDE sets gRevStackStatus to true for any stack with
a field, before you close it, and you will always see a Save dialog for
these stacks.
If you want to prevent this from happening, you will need to write your
own frontscript that handles the closeStackRequest, shutDownRequest and
appleEvent messages.
--
Best regards,
Mark Schonewille
Economy-x-Talk Consulting and Software Engineering
Homepage: http://economy-x-talk.com
Twitter: http://twitter.com/xtalkprogrammer
KvK: 50277553
Installer Maker for LiveCode:
http://qery.us/468
Buy my new book "Programming LiveCode for the Real Beginner"
http://qery.us/3fi
LiveCode on Facebook:
https://www.facebook.com/groups/runrev/
On 4/8/2015 18:33, Peter Haworth wrote:
After several years of using Livecode, I still don't understand how the IDE
decides when a stack needs to be saved when I quit from it.
As an example, if I delete a substack by script then quit, the stack isn't
saved. If I change the vale of a custom property by script then quit, the
stack isn't saved. Same thing happens if I add a new substack by script.
And if I change the value of a custom property by script.
Surely the IDE should be aware that a save is needed in those
circumstances?
Pete
_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode