mirror of
https://github.com/reactos/wine.git
synced 2024-11-29 22:50:43 +00:00
f0cbfa0c5c
Sat Feb 15 11:59:17 1997 Alexandre Julliard <julliard@lrc.epfl.ch> * [*/*] Converted a lot of functions to Win32 types. Removed HWND type. Fri Feb 14 15:09:19 1997 Onno Hovers <onno@stack.nl> * [memory/global.c] Implemented GMEM_MOVEABLE blocks for Win32. Fri Feb 14 00:24:39 1997 Alex Korobka <alex@trantor.pharm.sunysb.edu> * [loader/task.c] [windows/queue.c] Do not read X events while in the intertask SendMessage(). * [misc/lstr.c] Fixed CharPrev32A(). * [windows/hook.c] [include/hook.h] Restored broken WH_CALLWNDPROC functionality for dialogs, etc... * [windows/win.c] [windows/defwnd.c] [windows/mdi.c] [windows/event.c] [controls/edit.c] Added WIN_ISWIN32 flag to windows created by Win32 calls. Several new Win32 messages are sent when this flag is on. * [msdos/dosmem.c] [memory/global.c] Some changes in DOS memory allocation. Fri Feb 7 21:46:03 1997 Andrew Taylor <andrew@riscan.com> * [win32/security.c] Added SID manipulation functions. * [include/debug.h] Added debugging class "security". Fri Feb 7 20:46:33 1997 Robert Pouliot <krynos@clic.net> * [debugger/msc.c] [debugger/source.c] [documentation/wine_os2.txt] [loader/signal.c] Some more changes for OS/2. Doesn't work yet. Fri Feb 7 09:31:17 1997 Marcus Meissner <msmeissn@cip.informatik.uni-erlangen.de> * [scheduler/process.c] Added ExpandEnvironmentStrings*. * [misc/ntdll.c] [include/ntdll.h] Added some new functions. * [objects/cursoricon.c] CURSORICON_LoadHandler: check against some bizarre out of memory conditions. * [windows/mdi.c] Fixed DefFrameProc32*, added TranslateMDISysAccel32. Wed Feb 5 01:31:05 1997 John Zero <john@globe.graphisoft.hu> * [resources/sysres_Hu.rc] [misc/ole2nls.c] [misc/main.c] [programs/progman/Hu.rc] [programs/winhelp/Hu.rc] Added Hungarian language support.
87 lines
3.2 KiB
C
87 lines
3.2 KiB
C
/*
|
|
* System metrics functions
|
|
*
|
|
* Copyright 1994 Alexandre Julliard
|
|
*
|
|
static char Copyright[] = "Copyright Alexandre Julliard, 1994";
|
|
*/
|
|
|
|
#include <X11/Xlib.h>
|
|
#include "gdi.h"
|
|
#include "sysmetrics.h"
|
|
|
|
short sysMetrics[SM_CMETRICS+1];
|
|
|
|
/***********************************************************************
|
|
* SYSMETRICS_Init
|
|
*
|
|
* Initialisation of the system metrics array.
|
|
*/
|
|
void SYSMETRICS_Init(void)
|
|
{
|
|
sysMetrics[SM_CXSCREEN] = screenWidth;
|
|
sysMetrics[SM_CYSCREEN] = screenHeight;
|
|
sysMetrics[SM_CXVSCROLL] = SYSMETRICS_CXVSCROLL;
|
|
sysMetrics[SM_CYHSCROLL] = SYSMETRICS_CYHSCROLL;
|
|
sysMetrics[SM_CYCAPTION] = SYSMETRICS_CYCAPTION;
|
|
sysMetrics[SM_CXBORDER] = SYSMETRICS_CXBORDER;
|
|
sysMetrics[SM_CYBORDER] = SYSMETRICS_CYBORDER;
|
|
sysMetrics[SM_CXDLGFRAME] = SYSMETRICS_CXDLGFRAME;
|
|
sysMetrics[SM_CYDLGFRAME] = SYSMETRICS_CYDLGFRAME;
|
|
sysMetrics[SM_CYVTHUMB] = SYSMETRICS_CYVTHUMB;
|
|
sysMetrics[SM_CXHTHUMB] = SYSMETRICS_CXHTHUMB;
|
|
sysMetrics[SM_CXICON] = SYSMETRICS_CXICON;
|
|
sysMetrics[SM_CYICON] = SYSMETRICS_CYICON;
|
|
sysMetrics[SM_CXCURSOR] = SYSMETRICS_CXCURSOR;
|
|
sysMetrics[SM_CYCURSOR] = SYSMETRICS_CYCURSOR;
|
|
sysMetrics[SM_CYMENU] = SYSMETRICS_CYMENU;
|
|
sysMetrics[SM_CXFULLSCREEN] = sysMetrics[SM_CXSCREEN];
|
|
sysMetrics[SM_CYFULLSCREEN] = sysMetrics[SM_CYSCREEN] - sysMetrics[SM_CYCAPTION];
|
|
sysMetrics[SM_CYKANJIWINDOW] = 0;
|
|
sysMetrics[SM_MOUSEPRESENT] = 1;
|
|
sysMetrics[SM_CYVSCROLL] = SYSMETRICS_CYVSCROLL;
|
|
sysMetrics[SM_CXHSCROLL] = SYSMETRICS_CXHSCROLL;
|
|
sysMetrics[SM_DEBUG] = 0;
|
|
sysMetrics[SM_SWAPBUTTON] = 0;
|
|
sysMetrics[SM_RESERVED1] = 0;
|
|
sysMetrics[SM_RESERVED2] = 0;
|
|
sysMetrics[SM_RESERVED3] = 0;
|
|
sysMetrics[SM_RESERVED4] = 0;
|
|
sysMetrics[SM_CXMIN] = SYSMETRICS_CXMIN;
|
|
sysMetrics[SM_CYMIN] = SYSMETRICS_CYMIN;
|
|
sysMetrics[SM_CXSIZE] = SYSMETRICS_CXSIZE;
|
|
sysMetrics[SM_CYSIZE] = SYSMETRICS_CYSIZE;
|
|
sysMetrics[SM_CXFRAME] = GetProfileInt32A( "windows", "BorderWidth", 4 );
|
|
sysMetrics[SM_CYFRAME] = sysMetrics[SM_CXFRAME];
|
|
sysMetrics[SM_CXMINTRACK] = SYSMETRICS_CXMINTRACK;
|
|
sysMetrics[SM_CYMINTRACK] = SYSMETRICS_CYMINTRACK;
|
|
sysMetrics[SM_CXDOUBLECLK] = (GetProfileInt32A( "windows","DoubleClickWidth", 4) + 1) & ~1;
|
|
sysMetrics[SM_CYDOUBLECLK] = (GetProfileInt32A( "windows","DoubleClickHeight", 4) + 1) & ~1;
|
|
sysMetrics[SM_CXICONSPACING] = GetProfileInt32A( "desktop","IconSpacing", 75);
|
|
sysMetrics[SM_CYICONSPACING] = GetProfileInt32A( "desktop","IconVerticalSpacing", 72);
|
|
sysMetrics[SM_MENUDROPALIGNMENT] = GetProfileInt32A( "windows","MenuDropAlignment", 0 );
|
|
sysMetrics[SM_PENWINDOWS] = 0;
|
|
sysMetrics[SM_DBCSENABLED] = 0;
|
|
sysMetrics[SM_CMETRICS] = SM_CMETRICS;
|
|
}
|
|
|
|
|
|
/***********************************************************************
|
|
* GetSystemMetrics16 (USER.179)
|
|
*/
|
|
INT16 GetSystemMetrics16( INT16 index )
|
|
{
|
|
if ((index < 0) || (index > SM_CMETRICS)) return 0;
|
|
else return sysMetrics[index];
|
|
}
|
|
|
|
|
|
/***********************************************************************
|
|
* GetSystemMetrics32 (USER32.291)
|
|
*/
|
|
INT32 GetSystemMetrics32( INT32 index )
|
|
{
|
|
if ((index < 0) || (index > SM_CMETRICS)) return 0;
|
|
else return sysMetrics[index];
|
|
}
|