Implemented the Desktop=XXXxYYY setting in the [x11drv] section of the

config file.
oldstable
Andreas Mohr 2000-11-12 03:41:47 +00:00 committed by Alexandre Julliard
parent 5394ab83c4
commit efc17535ac
2 changed files with 17 additions and 4 deletions

View File

@ -10,6 +10,7 @@
#include <fcntl.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/time.h>
#include <unistd.h>
#include <X11/cursorfont.h>
@ -113,16 +114,26 @@ static void setup_options(void)
RegSetValueExA( hkey, "display", 0, REG_SZ, Options.display, strlen(Options.display)+1 );
}
/* --managed option */
/* check and set --managed and --desktop options in wine config file
* if it was not set on command line */
if (!Options.managed)
if ((!Options.managed) && (Options.desktopGeometry == NULL))
{
count = sizeof(buffer);
if (!RegQueryValueExA( hkey, "managed", 0, &type, buffer, &count ))
Options.managed = IS_OPTION_TRUE( buffer[0] );
}
else RegSetValueExA( hkey, "managed", 0, REG_SZ, "y", 2 );
count = sizeof(buffer);
if (!RegQueryValueExA( hkey, "Desktop", 0, &type, buffer, &count ))
Options.desktopGeometry = strdup(buffer);
}
if (Options.managed)
RegSetValueExA( hkey, "managed", 0, REG_SZ, "y", 2 );
if (Options.desktopGeometry)
RegSetValueExA( hkey, "desktop", 0, REG_SZ, Options.desktopGeometry, strlen(Options.desktopGeometry)+1 );
RegCloseKey( hkey );
}

View File

@ -106,6 +106,8 @@ PerfectGraphics = N
;;Display = :0.0
; Allow the window manager to manage created windows
Managed = N
; Use a desktop window of 640x480 for Wine
;Desktop = 640x480
; Use XFree86 DGA extension if present
UseDGA = Y
; Use XShm extension if present