Closed Bug 1204944 Opened 9 years ago Closed 9 years ago

Tab drag-rearrangement doesn't appear to work in Nightly w/e10s on OSX

Categories

(Firefox :: Tabbed Browser, defect, P2)

All
macOS
defect
Points:
1

Tracking

()

RESOLVED FIXED
Firefox 44
Tracking Status
e10s m8+ ---
firefox43 --- affected
firefox44 --- fixed

People

(Reporter: jfrench, Assigned: enndeakin)

References

Details

Attachments

(2 files)

When I attempt to re-order two tabs in today's Nightly build when running e10s, the page thumbnail that appears, prevents me from re-ordering the tab.

To reproduce:
o run Nightly (43.0a1 (2015-09-15))
o Create a 2nd tab
o LMB-click and try to drag the 2nd tab in front of the first tab

Expected behaviour:
The same as Firefox Release, the selected tab would appear as a semi-transparent thumbnail and slide over to accommodate the dragged tab.

Observed:
The selected tab thumbnail is larger and opaque, and no tab switch occurs.

Workaround:
Disable e10s in Preferences.

Configuration:
OSX 10.10.5 (14F27)
MacBookPro Retina 15-inch
2.6 GHz Intel Core i7
16 GB 1600 MHz DDR3
NVIDIA GeForce GT 750M 2048 MB

Apologies if this is a dupe, but I didn't see any suggested bugs appear during entry, other than a variant bug 1164892.
Flags: needinfo?(wmccloskey)
Attached image tabDragNightly_e10s
Per screen grab.
I suspect this is fallout from bug 1202176.
Blocks: 1202176
Flags: needinfo?(enndeakin)
This is a problem for me but only on the "right half" of the screen.  I'm guessing this is a hidpi only issue?
See Also: → 1203820
I think Mike is a better person to triage this.
Flags: needinfo?(wmccloskey)
Attached patch PatchSplinter Review
This seems to work, but I'm not sure why the CocoaPointsToDevPixels is needed. The other two places within nsChildView.mm where [NSEvent mouseLocation] is used don't seem to need that conversion.
Assignee: nobody → enndeakin
Status: NEW → ASSIGNED
Flags: needinfo?(enndeakin)
Attachment #8661833 - Flags: feedback?(mstange)
Points: --- → 1
Seems this code could benefit from using the typed units; it's clearly a unit issue (the original one as well), but even fully correct, it isn't obvious from the code that it's correct.  I'm sure a separate bug, just wanted to draw Botond's attention to it.
Flags: needinfo?(botond)
Looks to me like the following quantities would benefit from being typed:

  (1) nsIDragService.dragMoved() should take its arguments in LayoutDevice pixels
  (2) nsMenuPopupFrame::MoveTo() should take its arguments in CSS pixels
  (3) nsBaseDragService::mImage[X|Y] should be in CSS pixels

We should easily be able to do (2) and (3). We can't do (1) in code because it's IDL and IDL doesn't support typed units, but we can at least document it in a comment.
Flags: needinfo?(botond)
See Also: → 1205511
Thanks, and I see the bug opened for it.  All, sorry for the distraction :)
(In reply to Neil Deakin from comment #6)
> This seems to work, but I'm not sure why the CocoaPointsToDevPixels is
> needed. The other two places within nsChildView.mm where [NSEvent
> mouseLocation] is used don't seem to need that conversion.

That's strange, they should probably have the conversion as well. Can you find out why it works without one, or whether (and if so, why) anything breaks if you add the conversion to the other two places?
(In reply to Markus Stange [:mstange] from comment #10)
> (In reply to Neil Deakin from comment #6)
> > This seems to work, but I'm not sure why the CocoaPointsToDevPixels is
> > needed. The other two places within nsChildView.mm where [NSEvent
> > mouseLocation] is used don't seem to need that conversion.
> 
> That's strange, they should probably have the conversion as well. Can you
> find out why it works without one, or whether (and if so, why) anything
> breaks if you add the conversion to the other two places?

It looks like the case for SetDragEndPoint is correct as is, or at least, the dragend coordinates are correct if the code is unchanged, and adding a call to CocoaPointsToDevPixels results in incorrect values for event.screenX/Y in the dragend event.
The code here assigns the coordinates from [NSEvent mouseLocation] to event.refPoint.

The Rollup case looks incorrect however. Clicking the searchbox while the popup is open should leave it open, but works ok if I convert using CocoaPointsToDevPixels first.
Comment on attachment 8661833 [details] [diff] [review]
Patch

Anyway, I think this part is ok.
Attachment #8661833 - Flags: feedback?(mstange) → review?(mstange)
Attachment #8661833 - Flags: review?(mstange) → review+
https://hg.mozilla.org/mozilla-central/rev/aa7c3ce047ad
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 44
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: