Closed Bug 1139803 Opened 10 years ago Closed 10 years ago

(CopyPasteTest) Test case for selection utility bubble hide/show when scroll start/end

Categories

(Core :: DOM: Selection, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: chenpighead, Assigned: chenpighead)

References

Details

Attachments

(1 file, 4 obsolete files)

test case for Bug 1020801
Version: 37 Branch → unspecified
Assignee: nobody → jeremychen
Attached patch Gaia JS integration test wip (obsolete) — Splinter Review
In this bug, I try to produce a scrolling scenario and get the visibility of utility bubble before/after scroll end. I've written a draft wip and met some problems. Initially, I want to use "action.press().moveByOffset().perform();" for the scrolling scenario, but it failed to work on b2g desktop client. Then, I tried "action.press().move().perform();" instead. It worked on b2g desktop. But, on b2g desktop, it will fire scroll end automatically whenever we stop scrolling, even we're not yet called "action.release().perform()". Another issue on b2g desktop is that the utility bubble is always shown during the scrolling. So, I moved on to run the wip on device. However, the wip, which is able to produce a scrolling scenario on b2g desktop, is failed to do that on device. George, could you take a look and give me some feedback?
Flags: needinfo?(gduan)
George, It seems that I wrongly use the function moveByOffset by sending the wrong args. Now, I can use following code to make scroll happen both on b2g desktop and device. action.press(fakeTextselectionApp.BugContent, 100, 150).moveByOffset(0, -50).perform(); But, it still fires touchend automatically even though action.release().perform is not called yet. Kind of stuck here. Any idea?
Flags: needinfo?(gduan)
Flags: needinfo?(gduan)
Hey Jeremy, sorry, I have no idea for that, basically js marionette should behave the same as py marionette. could you update your patch as comment 2? How do I know if touchend is fired or not? I would like to verify it and find someone to deeply look into marionette.
Flags: needinfo?(gduan) → needinfo?(jeremychen)
Attached patch Gaia JS integration test wip (obsolete) — Splinter Review
In this patch, I can make scroll happen by moveByOffset() on b2g desktop. For the automatically sending touchend event issue, I kind of figure it out by discussing with Morris and TYLin. During scrolling, since we don't know when a scroll is ended or not, there is a timeout interval (seems =300ms) for APZ to send scrollend event automatically. STR: 1. Run b2g desktop 2. Open "UI test" app and get into "copy test API" 3. Select some text 4. Start scroll and keep mouse down on screen. Expect: Bubble is hidden. Actual: Bubble is shown.
Attachment #8573176 - Attachment is obsolete: true
Flags: needinfo?(jeremychen)
(In reply to George Duan [:gduan] [:喬智] from comment #3) > Hey Jeremy, > sorry, I have no idea for that, basically js marionette should behave the > same as py marionette. > could you update your patch as comment 2? How do I know if touchend is fired > or not? I would like to verify it and find someone to deeply look into > marionette. I kind of figure out why the touchend is fired automatically. It turns out that since APZ is not enabled on b2g desktop yet (see bug 1131237), we handle scroll event and set caret to invisible in another code flow. (https://dxr.mozilla.org/mozilla-central/source/layout/base/SelectionCarets.cpp?from=SelectionCarets.cpp#1200) Accordingly, I think this may not be a bug. After discussed with Morris and George, I'm going to work on another patch. Thanks to George's work in Bug 1141406, it won't take long.
Depend on Bug1141406. I'll send pull request after patch for Bug1141406 landed.
Attachment #8574535 - Attachment is obsolete: true
Depends on: 1141406
Attachment #8578571 - Attachment is obsolete: true
Comment on attachment 8582908 [details] [review] [gaia] chenpighead:Bug1139803 > mozilla-b2g:master Hi George, I use the patch in Bug 1141406 to write this test. Could you check this patch for JS integration test?
Attachment #8582908 - Flags: review?(gduan)
Comment on attachment 8582908 [details] [review] [gaia] chenpighead:Bug1139803 > mozilla-b2g:master r=gduan
Attachment #8582908 - Flags: review?(gduan) → review+
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Attachment #8585924 - Flags: review?(gduan)
Attachment #8582908 - Attachment is obsolete: true
Comment on attachment 8585924 [details] [review] [gaia] chenpighead:Bug1139803 > mozilla-b2g:master plz land it once treeherder is green! r=gduan
Attachment #8585924 - Flags: review?(gduan) → review+
Keywords: checkin-needed
Keywords: checkin-needed
Autolander could not locate a review from a user within the suggested reviewer list. Either the patch author or the reviewer should be in the suggested reviewer list.
Hi George, can you help check-in this patch? I've no idea why Autolander is not working...
Flags: needinfo?(gduan)
Keywords: checkin-needed
Keywords: checkin-needed
Autolander could not locate a review from a user within the suggested reviewer list. Either the patch author or the reviewer should be in the suggested reviewer list.
Attachment #8582908 - Attachment is obsolete: false
Attachment #8582908 - Attachment is obsolete: true
Status: REOPENED → RESOLVED
Closed: 10 years ago10 years ago
Flags: needinfo?(gduan)
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: