Page 1 of 1

Clarify use of "add preopenCard code to card script"?

Posted: Tue Aug 20, 2013 9:41 pm
by cavenewt
I just watched the doc video on tab bars and buttons. It is almost identical to the buttons we made for our summer school stack. However, that presenter never did check the box in mobGUI for "add preopenCard code to card script" and his stock ran in the Simulator just fine. Is this because we are using a mouse in the Simulator and not actually touching the buttons?

My own copy of the summer school stack only has the preopenCard handler (seven lines of code) in the script for the Contacts card. Are we supposed to add that code to every card, or is it sufficient to be just on one card?

Just as an aside, the mobGUI substack appears to be added to the project browser when you drag any mobGUI control onto your stack. It is not added by the pre-opencard checkbox.

Re: Clarify use of "add preopenCard code to card script"?

Posted: Wed Aug 21, 2013 4:36 am
by Pip
With the "add preOpenCard code to card script" in mobGUI, does this just need to be clicked once when you first use mobGUI or does it need clicking every time you change something in mobGUI?