Closed Bug 1336426 Opened 7 years ago Closed 4 years ago

Three finger tap should should use text selection as a source for dict query

Categories

(Core :: Widget: Cocoa, defect, P2)

defect

Tracking

()

VERIFIED FIXED
mozilla76
Tracking Status
firefox76 --- verified

People

(Reporter: stef, Assigned: RSChiang)

Details

(Whiteboard: tpi:+)

Attachments

(1 file)

New York

If I select above and make three finger tap I get results for "New" or "York" on Firefox on my mac but never for "New York". Another example (always "don"): don't
Component: Untriaged → Widget: Cocoa
Product: Firefox → Core
Priority: -- → P2
Whiteboard: tpi:+
It's not just the tap that doesn't work for text selection, but the Cmd+Ctrl+D shortcut as well. The shortcut will only work if your mouse cursor is over a word. And it will work for just that word, not the selected phrase. If your cursor is above a space between words, that space will be looked up in the dictionary.
Assignee: nobody → ren.chiang
Status: NEW → ASSIGNED

So I whipped up a patch upon the latest Nightly build, tested against macOS 10.14.6.

Upon applying this patch, user selected text would be honored in force-press dictionary lookup if the cursor position is within current selection. This is the behavior that native TextEdit.app has exhibited.

(CC :masayuki for reviewing the patch!)

Flags: needinfo?(masayuki)
Flags: needinfo?(masayuki)
Attachment #9115741 - Attachment description: Bug 1336426: Query selected text before calling word breaker → Bug 1336426 - Query selected text before calling word breaker.
Pushed by ccoroiu@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/f56cb5f07338
Query selected text before calling word breaker. r=masayuki,m_kato
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla76
Flags: qe-verify+

Reproduced this issue on macOS 10.15, on an affected Nightly build 2020-03-20.

The issue is verified as fixed on latest Beta 76.0b4. The issue is not reproducing anymore when using both, the shortcut or the three finger option.

Status: RESOLVED → VERIFIED
Flags: qe-verify+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: