OLD | NEW |
---|---|
1 /* | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 * Copyright (C) 2006, 2007, 2009 Apple Inc. All rights reserved. | 2 // Use of this source code is governed by a BSD-style license that can be |
3 * Copyright (C) 2006 Samuel Weinig <sam.weinig@gmail.com> | 3 // found in the LICENSE file. |
4 * | |
5 * This library is free software; you can redistribute it and/or | |
6 * modify it under the terms of the GNU Library General Public | |
7 * License as published by the Free Software Foundation; either | |
8 * version 2 of the License, or (at your option) any later version. | |
9 * | |
10 * This library is distributed in the hope that it will be useful, | |
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 * Library General Public License for more details. | |
14 * | |
15 * You should have received a copy of the GNU Library General Public License | |
16 * along with this library; see the file COPYING.LIB. If not, write to | |
17 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | |
18 * Boston, MA 02110-1301, USA. | |
19 */ | |
20 | 4 |
21 [ | 5 interface Element : ParentNode { |
22 SpecialWrapFor=HTMLElement, | 6 readonly attribute DOMString tagName; |
23 ] interface Element : Node { | |
24 readonly attribute DOMString? tagName; | |
25 | 7 |
26 DOMString? getAttribute(DOMString name); | 8 boolean hasAttribute(DOMString name); |
27 [RaisesException, CustomElementCallbacks] void setAttribute(DOMString name, DOMString value); | 9 [TreatReturnedNullStringAs=Null] DOMString getAttribute(DOMString name); |
28 [CustomElementCallbacks] void removeAttribute(DOMString name); | 10 [RaisesException] void setAttribute(DOMString name, optional DOMString value); |
29 boolean hasAttribute(DOMString name); | 11 void removeAttribute(DOMString name); |
30 boolean hasAttributes(); | |
31 sequence<Attr> getAttributes(); | |
32 | 12 |
33 readonly attribute CSSStyleDeclaration style; | 13 sequence<Attr> getAttributes(); |
34 | 14 |
35 [Reflect] attribute DOMString id; | 15 readonly attribute ShadowRoot shadowRoot; |
36 readonly attribute DOMString? localName; | |
37 | 16 |
38 [RaisesException] boolean matches(DOMString selectors); | 17 // TODO(abarth): Move to Node. |
18 readonly attribute CSSStyleDeclaration style; | |
esprehn
2015/02/13 23:53:48
Only elements have style, why move this to node?
abarth-chromium
2015/02/13 23:59:45
That's what Ian's spec says. Maybe we should chan
| |
39 | 19 |
40 readonly attribute long offsetLeft; | 20 // TODO(abarth): Remove these when we implement more of the system. |
41 readonly attribute long offsetTop; | 21 [RaisesException] boolean matches(DOMString selectors); |
42 readonly attribute long offsetWidth; | 22 void focus(); |
43 readonly attribute long offsetHeight; | 23 void blur(); |
44 readonly attribute Element offsetParent; | 24 attribute long tabIndex; |
45 readonly attribute long clientLeft; | 25 readonly attribute DOMTokenList classList; |
46 readonly attribute long clientTop; | 26 [RaisesException] ShadowRoot ensureShadowRoot(); |
47 readonly attribute long clientWidth; | 27 readonly attribute long offsetLeft; |
48 readonly attribute long clientHeight; | 28 readonly attribute long offsetTop; |
49 | 29 readonly attribute long offsetWidth; |
50 void focus(); | 30 readonly attribute long offsetHeight; |
51 void blur(); | 31 readonly attribute Element offsetParent; |
52 | 32 readonly attribute long clientLeft; |
53 readonly attribute DOMTokenList classList; | 33 readonly attribute long clientTop; |
54 | 34 readonly attribute long clientWidth; |
55 [RaisesException] ShadowRoot ensureShadowRoot(); | 35 readonly attribute long clientHeight; |
56 readonly attribute ShadowRoot shadowRoot; | |
57 NodeList getDestinationInsertionPoints(); | |
58 | |
59 // CSSOM View Module API | |
60 ClientRectList getClientRects(); | |
61 ClientRect getBoundingClientRect(); | |
62 | |
63 [Reflect] attribute DOMString lang; | |
64 attribute DOMString dir; | |
65 | |
66 [CustomElementCallbacks] attribute long tabIndex; | |
67 | |
68 [CustomElementCallbacks, RaisesException=Setter] attribute DOMString content Editable; | |
69 readonly attribute boolean isContentEditable; | |
70 | |
71 attribute boolean spellcheck; | |
72 }; | 36 }; |
73 | |
74 Element implements ParentNode; | |
75 Element implements ChildNode; | |
OLD | NEW |