hackathon-dev #1
|
@ -1,4 +1,5 @@
|
|||
#include <stdlib.h>
|
||||
#inlcude <string.h>
|
||||
#include "log.h"
|
||||
#include "fbinit.h"
|
||||
#include "devctxt.h"
|
||||
|
@ -160,7 +161,7 @@ static BOOL screen_solid_rect(PVOID privdata, PRECT rect, COLORREF color, INT32
|
|||
PUINT16 ps, p;
|
||||
int y, x;
|
||||
|
||||
ps = loc_from_coords(rect->left, rect->top);
|
||||
ps = loc_from_coords(priv, rect->left, rect->top);
|
||||
for (y = rect->top; y < rect->bottom; y++)
|
||||
{
|
||||
p = ps;
|
||||
|
@ -178,6 +179,7 @@ static PDCTXT screen_create_compat(PVOID privdata)
|
|||
{
|
||||
PSCREENPRIVDATA priv_new;
|
||||
PBITMAP pbmp;
|
||||
PDCTXT rc;
|
||||
|
||||
pbmp = BMP_Create(1, 1, NULL);
|
||||
if (!pbmp)
|
||||
|
@ -204,7 +206,7 @@ static PDCTXT screen_create_compat(PVOID privdata)
|
|||
}
|
||||
else
|
||||
{
|
||||
free(priv);
|
||||
free(priv_new);
|
||||
Go_release(&(pbmp->hdr));
|
||||
}
|
||||
return rc;
|
||||
|
|
|
@ -218,7 +218,7 @@ PGFXOBJECT DC_SelectObject(PDCTXT pdctxt, PGFXOBJECT pobj)
|
|||
pdctxt->baserect.left = pdctxt->baserect.top = 0;
|
||||
pdctxt->baserect.right = ((PBITMAP)pobj)->width;
|
||||
pdctxt->baserect.bottom = ((PBITMAP)pobj)->height;
|
||||
G_intersect_rect(&rtmp, &(pdctxt->baserect), &(pdctxt->cliprect));
|
||||
G_rect_intersect(&rtmp, &(pdctxt->baserect), &(pdctxt->cliprect));
|
||||
memcpy(&(pdctxt->cliprect), &rtmp, sizeof(RECT));
|
||||
return (PGFXOBJECT)rbmp;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user