[webkit-reviews] review denied: [Bug 51653] Text selection code shouldn't be invoked when -webkit-user-select is none : [Attachment 77519] Patch
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Dec 28 13:58:47 PST 2010
Eric Seidel <eric at webkit.org> has denied Noam Rosenthal
<noam.rosenthal at nokia.com>'s request for review:
Bug 51653: Text selection code shouldn't be invoked when -webkit-user-select is
none
https://bugs.webkit.org/show_bug.cgi?id=51653
Attachment 77519: Patch
https://bugs.webkit.org/attachment.cgi?id=77519&action=review
------- Additional Comments from Eric Seidel <eric at webkit.org>
View in context: https://bugs.webkit.org/attachment.cgi?id=77519&action=review
Good idea, we should just clean this up slightly.
> WebCore/page/EventHandler.cpp:617
> + // Don't modify the selection for nodes with -webkit-user-select: none.
> + const RenderStyle* style = targetRenderer->style();
> + const EUserSelect userSelect = style->userSelect();
> + if (userSelect == SELECT_NONE) {
> + const RenderStyle* styleForFirstLine =
targetRenderer->firstLineStyle();
> + if (styleForFirstLine == style || styleForFirstLine->userSelect() ==
SELECT_NONE)
> + return;
> + }
This feels like a separate (private or static) function.
if (!selectionEnabled())
return;
or something like that, no?
More information about the webkit-reviews
mailing list