I'm confused too. I remember having a similar issue early on when we
were getting the LFC running in swf9, if you
had classes that were not referenced by anyone, then they didn't get
compiled into the app. The dataset tag compiles
into some script that looks like
var mydataset = canvas.lzAddLocalDataset(...);
which because it's a global gets put into it's own file
mydataset.as:
package {
public var mydataset = ....;
}
And then there's nothing traceable from the library "application" that
points to it, because the library
app main class just contains calls to define classes by putting them
into the "lz" object, but it doesn't
mention global vars anyplace.
On Wed, Nov 19, 2008 at 5:12 PM, P T Withington <[EMAIL PROTECTED]> wrote:
> Looks ok.
>
> I'm confused about the hack in the data compiler. I would think that either
> the dataset is already referenced by the program or not; in either case, it
> seems redundant to have to make this 'fake' reference. Can you explain what
> is really going on?
>
> On 2008-11-19, at 16:33EST, Henry Minsky wrote:
>
>> Change 20081119-hqm-q by [EMAIL PROTECTED] on 2008-11-19 16:23:53 EST
>> in /Users/hqm/openlaszlo/trunk4
>> for http://svn.openlaszlo.org/openlaszlo/trunk
>>
>> Summary: more fixes for swf9 <import>
>>
>> New Features:
>>
>> Bugs Fixed:
>>
>> Technical Reviewer: dda
>> QA Reviewer: ptw
>> Doc Reviewer: (pending)
>>
>> Documentation:
>>
>> Release Notes:
>>
>> Details:
>>
>> + In order prevent the LFC from getting compiled into each loadable
>> library, I added the the compiler directive -external-library-path to
>> exclude it. I needed to then explicitly include a base application
>> class so that the file would compile into a real application swf. I
>> couldn't figure out how to get my LzBaseLoadableLib class to be
>> included from the LFC after I had excluded the whole library, so I
>> just made the SWF9Writer emit a little base class which extends Sprite
>> for the library.
>>
>> I was never able to make the Flash "runtime shared library" feature
>> work for the LFC, I need to figure out why that is. But we don't need
>> it right now, because the LFC isn't getting copied into each loadable
>> library anymore.
>>
>> Tests:
>> test/snippets/import-class.lzx
>> test/snippets/import-resource.lzx
>>
>> generated library .swf files are nice and small now, they don't have the
>> LFC in them
>>
>> Files:
>> M WEB-INF/lps/server/src/org/openlaszlo/sc/SWF9External.java
>> M WEB-INF/lps/server/src/org/openlaszlo/sc/Compiler.java
>> M WEB-INF/lps/server/src/org/openlaszlo/compiler/DataCompiler.java
>> M WEB-INF/lps/server/src/org/openlaszlo/compiler/ImportCompiler.java
>> M WEB-INF/lps/server/src/org/openlaszlo/compiler/SWF9Writer.java
>>
>>
>> Changeset: http://svn.openlaszlo.org/openlaszlo/patches/20081119-hqm-q.tar
>
>
--
Henry Minsky
Software Architect
[EMAIL PROTECTED]