Closed Bug 490873 Opened 16 years ago Closed 16 years ago

Dragging in chrome causes an extra click event to be sent at end of drag

Categories

(Firefox for Android Graveyard :: General, defect)

defect
Not set
normal

Tracking

(fennec1.0b2+)

VERIFIED FIXED
Tracking Status
fennec 1.0b2+ ---

People

(Reporter: bcombee, Assigned: bcombee)

References

Details

Attachments

(1 file, 5 obsolete files)

Noticed by gavin, needs to be fixed for beta 2.
This works by changing our ignoreNextClick one-time flag into an allowNextClick one-time flag. We set it both when we generate a click or when we get a mouseUp not related to a pan. I've tested with bookmarks, awesomebar, and URL bar.
Attachment #375211 - Flags: review?(mark.finkle)
Attachment #375211 - Flags: review?(gavin.sharp)
This patch applies on top of Brad's patch in bug 441585
Status: NEW → ASSIGNED
Depends on: 441585
Attachment #375211 - Flags: review?(mark.finkle) → review+
Comment on attachment 375211 [details] [diff] [review] Remove extra click on end of a drag inside chrome Gavin found a problem -- this prevents clicking in content! I'm working on it.
Attachment #375211 - Flags: review+ → review-
A little more code change than I originally thought, but I noticed issues with data members being defined in the prototypes, so I cleaned that up while moving things around. This requires the new version of the drag patch; I updated that about 15 minutes ago.
Attachment #375211 - Attachment is obsolete: true
Attachment #375266 - Flags: review?(gavin.sharp)
Attachment #375211 - Flags: review?(gavin.sharp)
Attachment #375266 - Attachment is obsolete: true
Attachment #375675 - Flags: review?(gavin.sharp)
Attachment #375266 - Flags: review?(gavin.sharp)
Attachment #375675 - Attachment is obsolete: true
Attachment #375886 - Flags: review?(gavin.sharp)
Attachment #375675 - Flags: review?(gavin.sharp)
Attached patch Update to apply to trunk (obsolete) — Splinter Review
Attachment #375886 - Attachment is obsolete: true
Attachment #376257 - Flags: review?(pavlov)
Attachment #375886 - Flags: review?(gavin.sharp)
The patch does two things: 1) Change the click handling so the InputHandler only allows a click through when it's been requested. This solves the problem with extra clicks in chrome. 2) fixes some leftover issues with data items being declared in the prototypes for classes
tracking-fennec: --- → ?
The reason this patch updates the top-level InputHandler is because of a cascading event problem. If we only do click prevention in ChromeInputHandler, then we have the potential of capturing a click that's intended for content. However, I didn't want to change ChromeInputHandler to filter out events that are destined for content as that means there's more coupling between this class and ContentDragHandler. Therefore, to solve the problem, I push clicking up into InputHandler so it becomes a privileged event that's always filtered out unless the click is intended to go through. Content handler generates clicks, so it can allow them. Chrome handler also generates clicks, so it can allow them too. It's not really ideal. I think to fix this better we'd need to add a whole filter mechanism to InputHandler to control the scope of what handlers saw what events. This starts to sound like we're reinventing the whole event bubbling mechanism though.
Flags: wanted-fennec1.0?
Attachment #376257 - Flags: review?(pavlov) → review+
tracking-fennec: ? → 1.0b2+
Attachment #376257 - Attachment is obsolete: true
Comment on attachment 380866 [details] [diff] [review] Update for tree rot carrying stuart's r+
Attachment #380866 - Flags: review+
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
verified FIXED checking R<->L scroll on the search bar on builds: Mozilla/5.0 (X11; U; Linux armv6l; en-US; rv:1.9.3a1pre) Gecko/20090821 Fennec/1.0b3pre and Mozilla/5.0 (Macintosh; U; Intel Mac OSX 10.5; en-US; rv:1.9.2a2pre) Gecko/20090808 Fennec/1.0b3pre
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: