From f57c1b77dd5b9e56e6e103d632f26c0ddea6009b Mon Sep 17 00:00:00 2001 From: Alexandre Julliard Date: Mon, 26 Jul 2010 15:36:01 +0200 Subject: [PATCH] gdi32: Get rid of the GetDCOrgEx driver entry point, GDI can implement this itself now. --- dlls/gdi32/clipping.c | 7 ++----- dlls/gdi32/dc.c | 5 ++--- dlls/gdi32/driver.c | 1 - dlls/gdi32/enhmfdrv/init.c | 1 - dlls/gdi32/gdi_private.h | 1 - dlls/gdi32/mfdrv/init.c | 1 - dlls/winex11.drv/graphics.c | 10 ---------- dlls/winex11.drv/winex11.drv.spec | 1 - dlls/winex11.drv/x11drv.h | 1 - 9 files changed, 4 insertions(+), 24 deletions(-) diff --git a/dlls/gdi32/clipping.c b/dlls/gdi32/clipping.c index 142c520a1d2..dfbc0caf996 100644 --- a/dlls/gdi32/clipping.c +++ b/dlls/gdi32/clipping.c @@ -463,11 +463,8 @@ INT WINAPI GetRandomRgn(HDC hDC, HRGN hRgn, INT iCode) /* On Windows NT/2000, the SYSRGN returned is in screen coordinates */ if (iCode == SYSRGN && !(GetVersion() & 0x80000000)) - { - POINT org; - GetDCOrgEx( hDC, &org ); - OffsetRgn( hRgn, org.x, org.y ); - } + OffsetRgn( hRgn, dc->vis_rect.left, dc->vis_rect.top ); + return (rgn != 0); } diff --git a/dlls/gdi32/dc.c b/dlls/gdi32/dc.c index 738e42efb0e..d122aae4fc0 100644 --- a/dlls/gdi32/dc.c +++ b/dlls/gdi32/dc.c @@ -1068,9 +1068,8 @@ BOOL WINAPI GetDCOrgEx( HDC hDC, LPPOINT lpp ) if (!lpp) return FALSE; if (!(dc = get_dc_ptr( hDC ))) return FALSE; - - lpp->x = lpp->y = 0; - if (dc->funcs->pGetDCOrgEx) dc->funcs->pGetDCOrgEx( dc->physDev, lpp ); + lpp->x = dc->vis_rect.left; + lpp->y = dc->vis_rect.top; release_dc_ptr( dc ); return TRUE; } diff --git a/dlls/gdi32/driver.c b/dlls/gdi32/driver.c index e6713ea2085..65eb048ab3d 100644 --- a/dlls/gdi32/driver.c +++ b/dlls/gdi32/driver.c @@ -109,7 +109,6 @@ static struct graphics_driver *create_driver( HMODULE module ) GET_FUNC(GdiComment); GET_FUNC(GetBitmapBits); GET_FUNC(GetCharWidth); - GET_FUNC(GetDCOrgEx); GET_FUNC(GetDIBColorTable); GET_FUNC(GetDIBits); GET_FUNC(GetDeviceCaps); diff --git a/dlls/gdi32/enhmfdrv/init.c b/dlls/gdi32/enhmfdrv/init.c index 115bb3935bd..7e1c9b82ec9 100644 --- a/dlls/gdi32/enhmfdrv/init.c +++ b/dlls/gdi32/enhmfdrv/init.c @@ -71,7 +71,6 @@ static const DC_FUNCTIONS EMFDRV_Funcs = EMFDRV_GdiComment, /* pGdiComment */ NULL, /* pGetBitmapBits */ NULL, /* pGetCharWidth */ - NULL, /* pGetDCOrgEx */ NULL, /* pGetDIBColorTable */ NULL, /* pGetDIBits */ EMFDRV_GetDeviceCaps, /* pGetDeviceCaps */ diff --git a/dlls/gdi32/gdi_private.h b/dlls/gdi32/gdi_private.h index 8ac78ef25d9..e09cf2b4487 100644 --- a/dlls/gdi32/gdi_private.h +++ b/dlls/gdi32/gdi_private.h @@ -113,7 +113,6 @@ typedef struct tagDC_FUNCS BOOL (CDECL *pGdiComment)(PHYSDEV,UINT,CONST BYTE*); LONG (CDECL *pGetBitmapBits)(HBITMAP,void*,LONG); BOOL (CDECL *pGetCharWidth)(PHYSDEV,UINT,UINT,LPINT); - BOOL (CDECL *pGetDCOrgEx)(PHYSDEV,LPPOINT); UINT (CDECL *pGetDIBColorTable)(PHYSDEV,UINT,UINT,RGBQUAD*); INT (CDECL *pGetDIBits)(PHYSDEV,HBITMAP,UINT,UINT,LPVOID,BITMAPINFO*,UINT); INT (CDECL *pGetDeviceCaps)(PHYSDEV,INT); diff --git a/dlls/gdi32/mfdrv/init.c b/dlls/gdi32/mfdrv/init.c index f515bcf88d7..810bd276966 100644 --- a/dlls/gdi32/mfdrv/init.c +++ b/dlls/gdi32/mfdrv/init.c @@ -69,7 +69,6 @@ static const DC_FUNCTIONS MFDRV_Funcs = NULL, /* pGdiComment */ NULL, /* pGetBitmapBits */ NULL, /* pGetCharWidth */ - NULL, /* pGetDCOrgEx */ NULL, /* pGetDIBColorTable */ NULL, /* pGetDIBits */ MFDRV_GetDeviceCaps, /* pGetDeviceCaps */ diff --git a/dlls/winex11.drv/graphics.c b/dlls/winex11.drv/graphics.c index 53cbab40f60..9cb509a9405 100644 --- a/dlls/winex11.drv/graphics.c +++ b/dlls/winex11.drv/graphics.c @@ -1466,16 +1466,6 @@ X11DRV_SetTextColor( X11DRV_PDEVICE *physDev, COLORREF color ) return color; } -/*********************************************************************** - * GetDCOrgEx (X11DRV.@) - */ -BOOL CDECL X11DRV_GetDCOrgEx( X11DRV_PDEVICE *physDev, LPPOINT lpp ) -{ - lpp->x = physDev->dc_rect.left + physDev->drawable_rect.left; - lpp->y = physDev->dc_rect.top + physDev->drawable_rect.top; - return TRUE; -} - static unsigned char *get_icm_profile( unsigned long *size ) { diff --git a/dlls/winex11.drv/winex11.drv.spec b/dlls/winex11.drv/winex11.drv.spec index ab61f548021..ffd90add7d7 100644 --- a/dlls/winex11.drv/winex11.drv.spec +++ b/dlls/winex11.drv/winex11.drv.spec @@ -17,7 +17,6 @@ @ cdecl ExtTextOut(ptr long long long ptr ptr long ptr) X11DRV_ExtTextOut @ cdecl GetBitmapBits(long ptr long) X11DRV_GetBitmapBits @ cdecl GetCharWidth(ptr long long ptr) X11DRV_GetCharWidth -@ cdecl GetDCOrgEx(ptr ptr) X11DRV_GetDCOrgEx @ cdecl GetDIBits(ptr long long long ptr ptr long) X11DRV_GetDIBits @ cdecl GetDeviceCaps(ptr long) X11DRV_GetDeviceCaps @ cdecl GetDeviceGammaRamp(ptr ptr) X11DRV_GetDeviceGammaRamp diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h index 1cd610d50a2..b8362faeb64 100644 --- a/dlls/winex11.drv/x11drv.h +++ b/dlls/winex11.drv/x11drv.h @@ -193,7 +193,6 @@ extern BOOL CDECL X11DRV_EnumDeviceFonts( X11DRV_PDEVICE *physDev, LPLOGFONTW pl extern LONG CDECL X11DRV_GetBitmapBits( HBITMAP hbitmap, void *bits, LONG count ); extern BOOL CDECL X11DRV_GetCharWidth( X11DRV_PDEVICE *physDev, UINT firstChar, UINT lastChar, LPINT buffer ); -extern BOOL CDECL X11DRV_GetDCOrgEx( X11DRV_PDEVICE *physDev, LPPOINT lpp ); extern BOOL CDECL X11DRV_GetTextExtentExPoint( X11DRV_PDEVICE *physDev, LPCWSTR str, INT count, INT maxExt, LPINT lpnFit, LPINT alpDx, LPSIZE size ); extern BOOL CDECL X11DRV_GetTextMetrics(X11DRV_PDEVICE *physDev, TEXTMETRICW *metrics); -- 2.11.4.GIT