[Reland] Remove style spans to follow the styles of the block element (issue 2117663002 by joone.hur@intel.com)

1 view
Skip to first unread message

joon...@intel.com

unread,
Jun 30, 2016, 9:16:00 PM6/30/16
to yo...@chromium.org, chromium...@chromium.org, blink-...@chromium.org
Reviewers: Yosi_UTC9
CL: https://codereview.chromium.org/2117663002/

Message:
Hi yosin@

I fixed the Win8 build break by updating the code as follows:

@@ -833,7 +833,8 @@ static bool
handleStyleSpansBeforeInsertion(ReplacementFragment& fragment, const
// e.g.) editing/execCommand/switch-list-type.html

// editing/deleting/backspace-merge-into-block.html

if (node->computedStyle()->display() == INLINE) {

- if (!(node = enclosingBlock(insertionPos.anchorNode())))

+ node = enclosingBlock(insertionPos.anchorNode());

+ if (!node)

return false;

}




FYI, this is the Win8 build error message:
c:\git\chromium\src\third_party\webkit\source\core\editing\commands\replaceselectioncommand.cpp(836)
: error C2220: warning treated as error - no 'object' file generated
c:\git\chromium\src\third_party\webkit\source\core\editing\commands\replaceselectioncommand.cpp(836)
: warning C4706: assignment within conditional expression

Thanks!

Description:
[Reland] Remove style spans to follow the styles of the block element

Note: The original CL was reverted because of breaking Win8 build:
https://codereview.chromium.org/2109973002/

This CL removes style spans to follow the styles of the block
element(li, pre, td, and h1~6) when the text of the pasted
or merged element becomes a part of the block element.

BUG=226941
TEST=third_party/WebKit/LayoutTests/editing/deleting/backspace-merge-into-block-element.html

Base URL: https://chromium.googlesource.com/chromium/src.git@master

Affected files (+68, -41 lines):
A third_party/WebKit/LayoutTests/editing/deleting/backspace-merge-into-block.html
D third_party/WebKit/LayoutTests/editing/deleting/backspace-merge-into-list-item.html
M third_party/WebKit/LayoutTests/editing/deleting/merge-paragraph-from-p-with-style-3-expected.txt
M third_party/WebKit/Source/core/editing/commands/ReplaceSelectionCommand.cpp


yosin@chromium.org via codereview.chromium.org

unread,
Jul 1, 2016, 4:53:33 AM7/1/16
to joon...@intel.com, blink-...@chromium.org, chromium...@chromium.org
lgtm

lgtm

I'm wander why CQ catches this...

https://codereview.chromium.org/2117663002/

commit-bot@chromium.org via codereview.chromium.org

unread,
Jul 1, 2016, 4:53:49 AM7/1/16
to joon...@intel.com, yo...@chromium.org, commi...@chromium.org, blink-...@chromium.org, chromium...@chromium.org

commit-bot@chromium.org via codereview.chromium.org

unread,
Jul 1, 2016, 4:59:44 AM7/1/16
to joon...@intel.com, yo...@chromium.org, commi...@chromium.org, blink-...@chromium.org, chromium...@chromium.org
Committed patchset #1 (id:1)

https://codereview.chromium.org/2117663002/

commit-bot@chromium.org via codereview.chromium.org

unread,
Jul 1, 2016, 5:01:38 AM7/1/16
to joon...@intel.com, yo...@chromium.org, commi...@chromium.org, blink-...@chromium.org, chromium...@chromium.org
Patchset 1 (id:??) landed as
https://crrev.com/7cd91bcaaf5ef14b3e76465b464902cd864eaea0
Cr-Commit-Position: refs/heads/master@{#403428}

https://codereview.chromium.org/2117663002/
Reply all
Reply to author
Forward
0 new messages