OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2005, 2006, 2008, 2009 Apple Inc. All rights reserved. | 2 * Copyright (C) 2005, 2006, 2008, 2009 Apple Inc. 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 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 1530 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1541 return 0; | 1541 return 0; |
1542 | 1542 |
1543 RefPtrWillBeRawPtr<CSSComputedStyleDeclaration> style = CSSComputedStyleDecl
aration::create(node); | 1543 RefPtrWillBeRawPtr<CSSComputedStyleDeclaration> style = CSSComputedStyleDecl
aration::create(node); |
1544 if (!style) | 1544 if (!style) |
1545 return 0; | 1545 return 0; |
1546 | 1546 |
1547 NullableCSSValue value = style->getPropertyCSSValue(CSSPropertyFontSize); | 1547 NullableCSSValue value = style->getPropertyCSSValue(CSSPropertyFontSize); |
1548 if (!value) | 1548 if (!value) |
1549 return 0; | 1549 return 0; |
1550 | 1550 |
1551 CSSPrimitiveValue& primitiveValue = toCSSPrimitiveValue(*value); | 1551 CSSPrimitiveValue primitiveValue = toCSSPrimitiveValue(*value); |
1552 ASSERT(primitiveValue.primitiveType() == CSSPrimitiveValue::CSS_PX); | 1552 ASSERT(primitiveValue.primitiveType() == CSSPrimitiveValue::CSS_PX); |
1553 return primitiveValue.getFloatValue(); | 1553 return primitiveValue.getFloatValue(); |
1554 } | 1554 } |
1555 | 1555 |
1556 void ApplyStyleCommand::joinChildTextNodes(ContainerNode* node, const Position&
start, const Position& end) | 1556 void ApplyStyleCommand::joinChildTextNodes(ContainerNode* node, const Position&
start, const Position& end) |
1557 { | 1557 { |
1558 if (!node) | 1558 if (!node) |
1559 return; | 1559 return; |
1560 | 1560 |
1561 Position newStart = start; | 1561 Position newStart = start; |
(...skipping 30 matching lines...) Expand all Loading... |
1592 DEFINE_TRACE(ApplyStyleCommand) | 1592 DEFINE_TRACE(ApplyStyleCommand) |
1593 { | 1593 { |
1594 visitor->trace(m_style); | 1594 visitor->trace(m_style); |
1595 visitor->trace(m_start); | 1595 visitor->trace(m_start); |
1596 visitor->trace(m_end); | 1596 visitor->trace(m_end); |
1597 visitor->trace(m_styledInlineElement); | 1597 visitor->trace(m_styledInlineElement); |
1598 CompositeEditCommand::trace(visitor); | 1598 CompositeEditCommand::trace(visitor); |
1599 } | 1599 } |
1600 | 1600 |
1601 } | 1601 } |
OLD | NEW |