1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00
metamask-extension/app/scripts
Thomas Huang f9e4023b04 Fix popup/notification when browser is in fullscreen, primarily on macOS. (#9075)
* Fix popup/notification when browser is in fullscreen, primarily on OSX.

The issue was reported internally via Slack. User was running Mac OSX Chrome in fullscreen mode where Chrome is created in a new Desktop workspace.

The issue reproduced on OSX Chrome in fullscreen/maximized view overrides the explicitly set width and height for `windows.create()`. Possibly not overrides, but creates a window based off of the window that it was created from. Found a related [Chromium bug](https://bugs.chromium.org/p/chromium/issues/detail?id=263092&q=window%20create%20width%20os%3DMac&can=2).
The fullscreen `popup.left` pixel will calculate the window position incorrectly since we set and assume the width of the created window. The incorrect `left` position the window and transition the focus Desktop/Workspace incorrectly and make is seem to lose focus of the new window/workspace. Incidentally this will make the popup full width/height, and create a new workspace for the view, which we have no control over until Chrome
fixes it.

This will check if the popup is 'fullscreen', which it gets passed from the origin window, if so then don't reposition the window. If Chrome fixes the issue we can revert this change.

* Feedback commit

Co-authored-by: Mark Stacey <markjstacey@gmail.com>

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
2020-08-07 16:42:47 -03:00
..
account-import-strategies Clean up "JSON File" import strategy test output (#7855) 2020-01-17 19:59:47 -03:30
controllers Fix typo (#9069) 2020-07-23 18:01:13 -02:30
lib Fix popup/notification when browser is in fullscreen, primarily on macOS. (#9075) 2020-08-07 16:42:47 -03:00
migrations Enable guard-for-in rule (#9000) 2020-07-21 18:40:45 -02:30
platforms Fix callback-return issues (#8996) 2020-07-17 20:19:52 -02:30
background.js Use eslint@6.8.0 (#8978) 2020-07-14 12:50:41 -02:30
chromereload.js Fix console.error references 2016-08-29 17:32:39 -07:00
contentscript.js Use eslint@6.8.0 (#8978) 2020-07-14 12:50:41 -02:30
first-time-state.js Migrate codebase to use ESM (#7730) 2020-01-09 00:04:58 -03:30
inpage.js Define global web3 as non-enumerable (#8634) 2020-05-20 20:18:25 -07:00
metamask-controller.js Fixes MetaMask/metamask-extension#8626 - verifies password on requesting seed phrase (#9063) 2020-08-07 16:42:47 -03:00
phishing-detect.js blacklist -> blocklist; whitelist -> safelist 2020-06-08 17:49:36 -07:00
ui.js Restore state snapshot for Sentry errors (#9028) 2020-07-17 12:09:38 -03:00