On Monday, March 3, 2003, at 11:48 AM, Raymond Irving wrote:
Agreed, but make sure you test for the existence of this._createInLine() before calling it, and eventually raise if the layer is setInline, but the fucntion isn't defined. I guess the inline schem still need to be optional, right ?
The setID should be modified from within dynapi.js Only add the inline argument:
p.setID = function(id,isInline) { if (this.id) delete DynObject.all[this.id]; this.id = id; this.isInline=isInline; DynObject.all[this.id] = this; };
There are other areas inside the api that would check for isInline. I think I'll have to check this out later. If you don't mind I can add the necessary codes to call the _createInLine() functions into the various areas of the api. So you could focus on the dynlayer_inline.js file while I'll add the isInline checks. Agree?
Benoit
PS. Also remember that We'll now be using DynLayerInline instead of DynLayer_inline
-- Raymond Irving
--- Benoit Marchant <[EMAIL PROTECTED]> wrote:-------------------------------------------------------Ok, so do we add the isInline argument to setID in event.js where we do use it in addChild ?
p.DynObjectSetID = DynObject.setID p.setID = function(id,isInline) { p.DynObjectSetID(id); this.isInline = isInline; };
Make sense ?
Benoit
isInlineOn Saturday, March 1, 2003, at 07:24 PM, Raymond Irving wrote:
to
--- Benoit Marchant <[EMAIL PROTECTED]> wrote:You didn't tell why you don't like adding an argument to addChild ?
Well, I believe that using setID() will allows uselmbetter set the isInline property. This will offer greater flexiblity if we need to test if a layer'sisLinealready exist or if we need to do other stuff with inline layers. All we have to do is to check ifis true and we will know if the layers has aninlineelm.Raymond
-- Raymond Irving
Benoit
On Friday, February 28, 2003, at 03:09 PM,thenIrving wrote:
wrote:
--- Doug Melvin <[EMAIL PROTECTED]>thenhow about .bindInline('inlineID'); ? thus binding yer dynlayer to an inline layer..
Hmmm...
setID(newID,true) if it's for an inline is more flexible.
If done before adding the layer to the documentwhen you do add, it would bind the inline layer.. if done after the dynlayer has been added..method<[EMAIL PROTECTED]>delete the dynamically created components and bind to the inline layer ----- Original Message ----- From: "Raymond Irving" <[EMAIL PROTECTED]> To: "DynAPI-Dev"Sent: Friday, February 28, 2003 2:49 PM Subject: Re: [Dynapi-Dev] New TemplateDesigner Object for 3.0
--- Benoit Marchant <[EMAIL PROTECTED]> wrote:So what about tweaking addChild(c,alias)specifytoaddChild(c,alias,inline). Then you cantheinline as true, and we would default to no, which means it would be transparent to the current api.
I disagree with adding an inline argument toasisInlineaddChild. I would however suggest that atheproperty be used:
lyr.isInline=true;
or we could modify the setID() function to useinline agrument.function ()
We can "override" DynElement.prototype.addChild in the dynlayer_inline.js, t should work as long as you include that file, right ?
Yes but not necessary.
DynLayer.prototype.assignInlineElement ={ if (this.parent && !this.elm) { //I'm not sure we want to call that__________________________________________________hereonprecreate was usually used to do setHTML which doesn't make senseassignInlineElement()since the html already exists. Comments ? //DynElement._flagEvent(this,'precreate'); DynLayer._assignElement(this); DynLayer._updateValues(this); DynElement._flagEvent(this,'create'); } }
Use _createInline() isstead ofobject
function(c,alias,inline) {
function(c,alias) {
if (!c) return dynapi.debug.print("Error: nosent to [DynLayer].addChild()"); if (c.isChild) c.removeFromParent(); c.isChild = true; c.parent = this; if (c._saveAnchor) { c.setAnchor(c._saveAnchor); delete c._saveAnchor; } if(alias) this[alias]=c; if (this._created) { if(!inline) c._create();
if(!c.isLine) c._create();
else { c.assignInlineElement();
c._createInline();
} this.children[this.children.length] = c; return c; };
-- Raymond Irving
moreDo you Yahoo!? Yahoo! Tax Center - forms, calculators, tips,http://taxes.yahoo.com/
http://www.mail-archive.com/[EMAIL PROTECTED]/_______________________________________________This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf
Dynapi-Dev mailing list [EMAIL PROTECTED]
=== message truncated ===
__________________________________________________ Do you Yahoo!? Yahoo! Tax Center - forms, calculators, tips, more http://taxes.yahoo.com/
------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ Dynapi-Dev mailing list [EMAIL PROTECTED] http://www.mail-archive.com/[EMAIL PROTECTED]/
-------------------------------------------------------
This SF.net email is sponsored by: Etnus, makers of TotalView, The debugger for complex code. Debugging C/C++ programs can leave you feeling lost and disoriented. TotalView can help you find your way. Available on major UNIX and Linux platforms. Try it free. www.etnus.com
_______________________________________________
Dynapi-Dev mailing list
[EMAIL PROTECTED]
http://www.mail-archive.com/[EMAIL PROTECTED]/
