[Laszlo-dev] dependence on ExternalInterface in swf9
Henry Minsky
hminsky at laszlosystems.com
Fri Aug 22 23:35:02 PDT 2008
I see what happened ; when Don reorganized the SWF9Generator to separate out
the application from the main sprite, the codefor the debug evaluator, which
I had wedged in there to act like a special case of an LFCApplication, got
out of sync. I'm fixing it now.
On Sat, Aug 23, 2008 at 2:25 AM, Henry Minsky <hminsky at laszlosystems.com>wrote:
>
>
> ---------- Forwarded message ----------
> From: Henry Minsky <henry.minsky at gmail.com>
> Date: Sat, Aug 23, 2008 at 2:25 AM
> Subject: Re: dependence on ExternalInterface in swf9
> To: Max Carlson <max at laszlosystems.com>
> Cc: OpenLaszlo Developers <laszlo-dev at openlaszlo.org>
>
>
> Oh foo, the "eval" feature of the debugger seems to be broken,I get this
> runtime error whenever I enter an expression to be eval'd
>
> Error #2044: Unhandled IOErrorEvent:. text=Error #2124: Loaded file is an
> unknown type.
>
>
> I better see what it is trying to compile for these expressions. Maybe
> something
>
> changed in the framework that broke the little "debug application" that
> gets
>
> compiled for each eval statement.
>
>
>
>
>
> On Sat, Aug 23, 2008 at 2:06 AM, Max Carlson <max at laszlosystems.com>wrote:
>
>> Good catch! I just noticed this myself, trying to debug ExternalInterface
>> stuff in the standalone player.
>>
>> I can't seem to get the debugger to work in the browser anymore, even with
>> <canvas debug="true">... I need the debugger working in the browser because
>> I need access to External Interface. I tried backing out your change to
>> only write messages if ($debug) {...} to no avail. Any ideas?
>>
>> Henry Minsky wrote:
>>
>>> I added a conditional on the "available" flag, which seems to work OK
>>> if (this.isroot && DojoExternalInterface.available) {
>>> // Expose your methods
>>> DojoExternalInterface.addCallback("getCanvasAttribute",
>>> lz.History, lz.History.getCanvasAttribute);
>>> DojoExternalInterface.addCallback("setCanvasAttribute",
>>> lz.History, lz.History.setCanvasAttribute);
>>> DojoExternalInterface.addCallback("callMethod", lz.History,
>>> lz.History.callMethod);
>>> DojoExternalInterface.addCallback("receiveHistory",
>>> lz.History, lz.History.receiveHistory);
>>>
>>> // Tell JavaScript that you are ready to have method calls
>>> DojoExternalInterface.loaded();
>>> }
>>>
>>> the layouts are working fine now, it must have been the error getting
>>> thrown before that messed up
>>> app initialization
>>>
>>>
>>> On Fri, Aug 22, 2008 at 11:53 PM, Henry Minsky <
>>> hminsky at laszlosystems.com <mailto:hminsky at laszlosystems.com>> wrote:
>>>
>>> When I try to debug a swf9 app from the fdb command line debugger, I
>>> get this error
>>>
>>>
>>> [Fault] exception, information=Error: Error #2067: The
>>> ExternalInterface is not available in this container.
>>> ExternalInterface requires Internet Explorer ActiveX, Firefox,
>>> Mozilla 1.7.5 and greater, or other browsers that support NPRuntime.
>>> Execution halted in 'gcursor.lzr=swf9.swf' at 0xffffffff (-1)
>>>
>>>
>>> Error: Error #2067: The ExternalInterface is not available in this
>>> container. ExternalInterface requires Internet Explorer ActiveX,
>>> Firefox, Mozilla 1.7.5 and greater, or other browsers that support
>>> NPRuntime.
>>>
>>> at Error$/throwError()
>>>
>>> at flash.external::ExternalInterface$/call()
>>>
>>> at
>>>
>>> DojoExternalInterfaceClass/addCallback()[/private/tmp/lzswf9/lzgen16038/DojoExternalInterfaceClass.as:33]
>>>
>>> at LzSprite/init()[/private/tmp/lzswf9/lzgen16038/LzSprite.as:99]
>>>
>>> at
>>>
>>> LzCanvas/__LZcallInit()[/private/tmp/lzswf9/lzgen16038/LzCanvas.as:418]
>>>
>>> at
>>>
>>> LzCanvas/__LZinstantiationDone()[/private/tmp/lzswf9/lzgen16038/LzCanvas.as:343]
>>>
>>> at
>>>
>>> LzInstantiatorService/makeSomeViews()[/private/tmp/lzswf9/lzgen16038/LzInstantiatorService.as:188]
>>>
>>> at
>>>
>>> LzInstantiatorService/checkQ()[/private/tmp/lzswf9/lzgen16038/LzInstantiatorService.as:132]
>>>
>>> at Function/http://adobe.com/AS3/2006/builtin::call()
>>>
>>> at LzEvent/sendEvent()[/private/tmp/lzswf9/lzgen16038/LzEvent.as:87]
>>>
>>> at
>>>
>>> LzIdleService/__idleupdate()[/private/tmp/lzswf9/lzgen16038/LzIdleService.as:51]
>>>
>>> at
>>>
>>> LzIdleKernel$/__update()[/private/tmp/lzswf9/lzgen16038/LzIdleKernel.as:27]
>>>
>>> at Function/http://adobe.com/AS3/2006/builtin::apply()
>>>
>>> at SetIntervalTimer/onTimer()
>>>
>>> at flash.utils::Timer/_timerDispatch()
>>>
>>> at flash.utils::Timer/tick()
>>>
>>>
>>>
>>>
>>> Is there a way we can make the calls to ExternalInterface optional,
>>> or wrap them in a try-catch, so that it is possible to debug
>>> without being in a browser? It looks like the canvas size or layout
>>> computations may depend on some callback, if I continue through that
>>> error,
>>> the canvas comes up with all the components on top of each other.
>>>
>>>
>>>
>>> -- Henry Minsky
>>> Software Architect
>>> hminsky at laszlosystems.com <mailto:hminsky at laszlosystems.com>
>>>
>>>
>>>
>>>
>>>
>>> --
>>> Henry Minsky
>>> Software Architect
>>> hminsky at laszlosystems.com <mailto:hminsky at laszlosystems.com>
>>>
>>>
>>>
>> --
>> Regards,
>> Max Carlson
>> OpenLaszlo.org
>>
>
>
>
> --
> Henry Minsky
> Software Architect
> hminsky at laszlosystems.com
>
>
>
>
>
> --
> Henry Minsky
> Software Architect
> hminsky at laszlosystems.com
>
>
>
--
Henry Minsky
Software Architect
hminsky at laszlosystems.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.openlaszlo.org/pipermail/laszlo-dev/attachments/20080822/c857c54d/attachment-0001.html
More information about the Laszlo-dev
mailing list