| OLD | NEW |
| 1 /* | 1 /* |
| 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org) | 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org) |
| 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012 Apple Inc. All r
ights reserved. | 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012 Apple Inc. All r
ights reserved. |
| 4 * Copyright (C) 2011 Research In Motion Limited. All rights reserved. | 4 * Copyright (C) 2011 Research In Motion Limited. All rights reserved. |
| 5 * | 5 * |
| 6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
| 7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
| 8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
| 9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
| 10 * | 10 * |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 113 { | 113 { |
| 114 m_propertySet->ref(); | 114 m_propertySet->ref(); |
| 115 } | 115 } |
| 116 | 116 |
| 117 void PropertySetCSSStyleDeclaration::deref() | 117 void PropertySetCSSStyleDeclaration::deref() |
| 118 { | 118 { |
| 119 m_propertySet->deref(); | 119 m_propertySet->deref(); |
| 120 } | 120 } |
| 121 #endif | 121 #endif |
| 122 | 122 |
| 123 void PropertySetCSSStyleDeclaration::trace(Visitor* visitor) | |
| 124 { | |
| 125 visitor->trace(m_propertySet); | |
| 126 AbstractPropertySetCSSStyleDeclaration::trace(visitor); | |
| 127 } | |
| 128 | |
| 129 unsigned AbstractPropertySetCSSStyleDeclaration::length() const | 123 unsigned AbstractPropertySetCSSStyleDeclaration::length() const |
| 130 { | 124 { |
| 131 return propertySet().propertyCount(); | 125 return propertySet().propertyCount(); |
| 132 } | 126 } |
| 133 | 127 |
| 134 String AbstractPropertySetCSSStyleDeclaration::item(unsigned i) const | 128 String AbstractPropertySetCSSStyleDeclaration::item(unsigned i) const |
| 135 { | 129 { |
| 136 if (i >= propertySet().propertyCount()) | 130 if (i >= propertySet().propertyCount()) |
| 137 return ""; | 131 return ""; |
| 138 return propertySet().propertyAt(i).cssName(); | 132 return propertySet().propertyAt(i).cssName(); |
| (...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 279 PassRefPtr<MutableStylePropertySet> AbstractPropertySetCSSStyleDeclaration::copy
Properties() const | 273 PassRefPtr<MutableStylePropertySet> AbstractPropertySetCSSStyleDeclaration::copy
Properties() const |
| 280 { | 274 { |
| 281 return propertySet().mutableCopy(); | 275 return propertySet().mutableCopy(); |
| 282 } | 276 } |
| 283 | 277 |
| 284 bool AbstractPropertySetCSSStyleDeclaration::cssPropertyMatches(CSSPropertyID pr
opertyID, const CSSValue* propertyValue) const | 278 bool AbstractPropertySetCSSStyleDeclaration::cssPropertyMatches(CSSPropertyID pr
opertyID, const CSSValue* propertyValue) const |
| 285 { | 279 { |
| 286 return propertySet().propertyMatches(propertyID, propertyValue); | 280 return propertySet().propertyMatches(propertyID, propertyValue); |
| 287 } | 281 } |
| 288 | 282 |
| 289 void AbstractPropertySetCSSStyleDeclaration::trace(Visitor* visitor) | |
| 290 { | |
| 291 #if ENABLE(OILPAN) | |
| 292 visitor->trace(m_cssomCSSValueClones); | |
| 293 #endif | |
| 294 CSSStyleDeclaration::trace(visitor); | |
| 295 } | |
| 296 | |
| 297 StyleRuleCSSStyleDeclaration::StyleRuleCSSStyleDeclaration(MutableStylePropertyS
et& propertySetArg, CSSRule* parentRule) | 283 StyleRuleCSSStyleDeclaration::StyleRuleCSSStyleDeclaration(MutableStylePropertyS
et& propertySetArg, CSSRule* parentRule) |
| 298 : PropertySetCSSStyleDeclaration(propertySetArg) | 284 : PropertySetCSSStyleDeclaration(propertySetArg) |
| 299 #if !ENABLE(OILPAN) | 285 #if !ENABLE(OILPAN) |
| 300 , m_refCount(1) | 286 , m_refCount(1) |
| 301 #endif | 287 #endif |
| 302 , m_parentRule(parentRule) | 288 , m_parentRule(parentRule) |
| 303 { | 289 { |
| 304 #if !ENABLE(OILPAN) | 290 #if !ENABLE(OILPAN) |
| 305 m_propertySet->ref(); | 291 m_propertySet->ref(); |
| 306 #endif | 292 #endif |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 352 { | 338 { |
| 353 #if !ENABLE(OILPAN) | 339 #if !ENABLE(OILPAN) |
| 354 m_propertySet->deref(); | 340 m_propertySet->deref(); |
| 355 #endif | 341 #endif |
| 356 m_propertySet = &propertySet; | 342 m_propertySet = &propertySet; |
| 357 #if !ENABLE(OILPAN) | 343 #if !ENABLE(OILPAN) |
| 358 m_propertySet->ref(); | 344 m_propertySet->ref(); |
| 359 #endif | 345 #endif |
| 360 } | 346 } |
| 361 | 347 |
| 362 void StyleRuleCSSStyleDeclaration::trace(Visitor* visitor) | |
| 363 { | |
| 364 visitor->trace(m_parentRule); | |
| 365 PropertySetCSSStyleDeclaration::trace(visitor); | |
| 366 } | |
| 367 | |
| 368 MutableStylePropertySet& InlineCSSStyleDeclaration::propertySet() const | 348 MutableStylePropertySet& InlineCSSStyleDeclaration::propertySet() const |
| 369 { | 349 { |
| 370 return m_parentElement->ensureMutableInlineStyle(); | 350 return m_parentElement->ensureMutableInlineStyle(); |
| 371 } | 351 } |
| 372 | 352 |
| 373 void InlineCSSStyleDeclaration::didMutate(MutationType type) | 353 void InlineCSSStyleDeclaration::didMutate(MutationType type) |
| 374 { | 354 { |
| 375 if (type == NoChanges) | 355 if (type == NoChanges) |
| 376 return; | 356 return; |
| 377 | 357 |
| (...skipping 18 matching lines...) Expand all Loading... |
| 396 { | 376 { |
| 397 m_parentElement->ref(); | 377 m_parentElement->ref(); |
| 398 } | 378 } |
| 399 | 379 |
| 400 void InlineCSSStyleDeclaration::deref() | 380 void InlineCSSStyleDeclaration::deref() |
| 401 { | 381 { |
| 402 m_parentElement->deref(); | 382 m_parentElement->deref(); |
| 403 } | 383 } |
| 404 #endif | 384 #endif |
| 405 | 385 |
| 406 void InlineCSSStyleDeclaration::trace(Visitor* visitor) | |
| 407 { | |
| 408 visitor->trace(m_parentElement); | |
| 409 AbstractPropertySetCSSStyleDeclaration::trace(visitor); | |
| 410 } | |
| 411 | |
| 412 } // namespace blink | 386 } // namespace blink |
| OLD | NEW |