bug-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[ 102031 ] mproving application startup visual appe


From: nobody
Subject: [ 102031 ] mproving application startup visual appe
Date: Sun, 06 Apr 2003 23:02:06 -0400


Support Request #102031, was updated on Sun 04/06/2003 at 21:02
You can respond by visiting: 
http://savannah.gnu.org/support/?func=detailsupport&support_id=102031&group_id=99

Category: AppKit
Status: Open
Priority: 5
Summary: mproving application startup visual appe

By: fedor
Date: Sun 04/06/2003 at 21:02
Logged In: YES 
user_id=328
Browser: Mozilla/5.0 (X11; U; Linux ppc; en-US; rv:1.1) Gecko/20020905

Subject: Improving application startup visual appeareance
Date: Mon, 17 Mar 2003 22:55:39 -0800 (PST)
From: Michael Hanni <michael@deviant-behavior.com>
To: bug-gnustep@gnu.org

Hi,

On a slow machine -- like mine -- an application like
GWorkspace takes quite
some time to load. During the loading process I get an
empty white menu window
and app icon window which are not "drawn" until the
main loop kicks in. I've
attached a small patch which adds a [NSView
displayIfNeeded] call right after
the orderFrontRegardless call for both the menus and
app icon windows.
(Afterwards because if I do it before the drawRect has
no effect. I didn't
trace the reasons for this out.) This has the effect of
making both appear
visually immediately. I really think this effect is
quite nice...

Index: NSApplication.m
===================================================================
RCS file:
/cvsroot/gnustep/gnustep/core/gui/Source/NSApplication.m,v
retrieving revision 1.233
diff -u -r1.233 NSApplication.m
--- NSApplication.m     7 Mar 2003 09:04:54 -0000     
 1.233
+++ NSApplication.m     18 Mar 2003 06:16:05 -0000
@@ -2500,9 +2500,14 @@
   iv = [[NSAppIconView alloc] initWithFrame:
NSMakeRect(0,0,64,64)];
   [iv setImage: _app_icon];
   [_app_icon_window setContentView: iv];
-  RELEASE(iv);
 
   [_app_icon_window orderFrontRegardless];
+
+  // Display our view immediately. This makes the
appIconWindow and the 
+  // view come up together.
+  [iv displayIfNeeded];
+  RELEASE(iv);
+
   return self;
 }
 
Index: NSMenu.m
===================================================================
RCS file:
/cvsroot/gnustep/gnustep/core/gui/Source/NSMenu.m,v
retrieving revision 1.112
diff -u -r1.112 NSMenu.m
--- NSMenu.m    8 Mar 2003 11:47:31 -0000       1.112
+++ NSMenu.m    18 Mar 2003 06:29:26 -0000
@@ -1225,6 +1225,9 @@
        }
     }
   [_aWindow orderFrontRegardless];
+
+  // Force the display of the view so the window is
never left blank.
+  [_view displayIfNeeded];
 }



----------------------------------------------------------------------
You can respond by visiting: 
http://savannah.gnu.org/support/?func=detailsupport&support_id=102031&group_id=99




reply via email to

[Prev in Thread] Current Thread [Next in Thread]