| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2000 Simon Hausmann (hausmann@kde.org) | 4 * (C) 2000 Simon Hausmann (hausmann@kde.org) |
| 5 * (C) 2001 Dirk Mueller (mueller@kde.org) | 5 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 6 * Copyright (C) 2004, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. | 6 * Copyright (C) 2004, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| (...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 document().textLinkColors().setLinkColor(color); | 107 document().textLinkColors().setLinkColor(color); |
| 108 else if (name == vlinkAttr) | 108 else if (name == vlinkAttr) |
| 109 document().textLinkColors().setVisitedLinkColor(color); | 109 document().textLinkColors().setVisitedLinkColor(color); |
| 110 else | 110 else |
| 111 document().textLinkColors().setActiveLinkColor(color); | 111 document().textLinkColors().setActiveLinkColor(color); |
| 112 } | 112 } |
| 113 } | 113 } |
| 114 | 114 |
| 115 setNeedsStyleRecalc(SubtreeStyleChange); | 115 setNeedsStyleRecalc(SubtreeStyleChange); |
| 116 } else if (name == onloadAttr) | 116 } else if (name == onloadAttr) |
| 117 document().setWindowAttributeEventListener(EventTypeNames::load, createA
ttributeEventListener(document().frame(), name, value)); | 117 document().setWindowAttributeEventListener(EventTypeNames::load, createA
ttributeEventListener(document().frame(), name, value, eventParameterName())); |
| 118 else if (name == onbeforeunloadAttr) | 118 else if (name == onbeforeunloadAttr) |
| 119 document().setWindowAttributeEventListener(EventTypeNames::beforeunload,
createAttributeEventListener(document().frame(), name, value)); | 119 document().setWindowAttributeEventListener(EventTypeNames::beforeunload,
createAttributeEventListener(document().frame(), name, value, eventParameterNam
e())); |
| 120 else if (name == onunloadAttr) | 120 else if (name == onunloadAttr) |
| 121 document().setWindowAttributeEventListener(EventTypeNames::unload, creat
eAttributeEventListener(document().frame(), name, value)); | 121 document().setWindowAttributeEventListener(EventTypeNames::unload, creat
eAttributeEventListener(document().frame(), name, value, eventParameterName())); |
| 122 else if (name == onpagehideAttr) | 122 else if (name == onpagehideAttr) |
| 123 document().setWindowAttributeEventListener(EventTypeNames::pagehide, cre
ateAttributeEventListener(document().frame(), name, value)); | 123 document().setWindowAttributeEventListener(EventTypeNames::pagehide, cre
ateAttributeEventListener(document().frame(), name, value, eventParameterName())
); |
| 124 else if (name == onpageshowAttr) | 124 else if (name == onpageshowAttr) |
| 125 document().setWindowAttributeEventListener(EventTypeNames::pageshow, cre
ateAttributeEventListener(document().frame(), name, value)); | 125 document().setWindowAttributeEventListener(EventTypeNames::pageshow, cre
ateAttributeEventListener(document().frame(), name, value, eventParameterName())
); |
| 126 else if (name == onpopstateAttr) | 126 else if (name == onpopstateAttr) |
| 127 document().setWindowAttributeEventListener(EventTypeNames::popstate, cre
ateAttributeEventListener(document().frame(), name, value)); | 127 document().setWindowAttributeEventListener(EventTypeNames::popstate, cre
ateAttributeEventListener(document().frame(), name, value, eventParameterName())
); |
| 128 else if (name == onblurAttr) | 128 else if (name == onblurAttr) |
| 129 document().setWindowAttributeEventListener(EventTypeNames::blur, createA
ttributeEventListener(document().frame(), name, value)); | 129 document().setWindowAttributeEventListener(EventTypeNames::blur, createA
ttributeEventListener(document().frame(), name, value, eventParameterName())); |
| 130 else if (name == onerrorAttr) | 130 else if (name == onerrorAttr) |
| 131 document().setWindowAttributeEventListener(EventTypeNames::error, create
AttributeEventListener(document().frame(), name, value)); | 131 document().setWindowAttributeEventListener(EventTypeNames::error, create
AttributeEventListener(document().frame(), name, value, eventParameterName())); |
| 132 else if (name == onfocusAttr) | 132 else if (name == onfocusAttr) |
| 133 document().setWindowAttributeEventListener(EventTypeNames::focus, create
AttributeEventListener(document().frame(), name, value)); | 133 document().setWindowAttributeEventListener(EventTypeNames::focus, create
AttributeEventListener(document().frame(), name, value, eventParameterName())); |
| 134 else if (RuntimeEnabledFeatures::orientationEventEnabled() && name == onorie
ntationchangeAttr) | 134 else if (RuntimeEnabledFeatures::orientationEventEnabled() && name == onorie
ntationchangeAttr) |
| 135 document().setWindowAttributeEventListener(EventTypeNames::orientationch
ange, createAttributeEventListener(document().frame(), name, value)); | 135 document().setWindowAttributeEventListener(EventTypeNames::orientationch
ange, createAttributeEventListener(document().frame(), name, value, eventParamet
erName())); |
| 136 else if (name == onhashchangeAttr) | 136 else if (name == onhashchangeAttr) |
| 137 document().setWindowAttributeEventListener(EventTypeNames::hashchange, c
reateAttributeEventListener(document().frame(), name, value)); | 137 document().setWindowAttributeEventListener(EventTypeNames::hashchange, c
reateAttributeEventListener(document().frame(), name, value, eventParameterName(
))); |
| 138 else if (name == onmessageAttr) | 138 else if (name == onmessageAttr) |
| 139 document().setWindowAttributeEventListener(EventTypeNames::message, crea
teAttributeEventListener(document().frame(), name, value)); | 139 document().setWindowAttributeEventListener(EventTypeNames::message, crea
teAttributeEventListener(document().frame(), name, value, eventParameterName()))
; |
| 140 else if (name == onresizeAttr) | 140 else if (name == onresizeAttr) |
| 141 document().setWindowAttributeEventListener(EventTypeNames::resize, creat
eAttributeEventListener(document().frame(), name, value)); | 141 document().setWindowAttributeEventListener(EventTypeNames::resize, creat
eAttributeEventListener(document().frame(), name, value, eventParameterName())); |
| 142 else if (name == onscrollAttr) | 142 else if (name == onscrollAttr) |
| 143 document().setWindowAttributeEventListener(EventTypeNames::scroll, creat
eAttributeEventListener(document().frame(), name, value)); | 143 document().setWindowAttributeEventListener(EventTypeNames::scroll, creat
eAttributeEventListener(document().frame(), name, value, eventParameterName())); |
| 144 else if (name == onselectionchangeAttr) | 144 else if (name == onselectionchangeAttr) |
| 145 document().setAttributeEventListener(EventTypeNames::selectionchange, cr
eateAttributeEventListener(document().frame(), name, value)); | 145 document().setAttributeEventListener(EventTypeNames::selectionchange, cr
eateAttributeEventListener(document().frame(), name, value, eventParameterName()
)); |
| 146 else if (name == onstorageAttr) | 146 else if (name == onstorageAttr) |
| 147 document().setWindowAttributeEventListener(EventTypeNames::storage, crea
teAttributeEventListener(document().frame(), name, value)); | 147 document().setWindowAttributeEventListener(EventTypeNames::storage, crea
teAttributeEventListener(document().frame(), name, value, eventParameterName()))
; |
| 148 else if (name == ononlineAttr) | 148 else if (name == ononlineAttr) |
| 149 document().setWindowAttributeEventListener(EventTypeNames::online, creat
eAttributeEventListener(document().frame(), name, value)); | 149 document().setWindowAttributeEventListener(EventTypeNames::online, creat
eAttributeEventListener(document().frame(), name, value, eventParameterName())); |
| 150 else if (name == onofflineAttr) | 150 else if (name == onofflineAttr) |
| 151 document().setWindowAttributeEventListener(EventTypeNames::offline, crea
teAttributeEventListener(document().frame(), name, value)); | 151 document().setWindowAttributeEventListener(EventTypeNames::offline, crea
teAttributeEventListener(document().frame(), name, value, eventParameterName()))
; |
| 152 else if (name == onlanguagechangeAttr) | 152 else if (name == onlanguagechangeAttr) |
| 153 document().setWindowAttributeEventListener(EventTypeNames::languagechang
e, createAttributeEventListener(document().frame(), name, value)); | 153 document().setWindowAttributeEventListener(EventTypeNames::languagechang
e, createAttributeEventListener(document().frame(), name, value, eventParameterN
ame())); |
| 154 else | 154 else |
| 155 HTMLElement::parseAttribute(name, value); | 155 HTMLElement::parseAttribute(name, value); |
| 156 } | 156 } |
| 157 | 157 |
| 158 Node::InsertionNotificationRequest HTMLBodyElement::insertedInto(ContainerNode*
insertionPoint) | 158 Node::InsertionNotificationRequest HTMLBodyElement::insertedInto(ContainerNode*
insertionPoint) |
| 159 { | 159 { |
| 160 HTMLElement::insertedInto(insertionPoint); | 160 HTMLElement::insertedInto(insertionPoint); |
| 161 return InsertionShouldCallDidNotifySubtreeInsertions; | 161 return InsertionShouldCallDidNotifySubtreeInsertions; |
| 162 } | 162 } |
| 163 | 163 |
| (...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 324 double HTMLBodyElement::scrollWidth() | 324 double HTMLBodyElement::scrollWidth() |
| 325 { | 325 { |
| 326 // Update the document's layout. | 326 // Update the document's layout. |
| 327 Document& document = this->document(); | 327 Document& document = this->document(); |
| 328 document.updateLayoutIgnorePendingStylesheets(); | 328 document.updateLayoutIgnorePendingStylesheets(); |
| 329 FrameView* view = document.view(); | 329 FrameView* view = document.view(); |
| 330 return view ? adjustForZoom(view->contentsWidth(), &document) : 0; | 330 return view ? adjustForZoom(view->contentsWidth(), &document) : 0; |
| 331 } | 331 } |
| 332 | 332 |
| 333 } // namespace WebCore | 333 } // namespace WebCore |
| OLD | NEW |