Changeset 117361 in webkit


Ignore:
Timestamp:
May 16, 2012 4:30:16 PM (12 years ago)
Author:
rniwa@webkit.org
Message:

REGRESSION(r92823): WebKit strips font-weight: normal from b element when copying
https://bugs.webkit.org/show_bug.cgi?id=86663

Reviewed by Tony Chang.

The bug was caused by removeStyleFromRulesAndContext incorrectly stripping font-weight property
even when the context had no font-weight property because of a property name mismatch in getPropertiesNotIn.

Fixed the mismatch.

Test: editing/pasteboard/paste-text-with-style-5.html

  • editing/EditingStyle.cpp:

(WebCore::getPropertiesNotIn):

Location:
trunk
Files:
2 added
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r117359 r117361  
     12012-05-16  Ryosuke Niwa  <rniwa@webkit.org>
     2
     3        REGRESSION(r92823): WebKit strips font-weight: normal from b element when copying
     4        https://bugs.webkit.org/show_bug.cgi?id=86663
     5
     6        Reviewed by Tony Chang.
     7
     8        The bug was caused by removeStyleFromRulesAndContext incorrectly stripping font-weight property
     9        even when the context had no font-weight property because of a property name mismatch in getPropertiesNotIn.
     10
     11        Fixed the mismatch.
     12
     13        Test: editing/pasteboard/paste-text-with-style-5.html
     14
     15        * editing/EditingStyle.cpp:
     16        (WebCore::getPropertiesNotIn):
     17
    1182012-05-16  Ryosuke Niwa  <rniwa@webkit.org>
    219
  • trunk/Source/WebCore/editing/EditingStyle.cpp

    r115215 r117361  
    14941494    diffTextDecorations(result.get(), CSSPropertyWebkitTextDecorationsInEffect, baseTextDecorationsInEffect.get());
    14951495
    1496     if (baseStyle->getPropertyCSSValueInternal(CSSPropertyFontSize) && fontWeightIsBold(result.get()) == fontWeightIsBold(baseStyle))
     1496    if (baseStyle->getPropertyCSSValueInternal(CSSPropertyFontWeight) && fontWeightIsBold(result.get()) == fontWeightIsBold(baseStyle))
    14971497        result->removeProperty(CSSPropertyFontWeight);
    14981498
Note: See TracChangeset for help on using the changeset viewer.