+ It seems like showFullScreen() really wants to be a setter so it can
be invoked by canvas.setAttribute('fullscreen', ...) - just rename to
$lzc$set_fullscreen().
+ Is the canvas.displaystate property actually required? It seems
like the canvas.fullscreen attribute should provide enough information.
We need 2 attributes on canvas. one to control addition of the embedding
code (allowFullScreen=true), and another for making a method call to go
into fullscreen display state. Those are 2 different things, we just
need to choose the two names for them.
Since the embed attribute is called allowFullScreen, perhaps the canvas
attribute should be the same - actually, allowfullscreen is more
consistent with current attribute naming for the canvas, and embednew.
Then, canvas.fullscreen represents the state of the app, and
canvas.allowfullscreen represents whether it can be set or not.
+ You could move the try/catch from LZScreenKernel.as#showFullScreen()
to the canvas method. It would catch all errors this way - even for
swf8.
For SWF8 there's no error thrown, the Flash Player will just silently
ignore the change in display state. That's why I introduced a
displaystate attribute. Through that attribute it's possible to track if
the attempt to go into fullscreen mode succeeded. The displaystate
If that's the case, why not check the displaystate attribute in the
kernel, and warn if it's not set correctly? That way there's no need to
expose displaystate on the canvas.
+ It looks like you need a separate callback for
fullScreenEventHandler() because there's no guarantee the screen state
will change at the same time as showFullScreen() call. I'd suggest
delegating the event sending to a callback method on the canvas.
Also, it's probably not a good idea to leak the runtime-specific
FullScreenEvent property to the runtime through sendEvent() - please
coerce to a true/false value - the canvas.fullscreen property also
need to be set to this value.
Good points. I'll do that.
+ Your editor has inserted little bits of whitespace in various
places, making the diff a little hard to follow - not sure why!
Noticed that, I'm not sure what happened. Will take care of that with
the next version.
Thanks a lot, will send a new version out tomorrow.
Thank you - I'm looking forward to it!
--
Regards,
Max Carlson
OpenLaszlo.org