Changeset 77985 in webkit


Ignore:
Timestamp:
Feb 8, 2011 3:59:30 PM (13 years ago)
Author:
aestes@apple.com
Message:

2011-02-08 Andy Estes <aestes@apple.com>

Reviewed by Darin Adler.

REGRESSION (r76301): 'plaintext-only' must be a supported contentEditable mode.
https://bugs.webkit.org/show_bug.cgi?id=54041

  • html/HTMLElement.cpp: (WebCore::HTMLElement::setContentEditable): Setting the contentEditable attribute to 'plaintext-only' should not throw an exception.

2011-02-08 Andy Estes <aestes@apple.com>

Reviewed by Darin Adler.

REGRESSION (r76301): 'plaintext-only' must be a supported contentEditable mode.
https://bugs.webkit.org/show_bug.cgi?id=54041

  • fast/dom/HTMLElement/set-value-caseinsensitive-expected.txt:
  • fast/dom/HTMLElement/set-value-caseinsensitive.html:
Location:
trunk
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r77982 r77985  
     12011-02-08  Andy Estes  <aestes@apple.com>
     2
     3        Reviewed by Darin Adler.
     4
     5        REGRESSION (r76301): 'plaintext-only' must be a supported contentEditable mode.
     6        https://bugs.webkit.org/show_bug.cgi?id=54041
     7
     8        * fast/dom/HTMLElement/set-value-caseinsensitive-expected.txt:
     9        * fast/dom/HTMLElement/set-value-caseinsensitive.html:
     10
    1112011-02-08  Martin Robinson  <mrobinson@igalia.com>
    212
  • trunk/LayoutTests/fast/dom/HTMLElement/set-value-caseinsensitive-expected.txt

    r76528 r77985  
    22
    33On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
     4
    45
    56
     
    2223PASS document.getElementById("p2").isContentEditable is true
    2324PASS window.getComputedStyle(p2, "").getPropertyValue("-webkit-user-modify") is "read-write"
     25PASS document.getElementById("div3").hasAttribute("contentEditable") is true
     26PASS document.getElementById("div3").contentEditable is "plaintext-only"
     27PASS document.getElementById("div3").isContentEditable is true
     28PASS window.getComputedStyle(div3, "").getPropertyValue("-webkit-user-modify") is "read-write-plaintext-only"
     29PASS document.getElementById("p3").hasAttribute("contentEditable") is false
     30PASS document.getElementById("p3").contentEditable is "inherit"
     31PASS document.getElementById("p3").isContentEditable is true
     32PASS window.getComputedStyle(p3, "").getPropertyValue("-webkit-user-modify") is "read-write-plaintext-only"
    2433
    2534PASS successfullyParsed is true
  • trunk/LayoutTests/fast/dom/HTMLElement/set-value-caseinsensitive.html

    r76528 r77985  
    1414    <p id="p2" contenteditable="false"></p>
    1515</div>
     16<div id="div3" contenteditable="true">
     17    <p id="p3" contenteditable="false"></p>
     18</div>
    1619<script>
    1720description('When contentEditable is set to a new value, the new value can be case-insensitive.')
     
    2023document.getElementById("p1").contentEditable = "faLSE";
    2124document.getElementById("p2").contentEditable = "inHERIT";
     25document.getElementById("div3").contentEditable = "PlainText-Only"
     26document.getElementById("p3").contentEditable = "Inherit"
    2227
    2328shouldBe('document.getElementById("div1").getAttribute("contentEditable")','"true"');
     
    3742shouldBe('window.getComputedStyle(p2, "").getPropertyValue("-webkit-user-modify")', '"read-write"');
    3843
     44shouldBe('document.getElementById("div3").hasAttribute("contentEditable")','true');
     45shouldBe('document.getElementById("div3").contentEditable', '"plaintext-only"');
     46shouldBe('document.getElementById("div3").isContentEditable', 'true');
     47shouldBe('window.getComputedStyle(div3, "").getPropertyValue("-webkit-user-modify")', '"read-write-plaintext-only"');
     48
     49shouldBe('document.getElementById("p3").hasAttribute("contentEditable")','false');
     50shouldBe('document.getElementById("p3").contentEditable', '"inherit"');
     51shouldBe('document.getElementById("p3").isContentEditable', 'true');
     52shouldBe('window.getComputedStyle(p3, "").getPropertyValue("-webkit-user-modify")', '"read-write-plaintext-only"');
     53
    3954document.getElementById("div1").style.display= 'none';
    4055document.getElementById("p1").style.display= 'none';
    4156document.getElementById("div2").style.display= 'none';
     57document.getElementById("div3").style.display= 'none';
     58
    4259
    4360window.successfullyParsed = true;
  • trunk/Source/WebCore/ChangeLog

    r77984 r77985  
     12011-02-08  Andy Estes  <aestes@apple.com>
     2
     3        Reviewed by Darin Adler.
     4
     5        REGRESSION (r76301): 'plaintext-only' must be a supported contentEditable mode.
     6        https://bugs.webkit.org/show_bug.cgi?id=54041
     7
     8        * html/HTMLElement.cpp:
     9        (WebCore::HTMLElement::setContentEditable): Setting the contentEditable
     10        attribute to 'plaintext-only' should not throw an exception.
     11
    1122011-02-08  Dan Bernstein  <mitz@apple.com>
    213
  • trunk/Source/WebCore/html/HTMLElement.cpp

    r76301 r77985  
    736736    else if (equalIgnoringCase(enabled, "false"))
    737737        setAttribute(contenteditableAttr, "false", ec);
     738    else if (equalIgnoringCase(enabled, "plaintext-only"))
     739        setAttribute(contenteditableAttr, "plaintext-only");
    738740    else if (equalIgnoringCase(enabled, "inherit"))
    739741        removeAttribute(contenteditableAttr, ec);
Note: See TracChangeset for help on using the changeset viewer.