December 7th, 2006
Those of us who are Director and Lingo savvy (generally) love the message window. For those of you who aren’t Director savvy, the message window allowed an author to run methods and view results during runtime. Though the Flash IDE doesn’t offer one, you can make your own (if you haven’t already). Its incredibly useful for debugging your code especially if you’re into using the singleton model.
I’ve prepared a basic command input and output example which (slightly) mimics Director’s message window. Since it is meant to overlay your site or application, pressing spacebar will toggle the whole thing’s visibility. Another key might be more suitable, since some method parameters might include spaces. Currently the only parameter types supported are non-object, non-arrays. A limit of 4 parameters also exists though its not entirely necessary.
Instructions and notes are commented within the class.
Download the debugger source
I’d love to see a more complete execution of a message window if someone has already gone through the trouble to make one.