[Webkit-unassigned] [Bug 26900] AX: Manual spell check with Command-; does not bring up suggestions
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Wed Jul 1 14:45:47 PDT 2009
https://bugs.webkit.org/show_bug.cgi?id=26900
bdakin at apple.com changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #32142|review? |review+
Flag| |
------- Comment #2 from bdakin at apple.com 2009-07-01 14:45 PDT -------
(From update of attachment 32142)
> +IntPoint AccessibilityRenderObject::clickPoint() const
> +{
> + // if we're asked to perform a show menu on an editable web area,
> + // the click point should be where the selection is
> + if (isWebArea() && !isReadOnly()) {
> + VisibleSelection visSelection = selection();
> + VisiblePositionRange range = VisiblePositionRange(visSelection.visibleStart(), visSelection.visibleEnd());
> + IntRect bounds = boundsForVisiblePositionRange(range);
> +#if PLATFORM(MAC)
> + bounds.setLocation(m_renderer->document()->view()->screenToContents(bounds.location()));
> +#endif
> + return IntPoint(bounds.x() + (bounds.width() / 2), bounds.y() - (bounds.height() / 2));
> + }
> +
> + return AccessibilityObject::clickPoint();
> +}
This is just a style nit-pick, but how about you do the generic case as an
early return like:
if (!isWebArea() || isReadOnly())
return AccessibilityObject::clickPoint();
VisibleSelection visSelection = selection();
r=me!
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
More information about the webkit-unassigned
mailing list