[Webkit-unassigned] [Bug 50116] On platforms other than Mac, right clicking anywhere discards the selection

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Dec 17 11:34:51 PST 2010


https://bugs.webkit.org/show_bug.cgi?id=50116





--- Comment #26 from Ryosuke Niwa <rniwa at webkit.org>  2010-12-17 11:34:51 PST ---
(From update of attachment 76212)
View in context: https://bugs.webkit.org/attachment.cgi?id=76212&action=review

> WebCore/editing/EditingBehavior.h:64
> +    // On Linux, right clicking outside of the current selection shouldn't discard the existing selection
> +    bool shouldDiscardCurrentSelectionOnRightClick() const { return m_type != EditingUnixBehavior; }

Nit: since editing behavior is "unix", we should probably say "On UNIX, right clicking..."

> WebCore/page/EventHandler.cpp:403
> +    // Don't alter the selection for buttons other than the left button unless it's desired behavior

Nit: I don't think this comment is necessary.  It repeats what code says.

> WebCore/page/EventHandler.cpp:405
> +    if (m_frame->selection()->shouldChangeSelection(newSelection) && shouldReplaceSelection)

I'm not sure if we want to call editing delegates if we're not changing the selection.  It's odd to call editing delegates to ask if the selection should change and then not changing regardless of what the delegates returns.  We should probably swap the order and do: shouldReplaceSelection && m_frame->selection()->shouldChangeSelection(newSelection).

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list