From: SourceForge.net <no...@so...> - 2005-08-31 12:37:05
|
Bugs item #1277369, was opened at 2005-08-31 22:36 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105757&aid=1277369&group_id=5757 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: DynAPI 3 API Group: None Status: Open Resolution: None Priority: 5 Submitted By: Andrew Gillett (agillett) Assigned to: Nobody/Anonymous (nobody) Summary: Style and Class confusion Initial Comment: dynlayer_base.js contains this code: p.setClass = function(c,noInlineStyle){ this._className=c; if(this.css) this.css.className=cn; else { this._cssClass=(c)? 'class="'+c+'"':''; this._noStyle=noInlineStyle; } }; This function is doing two different and unrelated things: 1. it is setting the _className attibute of the DynObject. This is normally set in the DynObject.setPrototype method and I see no reason why it should ever change. The _className attribute indicates a DynObjects type. 2. it also sets the className attribute of the stylesheet object that belongs to the DOM element associated with the DynLayer object. The setClass method should do 2 and not 1. When I want to alter the appearance of an element by changing its style, I should not be forced to also change the DynLayers object type. p.setClass = function(c,noInlineStyle){ if(this.css) this.css.className=cn; else { this._cssClass=(c)? 'class="'+c+'"':''; this._noStyle=noInlineStyle; } }; ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105757&aid=1277369&group_id=5757 |