-
Switching between scripts/class
What is the best way to swap/toggle between scripts when clicking on a button.
i have two as files - one is for a drawing tool and the other is for a writing tool. I am trying to 'switch' between the two codes when clicking on a button labeled 'Write' and another button labeled 'Draw'.
Is it possible to change the 'Document class'? I don't know if this makes sense
Any input appreciated. Thanks
-
It is not possible to change which class is the document class on the fly. Generally what you'll want to do is have a main class (document class), which instantiates both writing and drawing, and swaps them in and out of the displayList as necessary.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|