I'll add some code to insertAllChildren() to make if
support the loading of blueprints:

insertAllChildren(useBlueprint,blueprintSrc);

The generateBlueprint() function will no longer
require a user to include dynapi.debug as it will
display a popup window showing the blueprints.
Compression will also be added to blueprints create
for .js files which will reduce the size of the
blueprint .js file by 20-40%.

--
Raymond Irving

--- Benoit Marchant <[EMAIL PROTECTED]> wrote:
> 
> On Thursday, March 20, 2003, at 07:59  AM, Raymond
> Irving wrote:
> 
> >
> > --- Benoit Marchant <[EMAIL PROTECTED]> wrote:
> >> Hello,
> >>
> >> First of all, that generateBlueprint(0 feature is
> >> really cool and very
> >> valuable !
> >>
> >> I have some questions about the inline stuff.
> >> We tried to avoid having to do an
> >> insertInlineLayers() in the thread
> >> round about inline layers, so I'm not sure what
> the
> >> benefit is ?
> >
> > I had orginally used insertAllchildren() with two
> new
> > params: asInline and ignoreInline which would look
> > like:
> >
> > insertAllchildren(asInline,ignoreInline)
> >
> > This however would cause me to add much overhead
> to
> > the existing insertAllChildren() function.
> >
> > I later then deceided to use insertBluePrint(src),
> > insertAllChildrenAsBlueprints(src) or
> > insertInlineLayers(src);
> 
> The BluePrint usage is slightly different than a
> dynamic server side  
> generation of divs. It help inline what dynapi
> generate to speed things  
> up for static pages, right ?
> My worries with the way insertInlineLayers is
> currently implemented is  
> that it loops on all children of the document and
> consider each of them  
> a "blueprint" client. If you happens to mix regular
> dynamic layers and  
> layers using inline divs as child of the document
> and call  
> insertInlineLayers, it would cause issues with the
> non inline children.  
> So something must check within insertInlineLayers,
> as it loop on the  
> children that a child is inline, before going on and
> do:
>               c.isInline=true;
>               c._noInlineValues=true;
>               DynElement._flagEvent(c,'precreate');
> as a child might not be inlined at all. in
> insertAllChildren, there's a  
> test to not process inline layers, the opposite
> should be checked in  
> insertInlineLayers.
> 
> And again, I don't see the need for 
> insertInlineLayers().
> There's 1 benefit of using insertAllChildren() I
> see:  with NS4 english  
> version, the browser loose the encoding of the page
> after the document  
> is done loading, so if your page is in SHIFT_JIS,
> and you layers  
> contains Kanji text, you better have them generated
> in the document,  
> otherwise, if you create them after, the encoding is
> lost and your text  
> isn't right.
> There's another finding I made and used with dynapi2
> and IE, on the mac  
> at least, is that if you create top layers in
> individual <script>  
> blocks, and have the divs created there (I used a
> modified create())  
> then it looks like the browser is running different
> blocks in different  
> threads as they are non related, and it really made
> a big difference in  
> heavy pages.
> 
> But for inline layers, when the document receive
> create(), the inline  
> layers will receive _createInline. So basically, if
> you add
> this ._noInlineValues=true; along this.isInline =
> isInline;
> to setID(id,isInline)
> You get the same result without having to call
> insertInlineLayers(),  
> and we should.
> 
> 
> 
> >
> > (everyone) Which method do you prefer?
> >
> > Blueprints are similar to inline layers. The only
> > difference is that you don't have to set the id of
> the
> > layers. It uses the same id structure generated by
> > dynapi plus it does not _importInlineValues as
> they
> > already exist within the dynlayer objects.
> >
> > One other advantage of blueprint is that it does
> not
> > require the user to alter there existing code.
> They
> > can design the pages as the normally would with
> > dynlayers, widgets, etc. When finsihed with the
> design
> > they can then generate a blueprint and use that
> > blueprint improve the page's loading time.
> >
> > Blueprints are not meant for widget
> > designers/developers, it is meant for
> > application/webpage developers. It can however be
> used
> > to aid in the creation of widgets.
> >
> >> Plus the way it is, if you mixed inline layers
> and
> >> non inline layers,
> >> then it would lead to issues.
> >> In insertInlineLayers:
> >>   what is the purpose of sending
> >> DynElement._flagEvent(c,'precreate'); ?
> >
> > Many widgets uses this flag to create last minute
> > values and objects just before the layers are
> created.
> > I had thought about removing it but I them decided
> > that it's will be of some use to other developers
> and
> > to some widgets.
> 
> I agree, my main concern is that if you do setHTML
> in your onprecreate,  
> then you would have to test in each widget not to do
> this if you're  
> inline, othewise you would end up with twice the
> same divs. I would  
> prefer not to worry about that as a widget developer
> as it makes more  
> things to think about. So the solution might be to
> add some code in  
> setHTML to not do it precisely when a layer is
> inline, and is about to  
> be inlineCreated.
> 
> And if want to invoke precreate event for inline
> layers, then it should  
> be invoked from _createInline too.
> 
> 
> >
> >> what is the purpose of the
> >> dynapi.frame.document.write ?
> >
> > In my preliminary test I found out that <layers>
> are
> > much faster than <divs> when used inside ns4. So I
> > wanted a way to get the most out of ns4. for this
> > reason I added the src agrument to allow a user 
> to
> > insert a javascript which would contain the
> necessary
> > codes for either ns4 or dom/ie browsers:
> >
> > if(!dynapi.ua.ns4)
> >
>
dynapi.document.insertInlineLayers('speedtest.dynlayer.inline-basic-
> 
> > blueprint_def.js');
> > else
> >
>
dynapi.document.insertInlineLayers('speedtest.dynlayer.inline-basic-
> 
> > blueprint_ns4.js');
> >
> > So in truth and in fact users can
> > generateBlueprints(true) for ns4 or dom/ie
> browsers,
> > save it to a javascript file and then use
> > insertInlineLayers() to load the script for the
> > specified browser.
> 
> 
> So the javascript file would contains only a big
> string containing the  
> html ?
> 
> >
> >> Then, I don't see a way to call
> _importInlineValues
> 
=== message truncated ===


__________________________________________________
Do you Yahoo!?
Yahoo! Platinum - Watch CBS' NCAA March Madness, live on your desktop!
http://platinum.yahoo.com


-------------------------------------------------------
This SF.net email is sponsored by:Crypto Challenge is now open! 
Get cracking and register here for some mind boggling fun and 
the chance of winning an Apple iPod:
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en
_______________________________________________
Dynapi-Dev mailing list
[EMAIL PROTECTED]
http://www.mail-archive.com/[EMAIL PROTECTED]/

Reply via email to