[Webkit-unassigned] [Bug 39291] [Qt] Links are selected on right click by default

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue May 18 07:40:39 PDT 2010


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





--- Comment #2 from Antonio Gomes (tonikitoo) <tonikitoo at webkit.org>  2010-05-18 07:40:38 PST ---
more info here:

WebCore/page/EventHandler.cpp
(...)
#if ENABLE(CONTEXT_MENUS)
bool EventHandler::sendContextMenuEvent(const PlatformMouseEvent& event)
{
  Document* doc = m_frame->document();
  FrameView* v = m_frame->view();
  if (!v)
      return false;
(...)

  // Context menu events shouldn't select text in GTK+ applications or in Chromium.
  // FIXME: This should probably be configurable by embedders. Consider making it a WebPreferences setting.
  // See: https://bugs.webkit.org/show_bug.cgi?id=15279
#if !PLATFORM(GTK) && !PLATFORM(CHROMIUM)
  if (!m_frame->selection()->contains(viewportPos) && 
    // FIXME: In the editable case, word selection sometimes selects content that isn't underneath the mouse.
    // If the selection is non-editable, we do word selection to make it easier to use the contextual menu items
    // available for text selections.  But only if we're above text.
    (m_frame->selection()->isContentEditable() || (mev.targetNode() && mev.targetNode()->isTextNode()))) {
    m_mouseDownMayStartSelect = true; // context menu events are always allowed to perform a selection
    selectClosestWordOrLinkFromMouseEvent(mev);
  }
#endif
(...)

-- 
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