Fix Bug#: 4324: MAPPING_FixIsotropic behaves wrong with negativ viewport/window extension

Tobias Loew tobi at die-loews.de
Sat Jan 28 05:21:21 CST 2006


Changelog:
    dlls/gdi/mapping.c

    Tobias Loew <tobi at die-loews.de>
    Fix Bug#: 4324: MAPPING_FixIsotropic behaves wrong with negativ viewport/window 
extension

Tobias Loew


Index: dlls/gdi/mapping.c
===================================================================
RCS file: /home/wine/wine/dlls/gdi/mapping.c,v
retrieving revision 1.1
diff -u -p -r1.1 mapping.c
--- dlls/gdi/mapping.c	12 Feb 2004 23:11:30 -0000	1.1
+++ dlls/gdi/mapping.c	28 Jan 2006 10:25:43 -0000
@@ -37,7 +37,7 @@ void MAPPING_FixIsotropic( DC * dc )
                   (GetDeviceCaps( dc->hSelf, HORZRES ) * dc->wndExtX);
     double ydim = (double)dc->vportExtY * GetDeviceCaps( dc->hSelf, VERTSIZE ) /
                   (GetDeviceCaps( dc->hSelf, VERTRES ) * dc->wndExtY);
-    if (xdim > ydim)
+    if (fabs(xdim) > fabs(ydim))
     {
 	dc->vportExtX = floor(dc->vportExtX * fabs( ydim / xdim ) + 0.5);
 	if (!dc->vportExtX) dc->vportExtX = 1;




More information about the wine-patches mailing list