Tobie Langel
a246e777f5
prototype: Fix Selector.matchElements to allow for coma-separated selectors in Element#up/next/previous and Event#findElement.
2008-01-06 21:49:16 +00:00
Tobie Langel
0008fe4aed
prototype: Test.Unit refactoring. Allow running multiple instances of Test.Unit.Runner on the same page. Allow rake to run specific testcases. Closes #10704 , #10705 , #10706 .
2008-01-06 00:34:39 +00:00
Tobie Langel
b4735bca7c
prototype: Make Element#insert standard-compliant. Fixes an issue in FF3b2 when inserting HTML or text inside DOM nodes which aren't (yet) appended to the document.
2008-01-03 01:50:36 +00:00
Andrew Dupont
4d3ebf0912
Change document.viewport.getDimensions to exclude scrollbars in all cases. Closes #10148 , #9288 . [Nick Stackenburg]
2007-12-04 04:28:27 +00:00
Andrew Dupont
3e82a712d1
Changed some unit tests to filter out false test failures in Opera.
2007-12-04 03:58:44 +00:00
Andrew Dupont
c85285496b
* Ensure no comment nodes are returned in Selector queries (IE improperly returns comment nodes on getElementsByTagName("*")). Change Element#descendants to use Element#getElementsBySelector in order to avoid this issue. Closes #10220 . [Jeff Gobel, Andrew Dupont]
2007-11-27 18:43:56 +00:00
Andrew Dupont
26b8033295
* Fix a bug in the IE-specific Element#descendantOf logic. [Nicholas, Andrew Dupont]
2007-11-27 17:59:46 +00:00
Tobie Langel
d6b843c9cb
Ensure Element#hasClassName always returns a boolean. Closes #10075 .
2007-11-05 17:43:56 +00:00
Andrew Dupont
7cf17c7bec
Performance optimizations for Element#descendantOf. Costliness should no longer be dependent on the difference in depth between the parent and the child. [Andrew Dupont]
2007-11-01 15:11:52 +00:00
Sam Stephenson
18969c5159
prototype: Reset the browser's dimensions to their original settings after running the DOM viewport tests.
2007-10-26 03:10:06 +00:00
Tobie Langel
16127b024a
prototype: In IE, allow opacity to be set on elements not yet attached to the document. Closes #9904 .
2007-10-22 13:14:56 +00:00
Tobie Langel
0100aee1a0
prototype: Add more tests to Element.update.
2007-10-22 11:30:52 +00:00
Sam Stephenson
4607e29fa2
prototype: Element#wrap now returns the wrapper instead of the element being wrapped.
2007-10-11 06:11:26 +00:00
Thomas Fuchs
aa1a7f5bf0
prototype: Define Node constants conditionally after checking for Node.ELEMENT_NODE presence. Add unit test to check the values of all constants. Closes #7625 .
2007-08-17 11:20:56 +00:00
Thomas Fuchs
5f76c255a1
Fix Element#positionedOffset and Element#getOffsetParent for static elements on IE. DOM unit tests now pass on IE.
2007-08-10 14:19:30 +00:00
Sam Stephenson
ae2ab03294
prototype: Add the document.viewport object for querying dimensions and scroll offsets of the browser viewport.
2007-08-08 20:42:46 +00:00
Sam Stephenson
c0735dba77
prototype: Make Element#wrap accept a second argument for setting attributes on the wrapper. Allow wrapping elements which are not part of the document. Closes #9071 .
2007-07-24 19:08:55 +00:00
Sam Stephenson
44ef74813b
prototype: Improvements for Element#replace, Element#update and Element#insert. Closes #7429 , #9060 .
2007-07-24 18:52:17 +00:00
Sam Stephenson
7b2ce66e88
prototype: Make Element#setStyle accept a string argument of CSS rules. Deprecate uncamelized style property names when setting styles using an object (for performance reasons). Closes #9059 .
2007-07-24 18:14:36 +00:00
Sam Stephenson
c6f3daadaa
prototype: Add Element#identify, which returns the element's ID if it exists, or sets and returns a unique, auto-generated ID (of the form 'anonymous_element_' + auto-incremented digit) otherwise. Use this when you need to ensure an element has an ID. Closes #9012 .
2007-07-24 17:41:27 +00:00
Sam Stephenson
7e6481bcd7
prototype: Make Element#readAttribute work for cloned elements in IE. Closes #8481 .
2007-07-24 17:31:23 +00:00
Thomas Fuchs
cea24d6cc2
Prototype: Rename Element#getElementsBySelector to Element#select and add alias for Element#getElementsBySelector. Add Element#adjacent as a shortcut to selecting all adjacent nodes (and their children) that match a CSS selector.
2007-07-13 08:36:14 +00:00
Sam Stephenson
d6bf5e40ce
prototype: Make document.getElementsByClassName match a subset of the WHATWG Web Applications 1.0 specification which was adopted in Firefox 3 ( http://www.whatwg.org/specs/web-apps/current-work/#getelementsbyclassname ). It now supports multiple class names given as a whitespace-separated list in a string. Array argument is not supported. The method will only return the nodes that match all the class names. In browsers that implement the method natively it will not be overwritten. Closes #8401 .
2007-06-19 20:59:14 +00:00
Thomas Fuchs
0894f235b8
Begone, test artifacts
2007-06-17 22:29:44 +00:00
Thomas Fuchs
03ae9dd3ee
* Make document.getElementsByClassName match the WHATWG Web Applications 1.0 specification which was adopted in Firefox 3 ( http://www.whatwg.org/specs/web-apps/current-work/#getelementsbyclassname ). It now supports multiple class names given as an array or a space-separated list in a string. The method will only return the nodes that match all the class names. In browsers that implement the method natively it will not be overwritten. Closes #8401 . [Mislav Marohnic]
2007-06-17 22:26:46 +00:00
Thomas Fuchs
d5665e0d22
Prototype: add failing unit test (IE) for Element.Methods.getStyle on auto-calculated widths. References #8564 .
2007-06-10 12:58:32 +00:00
Thomas Fuchs
0c7bac17f0
Prototype: Make Element#absolutize and Element#relativize properly use Element#getStyle. Closes #8580 . [Christophe Porteneuve]
2007-06-06 14:30:01 +00:00
Thomas Fuchs
5f4bab4dcb
Prototype: Fix Element.insert for null values and numeric values when defaulting to bottom
2007-06-02 16:00:47 +00:00
Thomas Fuchs
d4d4fddc7c
Prototype: Change Element.insert syntax to allow multiple positions.
2007-06-02 15:08:50 +00:00
Thomas Fuchs
f099e670f5
Element.setOpacity now calls removeAttribute on the filter style on IE if no more filters remain, which makes Cleartype work properly. Closes #8376 .
2007-05-19 00:11:46 +00:00
Thomas Fuchs
df33e410b0
testElementMethodInsert: add test for non-lowercase position argument
2007-05-12 19:12:04 +00:00
Sam Stephenson
83b4b337e1
Merge -r6634:HEAD from ../branches/dom.
...
* Make Element#update and Element#insert work for SELECT tags in IE and Opera. [Tobie Langel]
* Make Element#insert and Element#update better handle TABLE related elements in IE and Opera. Closes #7776 , #8040 , #7550 , #7776 , #7938 . [Tobie Langel]
* Make Element#readAttribute('title') work in Opera. [Tobie Langel]
* Make Element#replace work with form elements in Firefox and Safari. Closes #8010 , #7989 . [dsl239, Tobie Langel]
* Add Element#wrap which wraps the element inside a new one. Closes #5732 . [P. Vande, Tobie Langel]
* Make Element into a constructor: new Element(tagName, attributes). Add Element#writeAttribute which accepts a hash of attributes or a name/value pair. Closes #7476 . [Mislav Marohnić, haraldmartin, Tobie Langel]
* Insertion overhaul: Add Element.insert(content[, position = 'Bottom']). Deprecate Insertion (kept for backwards compatibility). Make Ajax.Updater option.insertion accept both Insertion.Top or the now preferred 'Top'. Closes #7907 . [Tobie Langel]
2007-05-12 05:01:56 +00:00
Sam Stephenson
1886b03d60
prototype: Fix Element#readAttribute to work with the 'type' attribute in IE. Closes #8160 .
2007-04-28 02:23:26 +00:00
Sam Stephenson
47bfeb5083
prototype: Add Element#childElements as an alias for Element#immediateDescendants.
2007-04-24 06:17:59 +00:00
Sam Stephenson
5784d78f6e
prototype: Add Element#firstDescendant to retrieve the first non-text child node of an element. Optimize DOM navigation methods (Element#up, Element#down, Element#previous, Element#next) for no-argument calls. Closes #7848 .
2007-04-24 06:06:44 +00:00
Sam Stephenson
63342b9c01
prototype: Element.addMethods should add methods to Element as well as Element.Methods. Closes #7888 .
2007-04-24 05:23:41 +00:00
Thomas Fuchs
193104ac33
Trivial dom.html cleanups, dont do the hidden element getDimensions test for now
2007-04-18 16:30:40 +00:00
Thomas Fuchs
4c90be6a30
Prevent a crash on Safari on String.prototype.stripScripts and extractScripts with large <script> tags.
2007-04-03 22:21:58 +00:00
Thomas Fuchs
930c8f2665
Fix an issue with Element.getDimensions with some element types on non IE-browsers. Closes #7683 . [Andrew Dupont]
2007-03-27 18:04:59 +00:00
Thomas Fuchs
e9501d63e5
Make Element.extend work on IE for Nodes with the same ID that where discarded.
2007-03-11 22:40:24 +00:00
Thomas Fuchs
881b7dc00f
Prototype: Fix Element.Methods.descendants() to properly extend elements on IE.
2007-03-11 10:59:06 +00:00
Thomas Fuchs
752eebdd26
Prototype: Fix simulated attribute reading for IE for "href", "src" and boolean attributes.
2007-03-08 22:43:18 +00:00
Thomas Fuchs
fcc23f0d70
Optimize document.getElementsByClassName and finalize DOM performance optimization refactoring. Closes #6696
2007-03-04 22:55:08 +00:00
Thomas Fuchs
aa7ba0d4ff
Prototype: Add optional third parameter "camlized" to Element.setStyle, for optimized performance if style names are known to be camelCased. [Thomas Fuchs]
2007-03-02 12:36:09 +00:00
Thomas Fuchs
60bb0686ba
Prototype: Optimize Element.getStyle and add new Element.getOpacity method. Special case IE and Opera getStyle methods. Closes #7648 . [Tobie Langel, Thomas Fuchs]
2007-02-27 11:35:21 +00:00
Thomas Fuchs
80f6f4076b
Prototype: Optimize Element.setStyle and add new Element.setOpacity method, special case IE and Gecko opacity methods. Closes #7585 . [savetheclocktower]
2007-02-23 01:19:18 +00:00
Sam Stephenson
7044da8138
prototype: Fix $(form).serialize() in Safari and add support for extending specific tags to Element.addMethods. Closes #7358 .
2007-01-27 19:45:34 +00:00
Thomas Fuchs
8ea007df28
Prototype: Make setStyle() with opacity: 0 in Internet Explorer work correctly. [Thomas Fuchs]
2007-01-19 18:01:43 +00:00
Sam Stephenson
bb4d189b37
prototype: Reorganize the source tree.
2007-01-18 22:24:27 +00:00