Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixes firefox popup location #8467

Merged
merged 2 commits into from
Apr 29, 2020
Merged

fixes firefox popup location #8467

merged 2 commits into from
Apr 29, 2020

Conversation

brad-decker
Copy link
Contributor

Found that firefox doesn't have the proper popup location, but that's because firefox doesn't respect top and left on windows.create. https://bugzilla.mozilla.org/show_bug.cgi?id=1271047

It does, however, respect windows.update. This PR adds a method for moving the popup window if popupWindow.left !== left. Has a flash of the popup opening wherever firefox says it should, but ends up in the right place.

fowm

@brad-decker brad-decker requested a review from a team as a code owner April 29, 2020 20:35
@brad-decker brad-decker requested a review from Gudahtt April 29, 2020 20:35
Copy link
Contributor

@whymarrh whymarrh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One small suggestion but this looks like a decent solution

app/scripts/platforms/extension.js Outdated Show resolved Hide resolved
@brad-decker brad-decker force-pushed the firefox-modal-positioning branch from 8f42ab8 to 6b872e3 Compare April 29, 2020 21:08
@brad-decker brad-decker requested a review from whymarrh April 29, 2020 21:17
@brad-decker
Copy link
Contributor Author

Changed that up, @whymarrh, thanks for the suggestion

Copy link
Member

@Gudahtt Gudahtt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great find! Yet another Firefox bug to follow.

That flash of the popup being in the wrong spot is unfortunate, but this is still probably better than leaving it positioned incorrectly. That was especially painful on multi-monitor computers.

Copy link
Contributor

@whymarrh whymarrh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@metamaskbot
Copy link
Collaborator

Builds ready [6b872e3]
Page Load Metrics (642 ± 42 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint318438126
domContentLoaded3328456408842
load3368466428842
domInteractive3318446398842

@brad-decker brad-decker merged commit 0c7269f into develop Apr 29, 2020
@brad-decker brad-decker deleted the firefox-modal-positioning branch April 29, 2020 22:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants