mirror of
https://github.com/zen-browser/desktop.git
synced 2026-01-31 00:54:38 +00:00
Center welcome window using moveTo for improved positioning
This commit is contained in:
@@ -524,7 +524,10 @@
|
||||
window.focus();
|
||||
const appWin = window.docShell.treeOwner.QueryInterface(Ci.nsIInterfaceRequestor).getInterface(Ci.nsIAppWindow);
|
||||
appWin.rollupAllPopups();
|
||||
appWin.center(null, true, false);
|
||||
window.moveTo(
|
||||
screen.availLeft + (screen.availWidth - outerWidth) / 2,
|
||||
screen.availTop + (screen.availHeight - outerHeight) / 2
|
||||
);
|
||||
},
|
||||
{ once: true }
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user