Approved!

Change 20081215-hqm-6 by <mailto:[email protected]>[email protected] on 2008-12-15 17:15:15 EST
     in /Users/hqm/openlaszlo/trunk5
for <http://svn.openlaszlo.org/openlaszlo/trunk>http://svn.openlaszlo.org/openlaszlo/trunk

Summary: fix for resources in imported libraries (swf8,swf9)

New Features:

Bugs Fixed: LPP-7483, LPP-7486

Technical Reviewer: max
QA Reviewer: promanik
Doc Reviewer: (pending)

Documentation:

Release Notes:

Details:

+ In swf8, an <import> library's resources need to be compiled into
the main application,
because never figured out a way to be able to pull them from the runtime loaded swf.

The compiler thus needs to walk down (and compile) each library before it compiles the main app, so it can put any library's resources into the main app.

In swf9, we can embed resources in libraries, and we actually need to compile the main app first, so that the flex compiler can compile libraries against it in case they extend classes which are defined in the main app.

For swf9, I had set up the library compilation to queue the libraries to be compiled, so that I could compile the main app first. This change makes that code path conditional upon compiling for swf9 (as3), and for swf8 it goes back to the previous behavior of compiling the libraries first as it walks the application source DOM.

+ Also fixed: the ImportCompiler getting a null pointer to media
cache, because it
should have grabbed a copy from the main app CompilationEnvironment.


Tests:

import of resources which are compiled into <import> libs should now be working in swf8 and swf9,

test case in bug report, swf8, swf9
test/snippets/import-resource.lzx swf8,swf9 test/snippets/import-class.lzx swf8,swf9




Files:
M      WEB-INF/lps/lfc/kernel/LzLibraryCleanup.lzs
M      WEB-INF/lps/server/src/org/openlaszlo/sc/SWF9External.java
M      WEB-INF/lps/server/src/org/openlaszlo/compiler/
ImportCompiler.java
M      WEB-INF/lps/server/src/org/openlaszlo/compiler/Compiler.java



Changeset: <http://svn.openlaszlo.org/openlaszlo/patches/20081215-hqm-6.tar>http://svn.openlaszlo.org/openlaszlo/patches/20081215-hqm-6.tar

Reply via email to