Design patterns
Posted: Thu May 30, 2013 5:33 pm
Hi Folks,
I am trying to determine the best way to organize and structure my code to write an application that will work on mobile devices and the desktop. I am thinking that a good design might go as follows:
1. Use the Mainstack script to get the screen size, platform etc. on preOpenStack and set those values as global variables.
2. Use the Mainstack script to call a specific card from OpenCard, based on the values derived from step 1, above.
3. Use the Mainstack script to provide common user defined functions that can be used from the platform/design specific card layouts.
Any thoughts, tips, pointers to documentation would be greatly appreciated. I have been programming a long time with more traditional languages but am completely new to LiveCard, and quite enjoying it.
Thanks,
Daryl
I am trying to determine the best way to organize and structure my code to write an application that will work on mobile devices and the desktop. I am thinking that a good design might go as follows:
1. Use the Mainstack script to get the screen size, platform etc. on preOpenStack and set those values as global variables.
2. Use the Mainstack script to call a specific card from OpenCard, based on the values derived from step 1, above.
3. Use the Mainstack script to provide common user defined functions that can be used from the platform/design specific card layouts.
Any thoughts, tips, pointers to documentation would be greatly appreciated. I have been programming a long time with more traditional languages but am completely new to LiveCard, and quite enjoying it.
Thanks,
Daryl