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

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

Issue 209433004: Do not zero-initialize RawPtr. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix uses of RefPtrWillBeRawPtr 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Adobe Systems Incorporated. All rights reserved. 2 * Copyright (C) 2011 Adobe Systems Incorporated. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above 8 * 1. Redistributions of source code must retain the above
9 * copyright notice, this list of conditions and the following 9 * copyright notice, this list of conditions and the following
10 * disclaimer. 10 * disclaimer.
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 { 71 {
72 if ((offset.first()->getValueID() == CSSValueLeft && other.first()->getValue ID() == CSSValueTop) 72 if ((offset.first()->getValueID() == CSSValueLeft && other.first()->getValue ID() == CSSValueTop)
73 || (offset.first()->getValueID() == CSSValueTop && other.first()->getVal ueID() == CSSValueLeft)) 73 || (offset.first()->getValueID() == CSSValueTop && other.first()->getVal ueID() == CSSValueLeft))
74 return offset.second()->cssText(); 74 return offset.second()->cssText();
75 return offset.cssText(); 75 return offset.cssText();
76 } 76 }
77 77
78 static PassRefPtrWillBeRawPtr<CSSPrimitiveValue> buildSerializablePositionOffset (PassRefPtrWillBeRawPtr<CSSPrimitiveValue> offset, CSSValueID defaultSide) 78 static PassRefPtrWillBeRawPtr<CSSPrimitiveValue> buildSerializablePositionOffset (PassRefPtrWillBeRawPtr<CSSPrimitiveValue> offset, CSSValueID defaultSide)
79 { 79 {
80 CSSValueID side = defaultSide; 80 CSSValueID side = defaultSide;
81 RefPtrWillBeRawPtr<CSSPrimitiveValue> amount; 81 RefPtrWillBeRawPtr<CSSPrimitiveValue> amount = nullptr;
82 82
83 if (!offset) { 83 if (!offset) {
84 side = CSSValueCenter; 84 side = CSSValueCenter;
85 } else if (offset->isValueID()) { 85 } else if (offset->isValueID()) {
86 side = offset->getValueID(); 86 side = offset->getValueID();
87 } else if (Pair* pair = offset->getPairValue()) { 87 } else if (Pair* pair = offset->getPairValue()) {
88 side = pair->first()->getValueID(); 88 side = pair->first()->getValueID();
89 amount = pair->second(); 89 amount = pair->second();
90 } else { 90 } else {
91 amount = offset; 91 amount = offset;
(...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after
404 visitor->trace(m_left); 404 visitor->trace(m_left);
405 visitor->trace(m_topLeftRadius); 405 visitor->trace(m_topLeftRadius);
406 visitor->trace(m_topRightRadius); 406 visitor->trace(m_topRightRadius);
407 visitor->trace(m_bottomRightRadius); 407 visitor->trace(m_bottomRightRadius);
408 visitor->trace(m_bottomLeftRadius); 408 visitor->trace(m_bottomLeftRadius);
409 CSSBasicShape::trace(visitor); 409 CSSBasicShape::trace(visitor);
410 } 410 }
411 411
412 } // namespace WebCore 412 } // namespace WebCore
413 413
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698