Skip to content

Commit

Permalink
Edit window gets restored smaller on Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
JasonBarnabe committed Dec 1, 2014
1 parent 77bc7dc commit 7881d7a
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions content/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,8 @@ const CSSHTMLNS = "@namespace url(http://www.w3.org/1999/xhtml);";
// Only do this if we're opened with openDialog, in which case window.opener is set
if (window.opener) {
var windowPersist = JSON.parse(prefs.getCharPref("editorWindowPersist"));
var de = document.documentElement;
de.width = windowPersist.width;
de.height = windowPersist.height;
window.moveTo(windowPersist.screenX, windowPersist.screenY);
window.resizeTo(windowPersist.width, windowPersist.height);
if (windowPersist.windowState == 1) {
//https://bugzilla.mozilla.org/show_bug.cgi?id=1079962
window.addEventListener("load", function() {
Expand All @@ -45,8 +43,8 @@ if (window.opener) {
// this can fail if this is in a tab. if so, don't save.
try {
windowPersist = {
width: document.width,
height: document.height,
width: window.outerWidth,
height: window.outerHeight,
screenX: window.screenX,
screenY: window.screenY
}
Expand Down

0 comments on commit 7881d7a

Please sign in to comment.