remove the --managed option

Dimitrie O. Paun dpaun at rogers.com
Wed May 22 00:09:41 CDT 2002


As promised long ago :)
I was away for a little while.

ChangeLog:
  Remove the --managed option, and make wine
use the managed mode by default.

Index: dlls/x11drv/event.c
===================================================================
RCS file: /var/cvs/wine/dlls/x11drv/event.c,v
retrieving revision 1.1
diff -u -r1.1 event.c
--- dlls/x11drv/event.c	30 Apr 2002 21:16:39 -0000	1.1
+++ dlls/x11drv/event.c	22 May 2002 05:05:54 -0000
@@ -376,12 +376,11 @@
 
     bIsDisabled = GetWindowLongA( hWnd, GWL_STYLE ) & WS_DISABLED;
 
-    /* If the window has been disabled and we are in managed mode,
-       * revert the X focus back to the last focus window. This is to disallow
-       * the window manager from switching focus away while the app is
-       * in a modal state.
-       */
-    if ( Options.managed && bIsDisabled && glastXFocusWin)
+    /* If the window has been disabled, revert the X focus back to the last
+     * focus window. This is to disallow the window manager from switching 
+     * focus away while the app is in a modal state.
+     */
+    if (bIsDisabled && glastXFocusWin)
     {
         /* Change focus only if saved focus window is registered and viewable */
         wine_tsx11_lock();
Index: dlls/x11drv/window.c
===================================================================
RCS file: /var/cvs/wine/dlls/x11drv/window.c,v
retrieving revision 1.32
diff -u -r1.32 window.c
--- dlls/x11drv/window.c	7 May 2002 01:52:15 -0000	1.32
+++ dlls/x11drv/window.c	22 May 2002 04:08:05 -0000
@@ -74,8 +74,6 @@
  */
 inline static BOOL is_window_managed( WND *win )
 {
-    if (!Options.managed) return FALSE;
-
     /* tray window is always managed */
     if (win->dwExStyle & WS_EX_TRAYWINDOW) return TRUE;
     /* child windows are not managed */
Index: dlls/x11drv/x11drv_main.c
===================================================================
RCS file: /var/cvs/wine/dlls/x11drv/x11drv_main.c,v
retrieving revision 1.50
diff -u -r1.50 x11drv_main.c
--- dlls/x11drv/x11drv_main.c	17 May 2002 03:31:08 -0000	1.50
+++ dlls/x11drv/x11drv_main.c	22 May 2002 04:09:14 -0000
@@ -224,14 +224,6 @@
         putenv( strdup(buffer) );
     }
 
-    /* check --managed option in wine config file if it was not set on command line */
-
-    if (!Options.managed)
-    {
-        if (!get_config_key( hkey, appkey, "Managed", buffer, sizeof(buffer) ))
-            Options.managed = IS_OPTION_TRUE( buffer[0] );
-    }
-
     if (!get_config_key( hkey, appkey, "Desktop", buffer, sizeof(buffer) ))
     {
         /* Imperfect validation:  If Desktop=N, then we don't turn on
@@ -356,10 +348,7 @@
     screen_height = HeightOfScreen( screen );
 
     if (desktop_geometry)
-    {
-        Options.managed = FALSE;
         root_window = X11DRV_create_desktop( desktop_vi, desktop_geometry );
-    }
 
     /* initialize GDI */
     if(!X11DRV_GDI_Initialize( display ))
Index: documentation/wine.man.in
===================================================================
RCS file: /var/cvs/wine/documentation/wine.man.in,v
retrieving revision 1.39
diff -u -r1.39 wine.man.in
--- documentation/wine.man.in	9 May 2002 20:37:26 -0000	1.39
+++ documentation/wine.man.in	22 May 2002 05:05:10 -0000
@@ -161,10 +161,6 @@
 should imitate (e.g. 6.22) This option
 is only valid when used in conjunction with --winver win31.
 .TP
-.I --managed
-Create each top-level window as a properly managed X window instead of
-creating our own "sticky" window.
-.TP
 .I --winver version
 Specify which Windows version 
 .B wine 
@@ -205,7 +201,7 @@
 For example, if you want to execute 
 .B wine 
 with the options 
-.I --managed --dll riched32=n
+.I --dll riched32=n
 and if 
 .B wine 
 should run the program 
@@ -215,7 +211,7 @@
 , then you could use the following command line to invoke 
 .B wine:
 .PP
-.I wine --managed --dll riched32=n -- myapp.exe --display 3d somefile
+.I wine --dll riched32=n -- myapp.exe --display 3d somefile
 .PP 
 Note that in contrast to previous versions of 
 .B wine, 
Index: graphics/x11drv/graphics.c
===================================================================
RCS file: /var/cvs/wine/graphics/x11drv/graphics.c,v
retrieving revision 1.43
diff -u -r1.43 graphics.c
--- graphics/x11drv/graphics.c	28 Mar 2002 22:22:07 -0000	1.43
+++ graphics/x11drv/graphics.c	22 May 2002 04:11:51 -0000
@@ -1316,7 +1316,7 @@
        Window root;
        int x, y, w, h, border, depth;
 
-       /* FIXME: this is not correct for managed windows */
+       FIXME("this is not correct for managed windows");
        TSXGetGeometry( gdi_display, physDev->drawable, &root,
                        &x, &y, &w, &h, &border, &depth );
        lpp->x = x;
Index: include/options.h
===================================================================
RCS file: /var/cvs/wine/include/options.h,v
retrieving revision 1.35
diff -u -r1.35 options.h
--- include/options.h	10 Mar 2002 00:02:34 -0000	1.35
+++ include/options.h	22 May 2002 04:12:35 -0000
@@ -23,12 +23,6 @@
 
 #include "windef.h"
 
-struct options
-{
-    int    managed;	    /* Managed windows */
-};
-
-extern struct options Options;
 extern const char *argv0;
 extern const char *full_argv0;
 extern unsigned int server_startticks;
Index: misc/options.c
===================================================================
RCS file: /var/cvs/wine/misc/options.c,v
retrieving revision 1.35
diff -u -r1.35 options.c
--- misc/options.c	14 Apr 2002 19:36:02 -0000	1.35
+++ misc/options.c	22 May 2002 04:14:12 -0000
@@ -40,12 +40,6 @@
     const char *usage;
 };
 
-/* default options */
-struct options Options =
-{
-    FALSE           /* Managed windows */
-};
-
 const char *argv0;       /* the original argv[0] */
 const char *full_argv0;  /* the full path of argv[0] (if known) */
 
@@ -60,7 +54,6 @@
 
 static void do_debugmsg( const char *arg );
 static void do_help( const char *arg );
-static void do_managed( const char *arg );
 static void do_version( const char *arg );
 
 static const struct option_descr option_table[] =
@@ -74,8 +67,6 @@
       "                    Only valid with --winver win31" },
     { "help",       'h', 0, 0, do_help,
       "--help,-h        Show this help message" },
-    { "managed",      0, 0, 0, do_managed,
-      "--managed        Allow the window manager to manage created windows" },
     { "version",    'v', 0, 0, do_version,
       "--version,-v     Display the Wine version" },
     { "winver",       0, 1, 1, VERSION_ParseWinVersion,
@@ -93,11 +84,6 @@
 {
     MESSAGE( "%s\n", PACKAGE_STRING );
     ExitProcess(0);
-}
-
-static void do_managed( const char *arg )
-{
-    Options.managed = TRUE;
 }
 
 static void do_debugmsg( const char *arg )


-- 
Dimi.




More information about the wine-patches mailing list