Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(102)

Side by Side Diff: Source/core/css/CSSComputedStyleDeclaration.cpp

Issue 184313004: Move all RefPtr's to CSSValue to oilpan transition types, except for the one in CSSCursorImageValue. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix comment Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/animation/AnimatableUnknownTest.cpp ('k') | Source/core/css/CSSProperty.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004 Zack Rusin <zack@kde.org> 2 * Copyright (C) 2004 Zack Rusin <zack@kde.org>
3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved. 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved.
4 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> 4 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org>
5 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com> 5 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com>
6 * Copyright (C) 2011 Sencha, Inc. All rights reserved. 6 * Copyright (C) 2011 Sencha, Inc. All rights reserved.
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 Lesser General Public 9 * modify it under the terms of the GNU Lesser General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 2936 matching lines...) Expand 10 before | Expand all | Expand 10 after
2947 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSlashSeparated() ; 2947 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSlashSeparated() ;
2948 for (size_t i = 0; i < shorthand.length(); ++i) { 2948 for (size_t i = 0; i < shorthand.length(); ++i) {
2949 RefPtrWillBeRawPtr<CSSValue> value = getPropertyCSSValue(shorthand.prope rties()[i], DoNotUpdateLayout); 2949 RefPtrWillBeRawPtr<CSSValue> value = getPropertyCSSValue(shorthand.prope rties()[i], DoNotUpdateLayout);
2950 list->append(value.release()); 2950 list->append(value.release());
2951 } 2951 }
2952 return list.release(); 2952 return list.release();
2953 } 2953 }
2954 2954
2955 PassRefPtr<MutableStylePropertySet> CSSComputedStyleDeclaration::copyPropertiesI nSet(const Vector<CSSPropertyID>& properties) const 2955 PassRefPtr<MutableStylePropertySet> CSSComputedStyleDeclaration::copyPropertiesI nSet(const Vector<CSSPropertyID>& properties) const
2956 { 2956 {
2957 Vector<CSSProperty, 256> list; 2957 WillBeHeapVector<CSSProperty, 256> list;
2958 list.reserveInitialCapacity(properties.size()); 2958 list.reserveInitialCapacity(properties.size());
2959 for (unsigned i = 0; i < properties.size(); ++i) { 2959 for (unsigned i = 0; i < properties.size(); ++i) {
2960 RefPtrWillBeRawPtr<CSSValue> value = getPropertyCSSValue(properties[i]); 2960 RefPtrWillBeRawPtr<CSSValue> value = getPropertyCSSValue(properties[i]);
2961 if (value) 2961 if (value)
2962 list.append(CSSProperty(properties[i], value.release(), false)); 2962 list.append(CSSProperty(properties[i], value.release(), false));
2963 } 2963 }
2964 return MutableStylePropertySet::create(list.data(), list.size()); 2964 return MutableStylePropertySet::create(list.data(), list.size());
2965 } 2965 }
2966 2966
2967 CSSRule* CSSComputedStyleDeclaration::parentRule() const 2967 CSSRule* CSSComputedStyleDeclaration::parentRule() const
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
3036 static const CSSPropertyID propertiesAfterSlashSeperator[3] = { CSSPropertyB ackgroundSize, CSSPropertyBackgroundOrigin, 3036 static const CSSPropertyID propertiesAfterSlashSeperator[3] = { CSSPropertyB ackgroundSize, CSSPropertyBackgroundOrigin,
3037 CSSPropertyB ackgroundClip }; 3037 CSSPropertyB ackgroundClip };
3038 3038
3039 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSlashSeparated() ; 3039 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSlashSeparated() ;
3040 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa ckground, propertiesBeforeSlashSeperator, WTF_ARRAY_LENGTH(propertiesBeforeSlash Seperator)))); 3040 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa ckground, propertiesBeforeSlashSeperator, WTF_ARRAY_LENGTH(propertiesBeforeSlash Seperator))));
3041 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa ckground, propertiesAfterSlashSeperator, WTF_ARRAY_LENGTH(propertiesAfterSlashSe perator)))); 3041 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa ckground, propertiesAfterSlashSeperator, WTF_ARRAY_LENGTH(propertiesAfterSlashSe perator))));
3042 return list.release(); 3042 return list.release();
3043 } 3043 }
3044 3044
3045 } // namespace WebCore 3045 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/animation/AnimatableUnknownTest.cpp ('k') | Source/core/css/CSSProperty.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698