Changeset 63865 in webkit


Ignore:
Timestamp:
Jul 21, 2010, 5:36:38 PM (14 years ago)
Author:
jschuh@chromium.org
Message:

2010-07-21 Justin Schuh <jschuh@chromium.org>

Reviewed by Oliver Hunt.

Prevent DeleteButtonController enable state from changing when not editing
https://bugs.webkit.org/show_bug.cgi?id=42659

Test: svg/custom/use-invalid-html.xhtml

  • dom/ContainerNode.cpp: (WebCore::ContainerNode::cloneChildNodes):

2010-07-21 Justin Schuh <jschuh@chromium.org>

Reviewed by Oliver Hunt.

Prevent DeleteButtonController enable state from changing when not editing
https://bugs.webkit.org/show_bug.cgi?id=42659

  • svg/custom/use-invalid-html-expected.txt: Added.
  • svg/custom/use-invalid-html.xhtml: Added.
Location:
trunk
Files:
2 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r63864 r63865  
     12010-07-21  Justin Schuh  <jschuh@chromium.org>
     2
     3        Reviewed by Oliver Hunt.
     4
     5        Prevent DeleteButtonController enable state from changing when not editing
     6        https://bugs.webkit.org/show_bug.cgi?id=42659
     7
     8        * svg/custom/use-invalid-html-expected.txt: Added.
     9        * svg/custom/use-invalid-html.xhtml: Added.
     10
    1112010-07-21  Beth Dakin  <bdakin@apple.com>
    212
  • trunk/WebCore/ChangeLog

    r63864 r63865  
     12010-07-21  Justin Schuh  <jschuh@chromium.org>
     2
     3        Reviewed by Oliver Hunt.
     4
     5        Prevent DeleteButtonController enable state from changing when not editing
     6        https://bugs.webkit.org/show_bug.cgi?id=42659
     7
     8        Test: svg/custom/use-invalid-html.xhtml
     9
     10        * dom/ContainerNode.cpp:
     11        (WebCore::ContainerNode::cloneChildNodes):
     12
    1132010-07-21  Beth Dakin  <bdakin@apple.com>
    214
  • trunk/WebCore/dom/ContainerNode.cpp

    r63633 r63865  
    695695{
    696696    // disable the delete button so it's elements are not serialized into the markup
    697     if (document()->frame())
     697    bool isEditorEnabled = document()->frame() && document()->frame()->editor()->canEdit();
     698    if (isEditorEnabled)
    698699        document()->frame()->editor()->deleteButtonController()->disable();
    699700    ExceptionCode ec = 0;
    700701    for (Node* n = firstChild(); n && !ec; n = n->nextSibling())
    701702        clone->appendChild(n->cloneNode(true), ec);
    702     if (document()->frame())
     703    if (isEditorEnabled && document()->frame())
    703704        document()->frame()->editor()->deleteButtonController()->enable();
    704705}
Note: See TracChangeset for help on using the changeset viewer.