Closed
Bug 1194063
Opened 10 years ago
Closed 10 years ago
Text selection dialog does not disappear after 3 seconds on an empty input
Categories
(Core :: DOM: Selection, defect)
Core
DOM: Selection
Tracking
()
RESOLVED
FIXED
FxOS-S5 (21Aug)
People
(Reporter: TYLin, Assigned: TYLin)
References
(Blocks 1 open bug)
Details
Attachments
(3 files)
Steps to reproduce:
1. Copy some text.
2. Focus on an empty input.
3. The text selection dialog shows with a paste icon.
Actual results:
The dialog does not disappear after 3 seconds.
Expected results:
The dialog should disappear after 3 seconds timeout like it did on non-empty input.
Assignee | ||
Comment 1•10 years ago
|
||
Gaia has a bug that it triggers shortcut timeout in line 181, and cancel the timer in the first line of show() [1]. This causes issue when focusing on an empty input since currently gecko does not send another caretStateChange event after 3 seconds timeout.
Swapping line 181 and 182 should fix this bug. However, I'm thinking about another approach that gecko should send caretStateChange event after 3 seconds timeout on a collapsed selection whether the caret is actually visible to the user or not. In this way, Gaia could completely get rid of the shortcut timeout timer, and Gceko could maintain a consistent state that the first caret has Appearance::None in cursor mode after 3 seconds timeout.
[1] https://github.com/mozilla-b2g/gaia/blob/474784fc494519a0fab866407c0215aacf984ed9/apps/system/js/app_text_selection_dialog.js#L181-L182
Assignee | ||
Comment 2•10 years ago
|
||
If the timer is not launched when the content is empty, the first caret
will always has Appearance::NormalNotShown, which is not consistent with
the behavior when the caret is shown when the content is not empty.
After this patch, Gaia will always receive an update event after 3
seconds timeout. Hence fixed a bug that the shortcut text dialog does
not hide after 3 seconds timeout.
Attachment #8649093 -
Flags: review?(mtseng)
Assignee | ||
Comment 3•10 years ago
|
||
Attachment #8649095 -
Flags: review?(mtseng)
Updated•10 years ago
|
Attachment #8649093 -
Flags: review?(mtseng) → review+
Updated•10 years ago
|
Attachment #8649095 -
Flags: review?(mtseng) → review+
Assignee | ||
Updated•10 years ago
|
Blocks: AccessibleCaret
Assignee | ||
Comment 4•10 years ago
|
||
![]() |
||
Comment 7•10 years ago
|
||
Assignee | ||
Updated•10 years ago
|
Attachment #8649280 -
Flags: review?(timdream)
Updated•10 years ago
|
Attachment #8649280 -
Flags: review?(timdream) → review+
Assignee | ||
Comment 9•10 years ago
|
||
Morris & Tim, thank you for the review.
Please check in the Gaia patch. Thanks.
Keywords: leave-open → checkin-needed
Comment 10•10 years ago
|
||
Status: NEW → RESOLVED
Closed: 10 years ago
status-b2g-master:
--- → fixed
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → FxOS-S5 (21Aug)
You need to log in
before you can comment on or make changes to this bug.
Description
•