Author: tkreuzer
Date: Fri Mar 20 17:16:01 2009
New Revision: 40135
URL:
http://svn.reactos.org/svn/reactos?rev=40135&view=rev
Log:
rename DC.Dc_attr to dcattr, DC.DcLevel to dclevel, just like in gdikdx. Some naming
improvement, remove an excessive variable.
Modified:
trunk/reactos/subsystems/win32/win32k/include/coord.h
trunk/reactos/subsystems/win32/win32k/include/dc.h
trunk/reactos/subsystems/win32/win32k/include/gdifloat.h
trunk/reactos/subsystems/win32/win32k/include/path.h
trunk/reactos/subsystems/win32/win32k/ntuser/windc.c
trunk/reactos/subsystems/win32/win32k/objects/arc.c
trunk/reactos/subsystems/win32/win32k/objects/bitmaps.c
trunk/reactos/subsystems/win32/win32k/objects/cliprgn.c
trunk/reactos/subsystems/win32/win32k/objects/color.c
trunk/reactos/subsystems/win32/win32k/objects/coord.c
trunk/reactos/subsystems/win32/win32k/objects/dc.c
trunk/reactos/subsystems/win32/win32k/objects/dcutil.c
trunk/reactos/subsystems/win32/win32k/objects/dibobj.c
trunk/reactos/subsystems/win32/win32k/objects/drawing.c
trunk/reactos/subsystems/win32/win32k/objects/fillshap.c
trunk/reactos/subsystems/win32/win32k/objects/freetype.c
trunk/reactos/subsystems/win32/win32k/objects/gdiobj.c
trunk/reactos/subsystems/win32/win32k/objects/icm.c
trunk/reactos/subsystems/win32/win32k/objects/line.c
trunk/reactos/subsystems/win32/win32k/objects/path.c
trunk/reactos/subsystems/win32/win32k/objects/region.c
Modified: trunk/reactos/subsystems/win32/win32k/include/coord.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/include/coord.h [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/include/coord.h [iso-8859-1] Fri Mar 20 17:16:01
2009
@@ -3,10 +3,10 @@
#include <include/dc.h>
-#define IntDPtoLP(dc, pp, c)
XFORMOBJ_bApplyXform((XFORMOBJ*)&(dc)->DcLevel.mxDeviceToWorld, XF_LTOL, c, pp,
pp);
-#define IntLPtoDP(dc, pp, c)
XFORMOBJ_bApplyXform((XFORMOBJ*)&(dc)->DcLevel.mxWorldToDevice, XF_LTOL, c, pp,
pp);
-#define CoordDPtoLP(dc, pp)
XFORMOBJ_bApplyXform((XFORMOBJ*)&(dc)->DcLevel.mxDeviceToWorld, XF_LTOL, 1, pp,
pp);
-#define CoordLPtoDP(dc, pp)
XFORMOBJ_bApplyXform((XFORMOBJ*)&(dc)->DcLevel.mxWorldToDevice, XF_LTOL, 1, pp,
pp);
+#define IntDPtoLP(dc, pp, c)
XFORMOBJ_bApplyXform((XFORMOBJ*)&(dc)->dclevel.mxDeviceToWorld, XF_LTOL, c, pp,
pp);
+#define IntLPtoDP(dc, pp, c)
XFORMOBJ_bApplyXform((XFORMOBJ*)&(dc)->dclevel.mxWorldToDevice, XF_LTOL, c, pp,
pp);
+#define CoordDPtoLP(dc, pp)
XFORMOBJ_bApplyXform((XFORMOBJ*)&(dc)->dclevel.mxDeviceToWorld, XF_LTOL, 1, pp,
pp);
+#define CoordLPtoDP(dc, pp)
XFORMOBJ_bApplyXform((XFORMOBJ*)&(dc)->dclevel.mxWorldToDevice, XF_LTOL, 1, pp,
pp);
#define XForm2MatrixS(m, x) XFORMOBJ_iSetXform((XFORMOBJ*)m, (XFORML*)x)
#define MatrixS2XForm(x, m) XFORMOBJ_iGetXform((XFORMOBJ*)m, (XFORML*)x)
Modified: trunk/reactos/subsystems/win32/win32k/include/dc.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/include/dc.h [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/include/dc.h [iso-8859-1] Fri Mar 20 17:16:01
2009
@@ -114,8 +114,8 @@
FLONG flGraphicsCaps;
FLONG flGraphicsCaps2;
PDC_ATTR pdcattr;
- DCLEVEL DcLevel;
- DC_ATTR Dc_Attr;
+ DCLEVEL dclevel;
+ DC_ATTR dcattr;
HDC hdcNext;
HDC hdcPrev;
RECTL erclClip;
Modified: trunk/reactos/subsystems/win32/win32k/include/gdifloat.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/include/gdifloat.h [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/include/gdifloat.h [iso-8859-1] Fri Mar 20
17:16:01 2009
@@ -33,7 +33,7 @@
FLOAT x, y;
XFORM xformWorld2Vport;
- MatrixS2XForm(&xformWorld2Vport, &dc->DcLevel.mxWorldToDevice);
+ MatrixS2XForm(&xformWorld2Vport, &dc->dclevel.mxWorldToDevice);
/* Perform the transformation */
x = point->x;
@@ -89,25 +89,25 @@
#define MulDiv( x, y, z ) EngMulDiv( x, y, z )
-#define XDPTOLP(Dc_Attr,tx) \
- (MulDiv(((tx)-(Dc_Attr)->ptlViewportOrg.x), (Dc_Attr)->szlWindowExt.cx,
(Dc_Attr)->szlViewportExt.cx) + (Dc_Attr)->ptlWindowOrg.x)
-#define YDPTOLP(Dc_Attr,ty) \
- (MulDiv(((ty)-(Dc_Attr)->ptlViewportOrg.y), (Dc_Attr)->szlWindowExt.cy,
(Dc_Attr)->szlViewportExt.cy) + (Dc_Attr)->ptlWindowOrg.y)
-#define XLPTODP(Dc_Attr,tx) \
- (MulDiv(((tx)-(Dc_Attr)->ptlWindowOrg.x), (Dc_Attr)->szlViewportExt.cx,
(Dc_Attr)->szlWindowExt.cx) + (Dc_Attr)->ptlViewportOrg.x)
-#define YLPTODP(Dc_Attr,ty) \
- (MulDiv(((ty)-(Dc_Attr)->ptlWindowOrg.y), (Dc_Attr)->szlViewportExt.cy,
(Dc_Attr)->szlWindowExt.cy) + (Dc_Attr)->ptlViewportOrg.y)
+#define XDPTOLP(pdcattr,tx) \
+ (MulDiv(((tx)-(pdcattr)->ptlViewportOrg.x), (pdcattr)->szlWindowExt.cx,
(pdcattr)->szlViewportExt.cx) + (pdcattr)->ptlWindowOrg.x)
+#define YDPTOLP(pdcattr,ty) \
+ (MulDiv(((ty)-(pdcattr)->ptlViewportOrg.y), (pdcattr)->szlWindowExt.cy,
(pdcattr)->szlViewportExt.cy) + (pdcattr)->ptlWindowOrg.y)
+#define XLPTODP(pdcattr,tx) \
+ (MulDiv(((tx)-(pdcattr)->ptlWindowOrg.x), (pdcattr)->szlViewportExt.cx,
(pdcattr)->szlWindowExt.cx) + (pdcattr)->ptlViewportOrg.x)
+#define YLPTODP(pdcattr,ty) \
+ (MulDiv(((ty)-(pdcattr)->ptlWindowOrg.y), (pdcattr)->szlViewportExt.cy,
(pdcattr)->szlWindowExt.cy) + (pdcattr)->ptlViewportOrg.y)
/* Device <-> logical size conversion */
-#define XDSTOLS(Dc_Attr,tx) \
- MulDiv((tx), (Dc_Attr)->szlWindowExt.cx, (Dc_Attr)->szlViewportExt.cx)
+#define XDSTOLS(pdcattr,tx) \
+ MulDiv((tx), (pdcattr)->szlWindowExt.cx, (pdcattr)->szlViewportExt.cx)
#define YDSTOLS(DC_Attr,ty) \
- MulDiv((ty), (Dc_Attr)->szlWindowExt.cy, (Dc_Attr)->szlViewportExt.cy)
-#define XLSTODS(Dc_Attr,tx) \
- MulDiv((tx), (Dc_Attr)->szlViewportExt.cx, (Dc_Attr)->szlWindowExt.cx)
-#define YLSTODS(Dc_Attr,ty) \
- MulDiv((ty), (Dc_Attr)->szlViewportExt.cy, (Dc_Attr)->szlWindowExt.cy)
+ MulDiv((ty), (pdcattr)->szlWindowExt.cy, (pdcattr)->szlViewportExt.cy)
+#define XLSTODS(pdcattr,tx) \
+ MulDiv((tx), (pdcattr)->szlViewportExt.cx, (pdcattr)->szlWindowExt.cx)
+#define YLSTODS(pdcattr,ty) \
+ MulDiv((ty), (pdcattr)->szlViewportExt.cy, (pdcattr)->szlWindowExt.cy)
#endif
Modified: trunk/reactos/subsystems/win32/win32k/include/path.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/include/path.h [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/include/path.h [iso-8859-1] Fri Mar 20 17:16:01
2009
@@ -47,7 +47,7 @@
#define PATH_UnlockPath(pPath) GDIOBJ_ShareUnlockObjByPtr((POBJ)pPath)
-#define PATH_IsPathOpen(DcLevel) ( ((DcLevel).hPath) && ((DcLevel).flPath &
DCPATH_ACTIVE) )
+#define PATH_IsPathOpen(dclevel) ( ((dclevel).hPath) && ((dclevel).flPath &
DCPATH_ACTIVE) )
BOOL FASTCALL PATH_Arc (PDC dc, INT x1, INT y1, INT x2, INT y2, INT xStart, INT yStart,
INT xEnd, INT yEnd, INT lines);
BOOL FASTCALL PATH_AssignGdiPath (PPATH pPathDest, const PPATH pPathSrc);
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/windc.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/ntuser/windc.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/ntuser/windc.c [iso-8859-1] Fri Mar 20 17:16:01
2009
@@ -44,7 +44,7 @@
PDC dc = DC_LockDc ( hDC );
defaultDCstate = ExAllocatePoolWithTag(PagedPool, sizeof(DC), TAG_DC);
RtlZeroMemory(defaultDCstate, sizeof(DC));
- defaultDCstate->pdcattr = &defaultDCstate->Dc_Attr;
+ defaultDCstate->pdcattr = &defaultDCstate->dcattr;
IntGdiCopyToSaveState(dc, defaultDCstate);
DC_UnlockDc( dc );
}
Modified: trunk/reactos/subsystems/win32/win32k/objects/arc.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/arc.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/arc.c [iso-8859-1] Fri Mar 20 17:16:01
2009
@@ -207,7 +207,7 @@
if ((LeftRect == RightRect) || (TopRect == BottomRect)) return TRUE;
- if (PATH_IsPathOpen(dc->DcLevel))
+ if (PATH_IsPathOpen(dc->dclevel))
{
return PATH_Arc( dc,
LeftRect,
@@ -231,7 +231,7 @@
if (arctype == GdiTypeArcTo)
{
- if (dc->DcLevel.flPath & DCPATH_CLOCKWISE)
+ if (dc->dclevel.flPath & DCPATH_CLOCKWISE)
IntGdiLineTo(dc, XEndArc, YEndArc);
else
IntGdiLineTo(dc, XStartArc, YStartArc);
@@ -250,7 +250,7 @@
if (arctype == GdiTypeArcTo)
{
- if (dc->DcLevel.flPath & DCPATH_CLOCKWISE)
+ if (dc->dclevel.flPath & DCPATH_CLOCKWISE)
IntGdiMoveToEx(dc, XStartArc, YStartArc, NULL);
else
IntGdiMoveToEx(dc, XEndArc, YEndArc, NULL);
@@ -277,11 +277,11 @@
x1 = x + (INT)(cos((eStartAngle/360)*(M_PI*2)) * dwRadius);
y1 = y - (INT)(sin((eStartAngle/360)*(M_PI*2)) * dwRadius);
- arcdir = pDC->DcLevel.flPath & DCPATH_CLOCKWISE;
+ arcdir = pDC->dclevel.flPath & DCPATH_CLOCKWISE;
if (eSweepAngle >= 0)
- pDC->DcLevel.flPath &= ~DCPATH_CLOCKWISE;
+ pDC->dclevel.flPath &= ~DCPATH_CLOCKWISE;
else
- pDC->DcLevel.flPath |= DCPATH_CLOCKWISE;
+ pDC->dclevel.flPath |= DCPATH_CLOCKWISE;
result = IntGdiArcInternal( GdiTypeArcTo,
pDC,
@@ -294,7 +294,7 @@
x2,
y2 );
- pDC->DcLevel.flPath |= (arcdir & DCPATH_CLOCKWISE);
+ pDC->dclevel.flPath |= (arcdir & DCPATH_CLOCKWISE);
if (result)
{
Modified: trunk/reactos/subsystems/win32/win32k/objects/bitmaps.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/bitmaps.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/bitmaps.c [iso-8859-1] Fri Mar 20
17:16:01 2009
@@ -940,7 +940,7 @@
pDC->rosdc.hBitmap = hBmp;
// If Info DC this is zero and pSurface is moved to DC->pSurfInfo.
- pDC->DcLevel.pSurface = psurfBmp;
+ pDC->dclevel.pSurface = psurfBmp;
psurfBmp->hDC = hDC;
// if we're working with a DIB, get the palette
Modified: trunk/reactos/subsystems/win32/win32k/objects/cliprgn.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/cliprgn.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/cliprgn.c [iso-8859-1] Fri Mar 20
17:16:01 2009
@@ -429,30 +429,30 @@
INT Ret = ERROR;
PROSRGNDATA TempRgn;
- if ( pDC->DcLevel.prgnMeta )
- {
- if ( pDC->DcLevel.prgnClip )
+ if ( pDC->dclevel.prgnMeta )
+ {
+ if ( pDC->dclevel.prgnClip )
{
TempRgn = IntGdiCreateRectRgn(0,0,0,0);
if (TempRgn)
{
Ret = IntGdiCombineRgn( TempRgn,
- pDC->DcLevel.prgnMeta,
- pDC->DcLevel.prgnClip,
+ pDC->dclevel.prgnMeta,
+ pDC->dclevel.prgnClip,
RGN_AND);
if ( Ret )
{
- GDIOBJ_ShareUnlockObjByPtr(pDC->DcLevel.prgnMeta);
- if (!((PROSRGNDATA)pDC->DcLevel.prgnMeta)->BaseObject.ulShareCount)
- REGION_Delete(pDC->DcLevel.prgnMeta);
-
- pDC->DcLevel.prgnMeta = TempRgn;
-
- GDIOBJ_ShareUnlockObjByPtr(pDC->DcLevel.prgnClip);
- if (!((PROSRGNDATA)pDC->DcLevel.prgnClip)->BaseObject.ulShareCount)
- REGION_Delete(pDC->DcLevel.prgnClip);
-
- pDC->DcLevel.prgnClip = NULL;
+ GDIOBJ_ShareUnlockObjByPtr(pDC->dclevel.prgnMeta);
+ if (!((PROSRGNDATA)pDC->dclevel.prgnMeta)->BaseObject.ulShareCount)
+ REGION_Delete(pDC->dclevel.prgnMeta);
+
+ pDC->dclevel.prgnMeta = TempRgn;
+
+ GDIOBJ_ShareUnlockObjByPtr(pDC->dclevel.prgnClip);
+ if (!((PROSRGNDATA)pDC->dclevel.prgnClip)->BaseObject.ulShareCount)
+ REGION_Delete(pDC->dclevel.prgnClip);
+
+ pDC->dclevel.prgnClip = NULL;
IntGdiReleaseRaoRgn(pDC);
}
@@ -461,15 +461,15 @@
}
}
else
- Ret = REGION_Complexity(pDC->DcLevel.prgnMeta);
+ Ret = REGION_Complexity(pDC->dclevel.prgnMeta);
}
else
{
- if ( pDC->DcLevel.prgnClip )
+ if ( pDC->dclevel.prgnClip )
{
- Ret = REGION_Complexity(pDC->DcLevel.prgnClip);
- pDC->DcLevel.prgnMeta = pDC->DcLevel.prgnClip;
- pDC->DcLevel.prgnClip = NULL;
+ Ret = REGION_Complexity(pDC->dclevel.prgnClip);
+ pDC->dclevel.prgnMeta = pDC->dclevel.prgnClip;
+ pDC->dclevel.prgnClip = NULL;
}
else
Ret = SIMPLEREGION;
@@ -513,23 +513,23 @@
pDC->prgnRao = IntGdiCreateRectRgn(0,0,0,0);
}
- if (pDC->DcLevel.prgnMeta && pDC->DcLevel.prgnClip)
+ if (pDC->dclevel.prgnMeta && pDC->dclevel.prgnClip)
{
IntGdiCombineRgn( pDC->prgnAPI,
- pDC->DcLevel.prgnClip,
- pDC->DcLevel.prgnMeta,
+ pDC->dclevel.prgnClip,
+ pDC->dclevel.prgnMeta,
RGN_AND);
}
else
{
- if (pDC->DcLevel.prgnClip)
+ if (pDC->dclevel.prgnClip)
IntGdiCombineRgn( pDC->prgnAPI,
- pDC->DcLevel.prgnClip,
+ pDC->dclevel.prgnClip,
NULL,
RGN_COPY);
- else if (pDC->DcLevel.prgnMeta)
+ else if (pDC->dclevel.prgnMeta)
IntGdiCombineRgn( pDC->prgnAPI,
- pDC->DcLevel.prgnMeta,
+ pDC->dclevel.prgnMeta,
NULL,
RGN_COPY);
}
Modified: trunk/reactos/subsystems/win32/win32k/objects/color.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/color.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/color.c [iso-8859-1] Fri Mar 20 17:16:01
2009
@@ -122,7 +122,7 @@
dc = DC_LockDc(hDC);
if (NULL != dc)
{
- if (dc->DcLevel.hpal == hPal)
+ if (dc->dclevel.hpal == hPal)
{
DC_UnlockDc(dc);
IntGdiRealizePalette(hDC);
@@ -301,7 +301,7 @@
dc = DC_LockDc(hDC);
if (NULL != dc)
{
- HPALETTE hpal = dc->DcLevel.hpal;
+ HPALETTE hpal = dc->dclevel.hpal;
palGDI = (PPALGDI) PALETTE_LockPalette(hpal);
if (!palGDI)
{
@@ -431,7 +431,7 @@
return 0;
}
- palGDI = PALETTE_LockPalette(dc->DcLevel.hpal);
+ palGDI = PALETTE_LockPalette(dc->dclevel.hpal);
if (palGDI != NULL)
{
if (pe != NULL)
@@ -499,7 +499,7 @@
if (!dc) return 0;
systemPalette = NtGdiGetStockObject(DEFAULT_PALETTE);
- palGDI = PALETTE_LockPalette(dc->DcLevel.hpal);
+ palGDI = PALETTE_LockPalette(dc->dclevel.hpal);
if (palGDI == NULL)
{
@@ -543,7 +543,7 @@
{
EngDeleteXlate(palGDI->logicalToSystem);
}
- palGDI->logicalToSystem = IntEngCreateXlate(sysMode, palMode, systemPalette,
dc->DcLevel.hpal);
+ palGDI->logicalToSystem = IntEngCreateXlate(sysMode, palMode, systemPalette,
dc->dclevel.hpal);
}
DC_UnlockDc(dc);
Modified: trunk/reactos/subsystems/win32/win32k/objects/coord.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/coord.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/coord.c [iso-8859-1] Fri Mar 20 17:16:01
2009
@@ -144,23 +144,23 @@
xformWorld2Wnd.eM22 = 1.0f;
xformWorld2Wnd.eDx = 0.0f;
xformWorld2Wnd.eDy = 0.0f;
- XForm2MatrixS(&pDc->DcLevel.mxWorldToPage, &xformWorld2Wnd);
+ XForm2MatrixS(&pDc->dclevel.mxWorldToPage, &xformWorld2Wnd);
break;
case MWT_LEFTMULTIPLY:
- MatrixS2XForm(&xformWorld2Wnd, &pDc->DcLevel.mxWorldToPage);
+ MatrixS2XForm(&xformWorld2Wnd, &pDc->dclevel.mxWorldToPage);
IntGdiCombineTransform(&xformWorld2Wnd, lpXForm, &xformWorld2Wnd);
- XForm2MatrixS(&pDc->DcLevel.mxWorldToPage, &xformWorld2Wnd);
+ XForm2MatrixS(&pDc->dclevel.mxWorldToPage, &xformWorld2Wnd);
break;
case MWT_RIGHTMULTIPLY:
- MatrixS2XForm(&xformWorld2Wnd, &pDc->DcLevel.mxWorldToPage);
+ MatrixS2XForm(&xformWorld2Wnd, &pDc->dclevel.mxWorldToPage);
IntGdiCombineTransform(&xformWorld2Wnd, &xformWorld2Wnd, lpXForm);
- XForm2MatrixS(&pDc->DcLevel.mxWorldToPage, &xformWorld2Wnd);
+ XForm2MatrixS(&pDc->dclevel.mxWorldToPage, &xformWorld2Wnd);
break;
case MWT_MAX+1: // Must be MWT_SET????
- XForm2MatrixS(&pDc->DcLevel.mxWorldToPage, lpXForm); // Do it like
Wine.
+ XForm2MatrixS(&pDc->dclevel.mxWorldToPage, lpXForm); // Do it like
Wine.
break;
default:
@@ -198,7 +198,7 @@
switch (iXform)
{
case GdiWorldSpaceToPageSpace:
- MatrixS2XForm(XForm, &dc->DcLevel.mxWorldToPage);
+ MatrixS2XForm(XForm, &dc->dclevel.mxWorldToPage);
break;
default:
break;
@@ -897,10 +897,10 @@
if (!(pdcattr->flTextAlign & TA_CENTER)) pdcattr->flTextAlign |= TA_RIGHT;
- if (dc->DcLevel.flPath & DCPATH_CLOCKWISE)
- dc->DcLevel.flPath &= ~DCPATH_CLOCKWISE;
+ if (dc->dclevel.flPath & DCPATH_CLOCKWISE)
+ dc->dclevel.flPath &= ~DCPATH_CLOCKWISE;
else
- dc->DcLevel.flPath |= DCPATH_CLOCKWISE;
+ dc->dclevel.flPath |= DCPATH_CLOCKWISE;
pdcattr->flXform |= (PAGE_EXTENTS_CHANGED |
INVALIDATE_ATTRIBUTES |
Modified: trunk/reactos/subsystems/win32/win32k/objects/dc.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/dc.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/dc.c [iso-8859-1] Fri Mar 20 17:16:01
2009
@@ -59,7 +59,7 @@
NtGdiCreateCompatibleDC(HDC hDC)
{
PDC NewDC, OrigDC;
- PDC_ATTR nDc_Attr, oDc_Attr;
+ PDC_ATTR pdcattrNew, pdcattrOld;
HDC hNewDC, DisplayDC = NULL;
HRGN hVisRgn;
UNICODE_STRING DriverName;
@@ -108,36 +108,36 @@
return NULL;
}
- oDc_Attr = OrigDC->pdcattr;
- nDc_Attr = NewDC->pdcattr;
+ pdcattrOld = OrigDC->pdcattr;
+ pdcattrNew = NewDC->pdcattr;
/* Copy information from original DC to new DC */
- NewDC->DcLevel.hdcSave = hNewDC;
+ NewDC->dclevel.hdcSave = hNewDC;
NewDC->dhpdev = OrigDC->dhpdev;
NewDC->rosdc.bitsPerPixel = OrigDC->rosdc.bitsPerPixel;
/* DriverName is copied in the AllocDC routine */
- nDc_Attr->ptlWindowOrg = oDc_Attr->ptlWindowOrg;
- nDc_Attr->szlWindowExt = oDc_Attr->szlWindowExt;
- nDc_Attr->ptlViewportOrg = oDc_Attr->ptlViewportOrg;
- nDc_Attr->szlViewportExt = oDc_Attr->szlViewportExt;
+ pdcattrNew->ptlWindowOrg = pdcattrOld->ptlWindowOrg;
+ pdcattrNew->szlWindowExt = pdcattrOld->szlWindowExt;
+ pdcattrNew->ptlViewportOrg = pdcattrOld->ptlViewportOrg;
+ pdcattrNew->szlViewportExt = pdcattrOld->szlViewportExt;
NewDC->dctype = DC_TYPE_MEMORY; // Always!
NewDC->rosdc.hBitmap = NtGdiGetStockObject(DEFAULT_BITMAP);
NewDC->ppdev = OrigDC->ppdev;
- NewDC->DcLevel.hpal = OrigDC->DcLevel.hpal;
-
- nDc_Attr->lTextAlign = oDc_Attr->lTextAlign;
- nDc_Attr->lBkMode = oDc_Attr->lBkMode;
- nDc_Attr->jBkMode = oDc_Attr->jBkMode;
- nDc_Attr->jROP2 = oDc_Attr->jROP2;
- nDc_Attr->dwLayout = oDc_Attr->dwLayout;
- if (oDc_Attr->dwLayout & LAYOUT_ORIENTATIONMASK) Layout =
oDc_Attr->dwLayout;
- NewDC->DcLevel.flPath = OrigDC->DcLevel.flPath;
- nDc_Attr->ulDirty_ = oDc_Attr->ulDirty_;
- nDc_Attr->iCS_CP = oDc_Attr->iCS_CP;
+ NewDC->dclevel.hpal = OrigDC->dclevel.hpal;
+
+ pdcattrNew->lTextAlign = pdcattrOld->lTextAlign;
+ pdcattrNew->lBkMode = pdcattrOld->lBkMode;
+ pdcattrNew->jBkMode = pdcattrOld->jBkMode;
+ pdcattrNew->jROP2 = pdcattrOld->jROP2;
+ pdcattrNew->dwLayout = pdcattrOld->dwLayout;
+ if (pdcattrOld->dwLayout & LAYOUT_ORIENTATIONMASK) Layout =
pdcattrOld->dwLayout;
+ NewDC->dclevel.flPath = OrigDC->dclevel.flPath;
+ pdcattrNew->ulDirty_ = pdcattrOld->ulDirty_;
+ pdcattrNew->iCS_CP = pdcattrOld->iCS_CP;
NewDC->erclWindow = (RECTL){0,0,1,1};
@@ -738,10 +738,9 @@
CONST PDEVMODEW InitData,
BOOL CreateAsIC)
{
- HDC hNewDC;
- PDC NewDC;
- PDC_ATTR nDc_Attr;
- HDC hDC = NULL;
+ HDC hdc;
+ PDC pdc;
+ PDC_ATTR pdcattr;
HRGN hVisRgn;
UNICODE_STRING StdDriver;
BOOL calledFromUser;
@@ -791,71 +790,71 @@
}
/* Check for existing DC object */
- if ((hNewDC = DC_FindOpenDC(Driver)) != NULL)
- {
- hDC = NtGdiCreateCompatibleDC(hNewDC);
- if (!hDC)
+ if ((hdc = DC_FindOpenDC(Driver)) != NULL)
+ {
+ hdc = NtGdiCreateCompatibleDC(hdc);
+ if (!hdc)
DPRINT1("NtGdiCreateCompatibleDC() failed\n");
- return hDC;
+ return hdc;
}
/* Allocate a DC object */
- if ((hNewDC = DC_AllocDC(Driver)) == NULL)
+ if ((hdc = DC_AllocDC(Driver)) == NULL)
{
DPRINT1("DC_AllocDC() failed\n");
return NULL;
}
- NewDC = DC_LockDc( hNewDC );
- if ( !NewDC )
- {
- DC_FreeDC( hNewDC );
+ pdc = DC_LockDc( hdc );
+ if ( !pdc )
+ {
+ DC_FreeDC( hdc );
DPRINT1("DC_LockDc() failed\n");
return NULL;
}
- nDc_Attr = NewDC->pdcattr;
-
- NewDC->dctype = DC_TYPE_DIRECT;
-
- NewDC->dhpdev = PrimarySurface.hPDev;
- if(pUMdhpdev) pUMdhpdev = NewDC->dhpdev; // set DHPDEV for device.
- NewDC->ppdev = (PVOID)&PrimarySurface;
- NewDC->rosdc.hBitmap = (HBITMAP)PrimarySurface.pSurface;
+ pdcattr = pdc->pdcattr;
+
+ pdc->dctype = DC_TYPE_DIRECT;
+
+ pdc->dhpdev = PrimarySurface.hPDev;
+ if(pUMdhpdev) pUMdhpdev = pdc->dhpdev; // set DHPDEV for device.
+ pdc->ppdev = (PVOID)&PrimarySurface;
+ pdc->rosdc.hBitmap = (HBITMAP)PrimarySurface.pSurface;
// ATM we only have one display.
- nDc_Attr->ulDirty_ |= DC_PRIMARY_DISPLAY;
-
- NewDC->rosdc.bitsPerPixel = ((PGDIDEVICE)NewDC->ppdev)->GDIInfo.cBitsPixel *
- ((PGDIDEVICE)NewDC->ppdev)->GDIInfo.cPlanes;
- DPRINT("Bits per pel: %u\n", NewDC->rosdc.bitsPerPixel);
-
- NewDC->flGraphicsCaps = PrimarySurface.DevInfo.flGraphicsCaps;
- NewDC->flGraphicsCaps2 = PrimarySurface.DevInfo.flGraphicsCaps2;
-
- NewDC->DcLevel.hpal = NtGdiGetStockObject(DEFAULT_PALETTE);
-
- nDc_Attr->jROP2 = R2_COPYPEN;
-
- NewDC->erclWindow.top = NewDC->erclWindow.left = 0;
- NewDC->erclWindow.right = ((PGDIDEVICE)NewDC->ppdev)->GDIInfo.ulHorzRes;
- NewDC->erclWindow.bottom = ((PGDIDEVICE)NewDC->ppdev)->GDIInfo.ulVertRes;
- NewDC->DcLevel.flPath &= ~DCPATH_CLOCKWISE; // Default is CCW.
-
- nDc_Attr->iCS_CP = ftGdiGetTextCharsetInfo(NewDC,NULL,0);
-
- hVisRgn = NtGdiCreateRectRgn(0, 0,
((PGDIDEVICE)NewDC->ppdev)->GDIInfo.ulHorzRes,
-
((PGDIDEVICE)NewDC->ppdev)->GDIInfo.ulVertRes);
+ pdcattr->ulDirty_ |= DC_PRIMARY_DISPLAY;
+
+ pdc->rosdc.bitsPerPixel = ((PGDIDEVICE)pdc->ppdev)->GDIInfo.cBitsPixel *
+ ((PGDIDEVICE)pdc->ppdev)->GDIInfo.cPlanes;
+ DPRINT("Bits per pel: %u\n", pdc->rosdc.bitsPerPixel);
+
+ pdc->flGraphicsCaps = PrimarySurface.DevInfo.flGraphicsCaps;
+ pdc->flGraphicsCaps2 = PrimarySurface.DevInfo.flGraphicsCaps2;
+
+ pdc->dclevel.hpal = NtGdiGetStockObject(DEFAULT_PALETTE);
+
+ pdcattr->jROP2 = R2_COPYPEN;
+
+ pdc->erclWindow.top = pdc->erclWindow.left = 0;
+ pdc->erclWindow.right = ((PGDIDEVICE)pdc->ppdev)->GDIInfo.ulHorzRes;
+ pdc->erclWindow.bottom = ((PGDIDEVICE)pdc->ppdev)->GDIInfo.ulVertRes;
+ pdc->dclevel.flPath &= ~DCPATH_CLOCKWISE; // Default is CCW.
+
+ pdcattr->iCS_CP = ftGdiGetTextCharsetInfo(pdc,NULL,0);
+
+ hVisRgn = NtGdiCreateRectRgn(0, 0, ((PGDIDEVICE)pdc->ppdev)->GDIInfo.ulHorzRes,
+ ((PGDIDEVICE)pdc->ppdev)->GDIInfo.ulVertRes);
if (!CreateAsIC)
{
- NewDC->pSurfInfo = NULL;
-// NewDC->DcLevel.pSurface =
- DC_UnlockDc( NewDC );
+ pdc->pSurfInfo = NULL;
+// pdc->dclevel.pSurface =
+ DC_UnlockDc( pdc );
/* Initialize the DC state */
- DC_InitDC(hNewDC);
- IntGdiSetTextColor(hNewDC, RGB(0, 0, 0));
- IntGdiSetBkColor(hNewDC, RGB(255, 255, 255));
+ DC_InitDC(hdc);
+ IntGdiSetTextColor(hdc, RGB(0, 0, 0));
+ IntGdiSetBkColor(hdc, RGB(255, 255, 255));
}
else
{
@@ -865,24 +864,24 @@
device without creating a device context (DC). However, GDI drawing functions
cannot accept a handle to an information context.
*/
- NewDC->dctype = DC_TYPE_INFO;
-// NewDC->pSurfInfo =
- NewDC->DcLevel.pSurface = NULL;
- nDc_Attr->crBackgroundClr = nDc_Attr->ulBackgroundClr = RGB(255, 255, 255);
- nDc_Attr->crForegroundClr = RGB(0, 0, 0);
- DC_UnlockDc( NewDC );
+ pdc->dctype = DC_TYPE_INFO;
+// pdc->pSurfInfo =
+ pdc->dclevel.pSurface = NULL;
+ pdcattr->crBackgroundClr = pdcattr->ulBackgroundClr = RGB(255, 255, 255);
+ pdcattr->crForegroundClr = RGB(0, 0, 0);
+ DC_UnlockDc( pdc );
}
if (hVisRgn)
{
- GdiSelectVisRgn(hNewDC, hVisRgn);
+ GdiSelectVisRgn(hdc, hVisRgn);
NtGdiDeleteObject(hVisRgn);
}
- IntGdiSetTextAlign(hNewDC, TA_TOP);
- IntGdiSetBkMode(hNewDC, OPAQUE);
-
- return hNewDC;
+ IntGdiSetTextAlign(hdc, TA_TOP);
+ IntGdiSetBkMode(hdc, OPAQUE);
+
+ return hdc;
}
HDC APIENTRY
@@ -981,7 +980,7 @@
return NULL;
}
RtlZeroMemory(defaultDCstate, sizeof(DC));
- defaultDCstate->pdcattr = &defaultDCstate->Dc_Attr;
+ defaultDCstate->pdcattr = &defaultDCstate->dcattr;
IntGdiCopyToSaveState(dc, defaultDCstate);
DC_UnlockDc( dc );
}
@@ -1026,7 +1025,7 @@
}
/* First delete all saved DCs */
- while (DCToDelete->DcLevel.lSaveDepth)
+ while (DCToDelete->dclevel.lSaveDepth)
{
PDC savedDC;
HDC savedHDC;
@@ -1038,13 +1037,13 @@
break;
}
DC_SetNextDC (DCToDelete, DC_GetNextDC (savedDC));
- DCToDelete->DcLevel.lSaveDepth--;
+ DCToDelete->dclevel.lSaveDepth--;
DC_UnlockDc( savedDC );
IntGdiDeleteDC(savedHDC, Force);
}
/* Free GDI resources allocated to this DC */
- if (!(DCToDelete->DcLevel.flPath & DCPATH_SAVESTATE))
+ if (!(DCToDelete->dclevel.flPath & DCPATH_SAVESTATE))
{
/*
NtGdiSelectPen (DCHandle, STOCK_BLACK_PEN);
@@ -1072,7 +1071,7 @@
{
NtGdiDeleteObject (DCToDelete->rosdc.hGCClipRgn);
}
- PATH_Delete(DCToDelete->DcLevel.hPath);
+ PATH_Delete(DCToDelete->dclevel.hPath);
DC_UnlockDc( DCToDelete );
DC_FreeDC ( hDC );
@@ -1160,7 +1159,7 @@
SelObject = pdcattr->hbrush;
break;
case GDI_OBJECT_TYPE_PALETTE:
- SelObject = dc->DcLevel.hpal;
+ SelObject = dc->dclevel.hpal;
break;
case GDI_OBJECT_TYPE_FONT:
SelObject = pdcattr->hlfntNew;
@@ -1170,7 +1169,7 @@
break;
case GDI_OBJECT_TYPE_COLORSPACE:
DPRINT1("FIXME: NtGdiGetCurrentObject() ObjectType OBJ_COLORSPACE not
supported yet!\n");
- // SelObject = dc->DcLevel.pColorSpace.BaseObject.hHmgr; ?
+ // SelObject = dc->dclevel.pColorSpace.BaseObject.hHmgr; ?
SelObject = NULL;
break;
default:
@@ -1186,8 +1185,8 @@
LONG FASTCALL
IntCalcFillOrigin(PDC pdc)
{
- pdc->ptlFillOrigin.x = pdc->DcLevel.ptlBrushOrigin.x + pdc->ptlDCOrig.x;
- pdc->ptlFillOrigin.y = pdc->DcLevel.ptlBrushOrigin.y + pdc->ptlDCOrig.y;
+ pdc->ptlFillOrigin.x = pdc->dclevel.ptlBrushOrigin.x + pdc->ptlDCOrig.x;
+ pdc->ptlFillOrigin.y = pdc->dclevel.ptlBrushOrigin.y + pdc->ptlDCOrig.y;
return pdc->ptlFillOrigin.y;
}
@@ -1375,14 +1374,14 @@
pdcattr = dc->pdcattr;
nDc_Attr = newdc->pdcattr;
- newdc->DcLevel.flPath = dc->DcLevel.flPath | DCPATH_SAVESTATE;
+ newdc->dclevel.flPath = dc->dclevel.flPath | DCPATH_SAVESTATE;
nDc_Attr->dwLayout = pdcattr->dwLayout;
nDc_Attr->hpen = pdcattr->hpen;
nDc_Attr->hbrush = pdcattr->hbrush;
nDc_Attr->hlfntNew = pdcattr->hlfntNew;
newdc->rosdc.hBitmap = dc->rosdc.hBitmap;
- newdc->DcLevel.hpal = dc->DcLevel.hpal;
+ newdc->dclevel.hpal = dc->dclevel.hpal;
newdc->rosdc.bitsPerPixel = dc->rosdc.bitsPerPixel;
nDc_Attr->jROP2 = pdcattr->jROP2;
nDc_Attr->jFillMode = pdcattr->jFillMode;
@@ -1408,20 +1407,20 @@
#endif
nDc_Attr->ptlCurrent = pdcattr->ptlCurrent;
nDc_Attr->ptfxCurrent = pdcattr->ptfxCurrent;
- newdc->DcLevel.mxWorldToDevice = dc->DcLevel.mxWorldToDevice;
- newdc->DcLevel.mxDeviceToWorld = dc->DcLevel.mxDeviceToWorld;
- newdc->DcLevel.mxWorldToPage = dc->DcLevel.mxWorldToPage;
+ newdc->dclevel.mxWorldToDevice = dc->dclevel.mxWorldToDevice;
+ newdc->dclevel.mxDeviceToWorld = dc->dclevel.mxDeviceToWorld;
+ newdc->dclevel.mxWorldToPage = dc->dclevel.mxWorldToPage;
nDc_Attr->flXform = pdcattr->flXform;
nDc_Attr->ptlWindowOrg = pdcattr->ptlWindowOrg;
nDc_Attr->szlWindowExt = pdcattr->szlWindowExt;
nDc_Attr->ptlViewportOrg = pdcattr->ptlViewportOrg;
nDc_Attr->szlViewportExt = pdcattr->szlViewportExt;
- newdc->DcLevel.lSaveDepth = 0;
+ newdc->dclevel.lSaveDepth = 0;
newdc->dctype = dc->dctype;
#if 0
- PATH_InitGdiPath( &newdc->DcLevel.hPath );
+ PATH_InitGdiPath( &newdc->dclevel.hPath );
#endif
/* Get/SetDCState() don't change hVisRgn field ("Undoc. Windows" p.559).
*/
@@ -1444,7 +1443,7 @@
pdcattr = dc->pdcattr;
sDc_Attr = dcs->pdcattr;
- dc->DcLevel.flPath = dcs->DcLevel.flPath & ~DCPATH_SAVESTATE;
+ dc->dclevel.flPath = dcs->dclevel.flPath & ~DCPATH_SAVESTATE;
pdcattr->dwLayout = sDc_Attr->dwLayout;
pdcattr->jROP2 = sDc_Attr->jROP2;
@@ -1472,9 +1471,9 @@
#endif
pdcattr->ptlCurrent = sDc_Attr->ptlCurrent;
pdcattr->ptfxCurrent = sDc_Attr->ptfxCurrent;
- dc->DcLevel.mxWorldToDevice = dcs->DcLevel.mxWorldToDevice;
- dc->DcLevel.mxDeviceToWorld = dcs->DcLevel.mxDeviceToWorld;
- dc->DcLevel.mxWorldToPage = dcs->DcLevel.mxWorldToPage;
+ dc->dclevel.mxWorldToDevice = dcs->dclevel.mxWorldToDevice;
+ dc->dclevel.mxDeviceToWorld = dcs->dclevel.mxDeviceToWorld;
+ dc->dclevel.mxWorldToPage = dcs->dclevel.mxWorldToPage;
pdcattr->flXform = sDc_Attr->flXform;
pdcattr->ptlWindowOrg = sDc_Attr->ptlWindowOrg;
pdcattr->szlWindowExt = sDc_Attr->szlWindowExt;
@@ -1523,10 +1522,10 @@
IntGdiSetBkColor( hDC, sDc_Attr->crBackgroundClr);
IntGdiSetTextColor( hDC, sDc_Attr->crForegroundClr);
- GdiSelectPalette( hDC, dcs->DcLevel.hpal, FALSE );
+ GdiSelectPalette( hDC, dcs->dclevel.hpal, FALSE );
#if 0
- GDISelectPalette16( hDC, dcs->DcLevel.hpal, FALSE );
+ GDISelectPalette16( hDC, dcs->dclevel.hpal, FALSE );
#endif
}
@@ -1553,7 +1552,7 @@
/* FIXME - newdc can be NULL!!!! Don't assert here!!! */
ASSERT( newdc );
- newdc->DcLevel.hdcSave = hnewdc;
+ newdc->dclevel.hdcSave = hnewdc;
IntGdiCopyToSaveState( dc, newdc);
DC_UnlockDc( newdc );
@@ -1574,9 +1573,9 @@
dcs = DC_LockDc ( hDCSave );
if ( dcs )
{
- if ( dcs->DcLevel.flPath & DCPATH_SAVESTATE )
+ if ( dcs->dclevel.flPath & DCPATH_SAVESTATE )
{
- IntGdiCopyFromSaveState( dc, dcs, dc->DcLevel.hdcSave);
+ IntGdiCopyFromSaveState( dc, dcs, dc->dclevel.hdcSave);
}
else
{
@@ -1981,16 +1980,16 @@
}
if (SaveLevel < 0)
- SaveLevel = dc->DcLevel.lSaveDepth + SaveLevel + 1;
-
- if(SaveLevel < 0 || dc->DcLevel.lSaveDepth<SaveLevel)
+ SaveLevel = dc->dclevel.lSaveDepth + SaveLevel + 1;
+
+ if(SaveLevel < 0 || dc->dclevel.lSaveDepth<SaveLevel)
{
DC_UnlockDc(dc);
return FALSE;
}
success=TRUE;
- while (dc->DcLevel.lSaveDepth >= SaveLevel)
+ while (dc->dclevel.lSaveDepth >= SaveLevel)
{
HDC hdcs = DC_GetNextDC (dc);
@@ -2004,7 +2003,7 @@
DC_SetNextDC (dc, DC_GetNextDC (dcs));
dcs->hdcNext = 0;
- if (--dc->DcLevel.lSaveDepth < SaveLevel)
+ if (--dc->dclevel.lSaveDepth < SaveLevel)
{
DC_UnlockDc( dc );
DC_UnlockDc( dcs );
@@ -2018,11 +2017,11 @@
}
// Restore Path by removing it, if the Save flag is set.
// BeginPath will takecare of the rest.
- if ( dc->DcLevel.hPath && dc->DcLevel.flPath & DCPATH_SAVE)
+ if ( dc->dclevel.hPath && dc->dclevel.flPath & DCPATH_SAVE)
{
- PATH_Delete(dc->DcLevel.hPath);
- dc->DcLevel.hPath = 0;
- dc->DcLevel.flPath &= ~DCPATH_SAVE;
+ PATH_Delete(dc->dclevel.hPath);
+ dc->dclevel.hPath = 0;
+ dc->dclevel.flPath &= ~DCPATH_SAVE;
}
}
else
@@ -2067,12 +2066,12 @@
/*
* Copy path.
*/
- dcs->DcLevel.hPath = dc->DcLevel.hPath;
- if (dcs->DcLevel.hPath) dcs->DcLevel.flPath |= DCPATH_SAVE;
+ dcs->dclevel.hPath = dc->dclevel.hPath;
+ if (dcs->dclevel.hPath) dcs->dclevel.flPath |= DCPATH_SAVE;
DC_SetNextDC (dcs, DC_GetNextDC (dc));
DC_SetNextDC (dc, hdcs);
- ret = ++dc->DcLevel.lSaveDepth;
+ ret = ++dc->dclevel.lSaveDepth;
DC_UnlockDc( dcs );
DC_UnlockDc( dc );
@@ -2109,13 +2108,13 @@
if ((dc->rosdc.bitsPerPixel <= 8 && PalGDI->Mode == PAL_INDEXED) ||
(dc->rosdc.bitsPerPixel > 8 && PalGDI->Mode != PAL_INDEXED))
{
- oldPal = dc->DcLevel.hpal;
- dc->DcLevel.hpal = hpal;
+ oldPal = dc->dclevel.hpal;
+ dc->dclevel.hpal = hpal;
}
else if (8 < dc->rosdc.bitsPerPixel && PAL_INDEXED == PalGDI->Mode)
{
- oldPal = dc->DcLevel.hpal;
- dc->DcLevel.hpal = hpal;
+ oldPal = dc->dclevel.hpal;
+ dc->dclevel.hpal = hpal;
}
PALETTE_UnlockPalette(PalGDI);
@@ -2202,9 +2201,9 @@
break;
case GdiGetArcDirection:
if (pdcattr->dwLayout & LAYOUT_RTL)
- SafeResult = AD_CLOCKWISE - ((dc->DcLevel.flPath & DCPATH_CLOCKWISE) !=
0);
+ SafeResult = AD_CLOCKWISE - ((dc->dclevel.flPath & DCPATH_CLOCKWISE) !=
0);
else
- SafeResult = ((dc->DcLevel.flPath & DCPATH_CLOCKWISE) != 0) +
AD_COUNTERCLOCKWISE;
+ SafeResult = ((dc->dclevel.flPath & DCPATH_CLOCKWISE) != 0) +
AD_COUNTERCLOCKWISE;
break;
case GdiGetEMFRestorDc:
break;
@@ -2326,23 +2325,23 @@
}
if ( pdcattr->dwLayout & LAYOUT_RTL ) // Right to Left
{
- SafeResult = AD_CLOCKWISE - ((dc->DcLevel.flPath & DCPATH_CLOCKWISE) !=
0);
+ SafeResult = AD_CLOCKWISE - ((dc->dclevel.flPath & DCPATH_CLOCKWISE) !=
0);
if ( dwIn == AD_CLOCKWISE )
{
- dc->DcLevel.flPath &= ~DCPATH_CLOCKWISE;
+ dc->dclevel.flPath &= ~DCPATH_CLOCKWISE;
break;
}
- dc->DcLevel.flPath |= DCPATH_CLOCKWISE;
+ dc->dclevel.flPath |= DCPATH_CLOCKWISE;
}
else // Left to Right
{
- SafeResult = ((dc->DcLevel.flPath & DCPATH_CLOCKWISE) != 0) +
AD_COUNTERCLOCKWISE;
+ SafeResult = ((dc->dclevel.flPath & DCPATH_CLOCKWISE) != 0) +
AD_COUNTERCLOCKWISE;
if ( dwIn == AD_COUNTERCLOCKWISE)
{
- dc->DcLevel.flPath &= ~DCPATH_CLOCKWISE;
+ dc->dclevel.flPath &= ~DCPATH_CLOCKWISE;
break;
}
- dc->DcLevel.flPath |= DCPATH_CLOCKWISE;
+ dc->dclevel.flPath |= DCPATH_CLOCKWISE;
}
break;
default:
@@ -2413,7 +2412,7 @@
hDC = NewDC->BaseObject.hHmgr;
- NewDC->pdcattr = &NewDC->Dc_Attr;
+ NewDC->pdcattr = &NewDC->dcattr;
DC_AllocateDcAttr(hDC);
if (Driver != NULL)
@@ -2431,9 +2430,9 @@
xformTemplate.eM22 = 1.0f;
xformTemplate.eDx = 0.0f;
xformTemplate.eDy = 0.0f;
- XForm2MatrixS(&NewDC->DcLevel.mxWorldToDevice, &xformTemplate);
- XForm2MatrixS(&NewDC->DcLevel.mxDeviceToWorld, &xformTemplate);
- XForm2MatrixS(&NewDC->DcLevel.mxWorldToPage, &xformTemplate);
+ XForm2MatrixS(&NewDC->dclevel.mxWorldToDevice, &xformTemplate);
+ XForm2MatrixS(&NewDC->dclevel.mxDeviceToWorld, &xformTemplate);
+ XForm2MatrixS(&NewDC->dclevel.mxWorldToPage, &xformTemplate);
// Setup syncing bits for the dcattr data packets.
pdcattr->flXform = DEVICE_TO_PAGE_INVALID;
@@ -2468,8 +2467,8 @@
pdcattr->hlfntNew = NtGdiGetStockObject(SYSTEM_FONT);
TextIntRealizeFont(pdcattr->hlfntNew,NULL);
- NewDC->DcLevel.hpal = NtGdiGetStockObject(DEFAULT_PALETTE);
- NewDC->DcLevel.laPath.eMiterLimit = 10.0;
+ NewDC->dclevel.hpal = NtGdiGetStockObject(DEFAULT_PALETTE);
+ NewDC->dclevel.laPath.eMiterLimit = 10.0;
DC_UnlockDc(NewDC);
@@ -2538,7 +2537,7 @@
}
KeLeaveCriticalRegion();
pDC = DC_LockDc(hDC);
- ASSERT(pDC->pdcattr == &pDC->Dc_Attr);
+ ASSERT(pDC->pdcattr == &pDC->dcattr);
if(NewMem)
{
pDC->pdcattr = NewMem; // Store pointer
@@ -2552,8 +2551,8 @@
{
HANDLE Pid = NtCurrentProcess();
PDC pDC = DC_LockDc(DCToFree);
- if (pDC->pdcattr == &pDC->Dc_Attr) return; // Internal DC object!
- pDC->pdcattr = &pDC->Dc_Attr;
+ if (pDC->pdcattr == &pDC->dcattr) return; // Internal DC object!
+ pDC->pdcattr = &pDC->dcattr;
DC_UnlockDc(pDC);
KeEnterCriticalRegion();
@@ -2634,12 +2633,12 @@
xformWnd2Vport.eDy = (FLOAT)pdcattr->ptlViewportOrg.y - scaleY *
(FLOAT)pdcattr->ptlWindowOrg.y;
/* Combine with the world transformation */
- MatrixS2XForm(&xformWorld2Vport, &dc->DcLevel.mxWorldToDevice);
- MatrixS2XForm(&xformWorld2Wnd, &dc->DcLevel.mxWorldToPage);
+ MatrixS2XForm(&xformWorld2Vport, &dc->dclevel.mxWorldToDevice);
+ MatrixS2XForm(&xformWorld2Wnd, &dc->dclevel.mxWorldToPage);
IntGdiCombineTransform(&xformWorld2Vport, &xformWorld2Wnd,
&xformWnd2Vport);
/* Create inverse of world-to-viewport transformation */
- MatrixS2XForm(&xformVport2World, &dc->DcLevel.mxDeviceToWorld);
+ MatrixS2XForm(&xformVport2World, &dc->dclevel.mxDeviceToWorld);
if (DC_InvertXform(&xformWorld2Vport, &xformVport2World))
{
pdcattr->flXform &= ~DEVICE_TO_WORLD_INVALID;
@@ -2649,7 +2648,7 @@
pdcattr->flXform |= DEVICE_TO_WORLD_INVALID;
}
- XForm2MatrixS(&dc->DcLevel.mxWorldToDevice, &xformWorld2Vport);
+ XForm2MatrixS(&dc->dclevel.mxWorldToDevice, &xformWorld2Vport);
}
@@ -2697,9 +2696,9 @@
{
if(!GDIOBJ_SetOwnership(pDC->rosdc.hGCClipRgn, Owner)) return FALSE;
}
- if (pDC->DcLevel.hPath)
+ if (pDC->dclevel.hPath)
{
- if(!GDIOBJ_SetOwnership(pDC->DcLevel.hPath, Owner)) return FALSE;
+ if(!GDIOBJ_SetOwnership(pDC->dclevel.hPath, Owner)) return FALSE;
}
DC_UnlockDc(pDC);
}
Modified: trunk/reactos/subsystems/win32/win32k/objects/dcutil.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/dcutil.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/dcutil.c [iso-8859-1] Fri Mar 20
17:16:01 2009
@@ -110,9 +110,9 @@
CopytoUserDcAttr(PDC dc, PDC_ATTR pdcattr)
{
NTSTATUS Status = STATUS_SUCCESS;
- dc->Dc_Attr.mxWorldToDevice = dc->DcLevel.mxWorldToDevice;
- dc->Dc_Attr.mxDeviceToWorld = dc->DcLevel.mxDeviceToWorld;
- dc->Dc_Attr.mxWorldToPage = dc->DcLevel.mxWorldToPage;
+ dc->dcattr.mxWorldToDevice = dc->dclevel.mxWorldToDevice;
+ dc->dcattr.mxDeviceToWorld = dc->dclevel.mxDeviceToWorld;
+ dc->dcattr.mxWorldToPage = dc->dclevel.mxWorldToPage;
_SEH2_TRY
{
@@ -120,7 +120,7 @@
sizeof(DC_ATTR),
1);
RtlCopyMemory( pdcattr,
- &dc->Dc_Attr,
+ &dc->dcattr,
sizeof(DC_ATTR));
}
_SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER)
@@ -138,7 +138,7 @@
{
PDC_ATTR pdcattr = dc->pdcattr;
- if (pdcattr == &dc->Dc_Attr) return TRUE; // No need to copy self.
+ if (pdcattr == &dc->dcattr) return TRUE; // No need to copy self.
ASSERT(pdcattr);
CopytoUserDcAttr( dc, pdcattr);
return TRUE;
Modified: trunk/reactos/subsystems/win32/win32k/objects/dibobj.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/dibobj.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/dibobj.c [iso-8859-1] Fri Mar 20
17:16:01 2009
@@ -1604,7 +1604,7 @@
USHORT *lpIndex;
PPALGDI palGDI;
- palGDI = PALETTE_LockPalette(dc->DcLevel.hpal);
+ palGDI = PALETTE_LockPalette(dc->dclevel.hpal);
if (NULL == palGDI)
{
Modified: trunk/reactos/subsystems/win32/win32k/objects/drawing.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/drawing.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/drawing.c [iso-8859-1] Fri Mar 20
17:16:01 2009
@@ -1287,8 +1287,8 @@
}
// Sort out alignment here.
ret = app_fill_arc(dc, rect( XLeft, YLeft, Width, Height),
- (dc->DcLevel.flPath & DCPATH_CLOCKWISE) ? -End : -Start,
- (dc->DcLevel.flPath & DCPATH_CLOCKWISE) ? -Start : -End,
+ (dc->dclevel.flPath & DCPATH_CLOCKWISE) ? -End : -Start,
+ (dc->dclevel.flPath & DCPATH_CLOCKWISE) ? -Start : -End,
FillBrushObj, Chord);
BRUSHOBJ_UnlockBrush(FillBrushObj);
@@ -1312,8 +1312,8 @@
BOOL Chord = (arctype == GdiTypeChord);
// Sort out alignment here.
return app_draw_arc(dc, rect( XLeft, YLeft, Width, Height),
- (dc->DcLevel.flPath & DCPATH_CLOCKWISE) ? -End : -Start,
- (dc->DcLevel.flPath & DCPATH_CLOCKWISE) ? -Start : -End,
+ (dc->dclevel.flPath & DCPATH_CLOCKWISE) ? -End : -Start,
+ (dc->dclevel.flPath & DCPATH_CLOCKWISE) ? -Start : -End,
PenBrushObj, Chord);
}
Modified: trunk/reactos/subsystems/win32/win32k/objects/fillshap.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/fillshap.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/fillshap.c [iso-8859-1] Fri Mar 20
17:16:01 2009
@@ -21,25 +21,6 @@
#define NDEBUG
#include <debug.h>
-
-/*
- * a couple macros to fill a single pixel or a line
- */
-#define PUTPIXEL(x,y,BrushInst) \
- ret = ret && IntEngLineTo(&psurf->SurfObj, \
- dc->CombinedClip, \
- &BrushInst.BrushObject, \
- x, y, (x)+1, y, \
- &RectBounds, \
- ROP2_TO_MIX(Dc_Attr->jROP2));
-
-#define PUTLINE(x1,y1,x2,y2,BrushInst) \
- ret = ret && IntEngLineTo(&psurf->SurfObj, \
- dc->CombinedClip, \
- &BrushInst.BrushObject, \
- x1, y1, x2, y2, \
- &RectBounds, \
- ROP2_TO_MIX(Dc_Attr->jROP2));
#define Rsin(d) ((d) == 0.0 ? 0.0 : ((d) == 90.0 ? 1.0 : sin(d*M_PI/180.0)))
#define Rcos(d) ((d) == 0.0 ? 1.0 : ((d) == 90.0 ? 0.0 : cos(d*M_PI/180.0)))
@@ -186,7 +167,7 @@
PULONG PolyCounts,
int Count)
{
- if (PATH_IsPathOpen(dc->DcLevel))
+ if (PATH_IsPathOpen(dc->dclevel))
return PATH_PolyPolygon ( dc, Points, (PINT)PolyCounts, Count);
while (--Count >=0)
@@ -247,7 +228,7 @@
return TRUE;
}
- if (PATH_IsPathOpen(dc->DcLevel))
+ if (PATH_IsPathOpen(dc->dclevel))
{
ret = PATH_Ellipse(dc, Left, Top, Right, Bottom);
DC_UnlockDc(dc);
@@ -554,7 +535,7 @@
pdcattr = dc->pdcattr;
/* Do we rotate or shear? */
- if (!(dc->DcLevel.mxWorldToDevice.flAccel & MX_SCALE))
+ if (!(dc->dclevel.mxWorldToDevice.flAccel & MX_SCALE))
{
POINTL DestCoords[4];
@@ -567,7 +548,7 @@
return IntGdiPolyPolygon(dc, DestCoords, &PolyCounts, 1);
}
// Rectangle Path only.
- if ( PATH_IsPathOpen(dc->DcLevel) )
+ if ( PATH_IsPathOpen(dc->dclevel) )
{
return PATH_Rectangle ( dc, LeftRect, TopRect, RightRect, BottomRect );
}
@@ -740,7 +721,7 @@
ASSERT ( dc ); // caller's responsibility to set this up
- if ( PATH_IsPathOpen(dc->DcLevel) )
+ if ( PATH_IsPathOpen(dc->dclevel) )
return PATH_RoundRect ( dc, Left, Top, Right, Bottom,
xCurveDiameter, yCurveDiameter );
Modified: trunk/reactos/subsystems/win32/win32k/objects/freetype.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/freetype.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/freetype.c [iso-8859-1] Fri Mar 20
17:16:01 2009
@@ -1500,7 +1500,7 @@
pdcattr = dc->pdcattr;
- MatrixS2XForm(&xForm, &dc->DcLevel.mxWorldToDevice);
+ MatrixS2XForm(&xForm, &dc->dclevel.mxWorldToDevice);
eM11 = xForm.eM11;
hFont = pdcattr->hlfntNew;
@@ -3178,7 +3178,7 @@
DxShift = fuOptions & ETO_PDY ? 1 : 0;
- if (PATH_IsPathOpen(dc->DcLevel))
+ if (PATH_IsPathOpen(dc->dclevel))
{
if (!PATH_ExtTextOut( dc,
XStart,
Modified: trunk/reactos/subsystems/win32/win32k/objects/gdiobj.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/gdiobj.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/gdiobj.c [iso-8859-1] Fri Mar 20
17:16:01 2009
@@ -1562,7 +1562,7 @@
if ((OwnerMask == GDI_OBJ_HMGR_PUBLIC) || OwnerMask == GDI_OBJ_HMGR_NONE)
{
pDC = DC_LockDc ( hDC );
- MmCopyFromCaller(&pDC->Dc_Attr, pDC->pdcattr, sizeof(DC_ATTR));
+ MmCopyFromCaller(&pDC->dcattr, pDC->pdcattr, sizeof(DC_ATTR));
DC_UnlockDc( pDC );
DC_FreeDcAttr( hDC ); // Free the dcattr!
@@ -1574,7 +1574,7 @@
if (OwnerMask == GDI_OBJ_HMGR_POWNED)
{
pDC = DC_LockDc ( hDC );
- ASSERT(pDC->pdcattr == &pDC->Dc_Attr);
+ ASSERT(pDC->pdcattr == &pDC->dcattr);
DC_UnlockDc( pDC );
if (!DC_SetOwnership( hDC, PsGetCurrentProcess() )) return Ret;
@@ -1587,8 +1587,8 @@
if ((OwnerMask != GDI_OBJ_HMGR_NONE) && !NoSetBrush)
{
pDC = DC_LockDc ( hDC );
- if (IntGdiSetBrushOwner((PGDIBRUSHOBJ)pDC->DcLevel.pbrFill, OwnerMask))
- IntGdiSetBrushOwner((PGDIBRUSHOBJ)pDC->DcLevel.pbrLine, OwnerMask);
+ if (IntGdiSetBrushOwner((PGDIBRUSHOBJ)pDC->dclevel.pbrFill, OwnerMask))
+ IntGdiSetBrushOwner((PGDIBRUSHOBJ)pDC->dclevel.pbrLine, OwnerMask);
DC_UnlockDc( pDC );
}
return TRUE;
Modified: trunk/reactos/subsystems/win32/win32k/objects/icm.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/icm.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/icm.c [iso-8859-1] Fri Mar 20 17:16:01
2009
@@ -214,12 +214,12 @@
return FALSE;
}
- if (pDC->DcLevel.pColorSpace)
- {
- GDIOBJ_ShareUnlockObjByPtr((POBJ) pDC->DcLevel.pColorSpace);
- }
-
- pDC->DcLevel.pColorSpace = pCS;
+ if (pDC->dclevel.pColorSpace)
+ {
+ GDIOBJ_ShareUnlockObjByPtr((POBJ) pDC->dclevel.pColorSpace);
+ }
+
+ pDC->dclevel.pColorSpace = pCS;
pdcattr->hColorSpace = hColorSpace;
COLORSPACEOBJ_UnlockCS(pCS);
Modified: trunk/reactos/subsystems/win32/win32k/objects/line.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/line.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/line.c [iso-8859-1] Fri Mar 20 17:16:01
2009
@@ -54,7 +54,7 @@
CoordLPtoDP(dc, &pdcattr->ptfxCurrent); // Update fx
pdcattr->ulDirty_ &= ~(DIRTY_PTLCURRENT|DIRTY_PTFXCURRENT|DIRTY_STYLESTATE);
- PathIsOpen = PATH_IsPathOpen(dc->DcLevel);
+ PathIsOpen = PATH_IsPathOpen(dc->dclevel);
if ( PathIsOpen )
return PATH_MoveTo ( dc );
@@ -96,7 +96,7 @@
PDC_ATTR pdcattr = dc->pdcattr;
- if (PATH_IsPathOpen(dc->DcLevel))
+ if (PATH_IsPathOpen(dc->dclevel))
{
Ret = PATH_LineTo(dc, XEnd, YEnd);
if (Ret)
@@ -187,7 +187,7 @@
{
BOOL ret = FALSE; // default to FAILURE
- if ( PATH_IsPathOpen(dc->DcLevel) )
+ if ( PATH_IsPathOpen(dc->dclevel) )
{
return PATH_PolyBezier ( dc, pt, Count );
}
@@ -216,7 +216,7 @@
BOOL ret = FALSE; // default to failure
PDC_ATTR pdcattr = dc->pdcattr;
- if ( PATH_IsPathOpen(dc->DcLevel) )
+ if ( PATH_IsPathOpen(dc->dclevel) )
ret = PATH_PolyBezierTo ( dc, pt, Count );
else /* We'll do it using PolyBezier */
{
@@ -258,7 +258,7 @@
LONG i;
PDC_ATTR pdcattr = dc->pdcattr;
- if (PATH_IsPathOpen(dc->DcLevel))
+ if (PATH_IsPathOpen(dc->dclevel))
return PATH_Polyline(dc, pt, Count);
if (pdcattr->ulDirty_ & DC_BRUSH_DIRTY)
@@ -322,7 +322,7 @@
BOOL ret = FALSE; // default to failure
PDC_ATTR pdcattr = dc->pdcattr;
- if (PATH_IsPathOpen(dc->DcLevel))
+ if (PATH_IsPathOpen(dc->dclevel))
{
ret = PATH_PolylineTo(dc, pt, Count);
}
@@ -366,7 +366,7 @@
pts = pt;
pc = PolyPoints;
- if (PATH_IsPathOpen(dc->DcLevel))
+ if (PATH_IsPathOpen(dc->dclevel))
return PATH_PolyPolyline( dc, pt, PolyPoints, Count );
for (i = 0; i < Count; i++)
@@ -475,9 +475,9 @@
if ( lpbTypes[i] & PT_CLOSEFIGURE )
{
- if ( PATH_IsPathOpen(dc->DcLevel) )
+ if ( PATH_IsPathOpen(dc->dclevel) )
{
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (pPath)
{
IntGdiCloseFigure( pPath );
Modified: trunk/reactos/subsystems/win32/win32k/objects/path.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/path.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/path.c [iso-8859-1] Fri Mar 20 17:16:01
2009
@@ -133,7 +133,7 @@
* tests show that resetting the graphics mode to GM_COMPATIBLE does
* not reset the world transform.
*/
- MatrixS2XForm(&xform, &dc->DcLevel.mxWorldToPage);
+ MatrixS2XForm(&xform, &dc->dclevel.mxWorldToPage);
/* Set MM_TEXT */
// IntGdiSetMapMode( dc, MM_TEXT );
@@ -240,7 +240,7 @@
FASTCALL
PATH_MoveTo ( PDC dc )
{
- PPATH pPath = PATH_LockPath( dc->DcLevel.hPath );
+ PPATH pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
/* Check that path is open */
@@ -271,7 +271,7 @@
PPATH pPath;
POINT point, pointCurPos;
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
/* Check that path is open */
@@ -318,7 +318,7 @@
POINT corners[2], pointTemp;
INT temp;
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
/* Check that path is open */
@@ -406,7 +406,7 @@
POINT corners[2], pointTemp;
FLOAT_POINT ellCorners[2];
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
/* Check that path is open */
@@ -496,7 +496,7 @@
BOOL Ret = PATH_Arc ( dc, x1, y1, x2, y2, x1, (y1+y2)/2, x1, (y1+y2)/2, GdiTypeArc );
if (Ret)
{
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
IntGdiCloseFigure(pPath);
PATH_UnlockPath( pPath );
@@ -534,10 +534,10 @@
ASSERT ( dc );
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
- clockwise = ((dc->DcLevel.flPath & DCPATH_CLOCKWISE) != 0);
+ clockwise = ((dc->dclevel.flPath & DCPATH_CLOCKWISE) != 0);
/* Check that path is open */
if ( pPath->state != PATH_Open )
@@ -694,7 +694,7 @@
ASSERT ( pts );
ASSERT ( cbPoints );
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
/* Check that path is open */
@@ -739,7 +739,7 @@
ASSERT ( pts );
ASSERT ( cbPoints );
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
/* Check that path is open */
@@ -771,7 +771,7 @@
ASSERT ( pts );
ASSERT ( cbPoints );
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
/* Check that path is open */
@@ -802,7 +802,7 @@
ASSERT ( pts );
ASSERT ( cbPoints );
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
/* Check that path is open */
@@ -847,7 +847,7 @@
ASSERT ( dc );
ASSERT ( pts );
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
/* Check that path is open */
@@ -882,7 +882,7 @@
ASSERT ( counts );
ASSERT ( polygons );
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
/* Check that path is open */
@@ -921,7 +921,7 @@
ASSERT ( counts );
ASSERT ( polylines );
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
/* Check that path is open */
@@ -1348,7 +1348,7 @@
IntGetWindowExtEx(dc, &szWindowExt);
IntGetWindowOrgEx(dc, &ptWindowOrg);
- MatrixS2XForm(&xform, &dc->DcLevel.mxWorldToPage);
+ MatrixS2XForm(&xform, &dc->dclevel.mxWorldToPage);
/* Set MM_TEXT */
pdcattr->iMapMode = MM_TEXT;
@@ -1475,7 +1475,7 @@
pdcattr->ptlViewportOrg.y = ptViewportOrg.y;
/* Restore the world transform */
- XForm2MatrixS(&dc->DcLevel.mxWorldToPage, &xform);
+ XForm2MatrixS(&dc->dclevel.mxWorldToPage, &xform);
/* If we've moved the current point then get its new position
which will be in device (MM_TEXT) co-ords, convert it to
@@ -1508,7 +1508,7 @@
DWORD obj_type, joint, endcap, penType;
PDC_ATTR pdcattr = dc->pdcattr;
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath) return FALSE;
if(pPath->state == PATH_Open)
@@ -1726,7 +1726,7 @@
alpha = atan2( yb - yo, xb - xo ) - theta;
if (alpha > 0) alpha -= M_PI;
else alpha += M_PI;
- if(_joint == PS_JOIN_MITER && dc->DcLevel.laPath.eMiterLimit
< fabs(1 / sin(alpha/2)))
+ if(_joint == PS_JOIN_MITER && dc->dclevel.laPath.eMiterLimit
< fabs(1 / sin(alpha/2)))
{
_joint = PS_JOIN_BEVEL;
}
@@ -1927,7 +1927,7 @@
start = header;
- pPath = PATH_LockPath(dc->DcLevel.hPath);
+ pPath = PATH_LockPath(dc->dclevel.hPath);
{
return FALSE;
}
@@ -2113,7 +2113,7 @@
return FALSE;
}
- pPath = PATH_LockPath(dc->DcLevel.hPath);
+ pPath = PATH_LockPath(dc->dclevel.hPath);
{
DC_UnlockDc(dc);
return FALSE;
@@ -2141,18 +2141,18 @@
}
/* If path is already open, do nothing. Check if not Save DC state */
- if ((dc->DcLevel.flPath & DCPATH_ACTIVE) && !(dc->DcLevel.flPath
& DCPATH_SAVE))
+ if ((dc->dclevel.flPath & DCPATH_ACTIVE) && !(dc->dclevel.flPath
& DCPATH_SAVE))
{
DC_UnlockDc ( dc );
return TRUE;
}
- if ( dc->DcLevel.hPath )
- {
- DPRINT1("BeginPath 1 0x%x\n", dc->DcLevel.hPath);
- if ( !(dc->DcLevel.flPath & DCPATH_SAVE) )
+ if ( dc->dclevel.hPath )
+ {
+ DPRINT1("BeginPath 1 0x%x\n", dc->dclevel.hPath);
+ if ( !(dc->dclevel.flPath & DCPATH_SAVE) )
{ // Remove previous handle.
- if (!PATH_Delete(dc->DcLevel.hPath))
+ if (!PATH_Delete(dc->dclevel.hPath))
{
DC_UnlockDc ( dc );
return FALSE;
@@ -2160,8 +2160,8 @@
}
else
{ // Clear flags and Handle.
- dc->DcLevel.flPath &= ~(DCPATH_SAVE|DCPATH_ACTIVE);
- dc->DcLevel.hPath = NULL;
+ dc->dclevel.flPath &= ~(DCPATH_SAVE|DCPATH_ACTIVE);
+ dc->dclevel.hPath = NULL;
}
}
pPath = PATH_AllocPathWithHandle();
@@ -2170,14 +2170,14 @@
SetLastWin32Error(ERROR_NOT_ENOUGH_MEMORY);
return FALSE;
}
- dc->DcLevel.flPath |= DCPATH_ACTIVE; // Set active ASAP!
-
- dc->DcLevel.hPath = pPath->BaseObject.hHmgr;
-
- DPRINT1("BeginPath 2 h 0x%x p 0x%x\n", dc->DcLevel.hPath, pPath);
+ dc->dclevel.flPath |= DCPATH_ACTIVE; // Set active ASAP!
+
+ dc->dclevel.hPath = pPath->BaseObject.hHmgr;
+
+ DPRINT1("BeginPath 2 h 0x%x p 0x%x\n", dc->dclevel.hPath, pPath);
// Path handles are shared. Also due to recursion with in the same thread.
GDIOBJ_UnlockObjByPtr((POBJ)pPath); // Unlock
- pPath = PATH_LockPath(dc->DcLevel.hPath); // Share Lock.
+ pPath = PATH_LockPath(dc->dclevel.hPath); // Share Lock.
/* Make sure that path is empty */
PATH_EmptyPath( pPath );
@@ -2207,7 +2207,7 @@
SetLastWin32Error(ERROR_INVALID_PARAMETER);
return FALSE;
}
- pPath = PATH_LockPath( pDc->DcLevel.hPath );
+ pPath = PATH_LockPath( pDc->dclevel.hPath );
if (!pPath)
{
DC_UnlockDc(pDc);
@@ -2244,25 +2244,25 @@
return FALSE;
}
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath)
{
DC_UnlockDc ( dc );
return FALSE;
}
/* Check that path is currently being constructed */
- if ( (pPath->state != PATH_Open) || !(dc->DcLevel.flPath & DCPATH_ACTIVE) )
- {
- DPRINT1("EndPath ERROR! 0x%x\n", dc->DcLevel.hPath);
+ if ( (pPath->state != PATH_Open) || !(dc->dclevel.flPath & DCPATH_ACTIVE) )
+ {
+ DPRINT1("EndPath ERROR! 0x%x\n", dc->dclevel.hPath);
SetLastWin32Error(ERROR_CAN_NOT_COMPLETE);
ret = FALSE;
}
/* Set flag to indicate that path is finished */
else
{
- DPRINT1("EndPath 0x%x\n", dc->DcLevel.hPath);
+ DPRINT1("EndPath 0x%x\n", dc->dclevel.hPath);
pPath->state = PATH_Closed;
- dc->DcLevel.flPath &= ~DCPATH_ACTIVE;
+ dc->dclevel.flPath &= ~DCPATH_ACTIVE;
}
PATH_UnlockPath( pPath );
DC_UnlockDc ( dc );
@@ -2283,7 +2283,7 @@
SetLastWin32Error(ERROR_INVALID_PARAMETER);
return FALSE;
}
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath)
{
DC_UnlockDc ( dc );
@@ -2325,7 +2325,7 @@
return FALSE;
}
- pPath = PATH_LockPath( pDc->DcLevel.hPath );
+ pPath = PATH_LockPath( pDc->dclevel.hPath );
if (!pPath)
{
DC_UnlockDc ( pDc );
@@ -2356,7 +2356,7 @@
return FALSE;
}
- worker.f = pDc->DcLevel.laPath.eMiterLimit;
+ worker.f = pDc->dclevel.laPath.eMiterLimit;
if (pdwOut)
{
@@ -2404,7 +2404,7 @@
return -1;
}
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath)
{
DC_UnlockDc ( dc );
@@ -2471,7 +2471,7 @@
pdcattr = pDc->pdcattr;
- pPath = PATH_LockPath( pDc->DcLevel.hPath );
+ pPath = PATH_LockPath( pDc->dclevel.hPath );
if (!pPath)
{
DC_UnlockDc ( pDc );
@@ -2513,8 +2513,8 @@
}
worker.l = dwNew;
- worker1.f = pDc->DcLevel.laPath.eMiterLimit;
- pDc->DcLevel.laPath.eMiterLimit = worker.f;
+ worker1.f = pDc->dclevel.laPath.eMiterLimit;
+ pDc->dclevel.laPath.eMiterLimit = worker.f;
if (pdwOut)
{
@@ -2558,7 +2558,7 @@
SetLastWin32Error(ERROR_INVALID_PARAMETER);
return FALSE;
}
- pPath = PATH_LockPath( pDc->DcLevel.hPath );
+ pPath = PATH_LockPath( pDc->dclevel.hPath );
if (!pPath)
{
DC_UnlockDc ( pDc );
@@ -2597,7 +2597,7 @@
SetLastWin32Error(ERROR_INVALID_PARAMETER);
return FALSE;
}
- pPath = PATH_LockPath( pDc->DcLevel.hPath );
+ pPath = PATH_LockPath( pDc->dclevel.hPath );
if (!pPath)
{
DC_UnlockDc ( pDc );
@@ -2652,7 +2652,7 @@
pdcattr = dc->pdcattr;
- pPath = PATH_LockPath( dc->DcLevel.hPath );
+ pPath = PATH_LockPath( dc->dclevel.hPath );
if (!pPath)
{
DC_UnlockDc ( dc );
Modified: trunk/reactos/subsystems/win32/win32k/objects/region.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/region.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/region.c [iso-8859-1] Fri Mar 20
17:16:01 2009
@@ -2706,10 +2706,10 @@
{
case CLIPRGN:
hSrc = pDC->rosdc.hClipRgn;
-// if (pDC->DcLevel.prgnClip) hSrc =
((PROSRGNDATA)pDC->DcLevel.prgnClip)->BaseObject.hHmgr;
+// if (pDC->dclevel.prgnClip) hSrc =
((PROSRGNDATA)pDC->dclevel.prgnClip)->BaseObject.hHmgr;
break;
case METARGN:
- if (pDC->DcLevel.prgnMeta) hSrc =
((PROSRGNDATA)pDC->DcLevel.prgnMeta)->BaseObject.hHmgr;
+ if (pDC->dclevel.prgnMeta) hSrc =
((PROSRGNDATA)pDC->dclevel.prgnMeta)->BaseObject.hHmgr;
break;
case APIRGN:
DPRINT1("hMetaRgn not implemented\n");
@@ -2717,8 +2717,8 @@
if (!hSrc) hSrc = pDC->rosdc.hClipRgn;
//if (!hSrc) rgn = dc->hMetaRgn;
// if (pDC->prgnAPI) hSrc =
((PROSRGNDATA)pDC->prgnAPI)->BaseObject.hHmgr;
-// else if (pDC->DcLevel.prgnClip) hSrc =
((PROSRGNDATA)pDC->DcLevel.prgnClip)->BaseObject.hHmgr;
-// else if (pDC->DcLevel.prgnMeta) hSrc =
((PROSRGNDATA)pDC->DcLevel.prgnMeta)->BaseObject.hHmgr;
+// else if (pDC->dclevel.prgnClip) hSrc =
((PROSRGNDATA)pDC->dclevel.prgnClip)->BaseObject.hHmgr;
+// else if (pDC->dclevel.prgnMeta) hSrc =
((PROSRGNDATA)pDC->dclevel.prgnMeta)->BaseObject.hHmgr;
break;
case SYSRGN:
hSrc = pDC->rosdc.hVisRgn;