Last Comment Bug 421644 - Firefox saves wrong window restore size while closing a full screen mode window.
: Firefox saves wrong window restore size while closing a full screen mode window.
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: Widget: Win32 (show other bugs)
: Trunk
: x86 Windows XP
: -- normal (vote)
: ---
Assigned To: Nobody; OK to take it and work on it
:
: Jim Mathies [:jimm]
Mentors:
: 440343 (view as bug list)
Depends on: 398907
Blocks:
  Show dependency treegraph
 
Reported: 2008-03-07 19:24 PST by Biju
Modified: 2011-05-24 13:58 PDT (History)
12 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments

Description Biju 2008-03-07 19:24:36 PST
+++ This bug was initially created as a clone of Bug #398907 +++
This is similar to bug 398907, but now for full screen mode window.

Firefox saves wrong window restore size and window position while closing a full screen mode window.

Current logic is making restore window button useless. Which is too irritating.

This was tested on windows.

Steps:-
1. Exit Firefox, to close all Firefox instance.
2. Re-Start Firefox, to get a single Firefox window.
3. Re-Size window to 60% size of screen display.
4. Reposition window 10% away from top and left.
6. Exit Firefox, then Re-Start Firefox.
7. You can see Firefox remember window state, 
   size and position correctly.
   (ie, restore state, size 60%, 10% from top/left) 
6. Now press f11 to make full screen mode window.
   (remember not to change position/size
     when it is still in restore state)
7. Exit Firefox, then Re-Start Firefox.
8. You can see Firefox in restored window state,
   But.....

Result:-
--------
  You can see 
  * size is almost 100% of screen size, like maximized
  * position almost left, top of screen size


Expected:-
---------
  * size 60% of screen size
  * position at 10% from top/left of screen.



What to be done:-
---------------
We should use following common logic.

function onExitApplication(){
  switch(window.state){

    'maxmized' : 
       save_window_state('maxmized');
       break;

    'normal' :   /*ie, restored state*/ 
       save_window_state('normal');
       save_window_size(window.width, window.height);
       save_window_position(window.left, window.top);
       break;

    'minimized' : 
    'fullscreen' : 
    'systray' : 
    'dialog' : 
    'chrome' : 
    default :
        /*save nothing*/ 
  }  
}

Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9b5pre) 
Gecko/2008030607 Minefield/3.0b5pre
Comment 1 Ria Klaassen (not reading all bugmail) 2008-06-19 12:22:28 PDT
*** Bug 440343 has been marked as a duplicate of this bug. ***
Comment 2 Robert Strong [:rstrong] (use needinfo to contact me) 2011-04-28 23:43:27 PDT
Not a shell integration bug (e.g. protocol registration, default browser check, etc.). Moving over to widget
Comment 3 Jim Mathies [:jimm] 2011-05-24 13:58:22 PDT
win7:
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:6.0a1) Gecko/20110522 Firefox/6.0a1

WFM - we fixed this in 4.0.

Note You need to log in before you can comment on or make changes to this bug.