| OLD | NEW |
| 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 * Copyright (C) 2015 Google Inc. All rights reserved. | 7 * Copyright (C) 2015 Google Inc. All rights reserved. |
| 8 * | 8 * |
| 9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
| 10 * modify it under the terms of the GNU Lesser General Public | 10 * modify it under the terms of the GNU Lesser General Public |
| (...skipping 471 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 482 return CSSValueSansSerif; | 482 return CSSValueSansSerif; |
| 483 if (family == FontFamilyNames::webkit_serif) | 483 if (family == FontFamilyNames::webkit_serif) |
| 484 return CSSValueSerif; | 484 return CSSValueSerif; |
| 485 return CSSValueInvalid; | 485 return CSSValueInvalid; |
| 486 } | 486 } |
| 487 | 487 |
| 488 static PassRefPtrWillBeRawPtr<CSSValue> valueForFamily(const AtomicString& famil
y) | 488 static PassRefPtrWillBeRawPtr<CSSValue> valueForFamily(const AtomicString& famil
y) |
| 489 { | 489 { |
| 490 if (CSSValueID familyIdentifier = identifierForFamily(family)) | 490 if (CSSValueID familyIdentifier = identifierForFamily(family)) |
| 491 return cssValuePool().createIdentifierValue(familyIdentifier); | 491 return cssValuePool().createIdentifierValue(familyIdentifier); |
| 492 return CSSCustomIdentValue::create(family.string()); | 492 return cssValuePool().createFontFamilyValue(family.string()); |
| 493 } | 493 } |
| 494 | 494 |
| 495 static PassRefPtrWillBeRawPtr<CSSValueList> valueForFontFamily(const ComputedSty
le& style) | 495 static PassRefPtrWillBeRawPtr<CSSValueList> valueForFontFamily(const ComputedSty
le& style) |
| 496 { | 496 { |
| 497 const FontFamily& firstFamily = style.getFontDescription().family(); | 497 const FontFamily& firstFamily = style.getFontDescription().family(); |
| 498 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSeparated()
; | 498 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSeparated()
; |
| 499 for (const FontFamily* family = &firstFamily; family; family = family->next(
)) | 499 for (const FontFamily* family = &firstFamily; family; family = family->next(
)) |
| 500 list->append(valueForFamily(family->family())); | 500 list->append(valueForFamily(family->family())); |
| 501 return list.release(); | 501 return list.release(); |
| 502 } | 502 } |
| (...skipping 2248 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2751 case CSSPropertyAll: | 2751 case CSSPropertyAll: |
| 2752 return nullptr; | 2752 return nullptr; |
| 2753 default: | 2753 default: |
| 2754 break; | 2754 break; |
| 2755 } | 2755 } |
| 2756 ASSERT_NOT_REACHED(); | 2756 ASSERT_NOT_REACHED(); |
| 2757 return nullptr; | 2757 return nullptr; |
| 2758 } | 2758 } |
| 2759 | 2759 |
| 2760 } // namespace blink | 2760 } // namespace blink |
| OLD | NEW |