ReactOS 0.4.15-dev-8219-ge8b88cf
cardrgnmouse.cpp File Reference
#include "cardlib.h"
#include <math.h>
Include dependency graph for cardrgnmouse.cpp:

Go to the source code of this file.

Macros

#define TRACE(s)
 

Functions

int ClipCard (HDC hdc, int x, int y, int width, int height)
 
void DrawCard (HDC hdc, int x, int y, HDC hdcSource, int width, int height)
 
BOOL ClippedBitBlt (HDC hdcDest, int x, int y, int width, int height, HDC hdcSrc, int srcx, int srcy, DWORD dwROP)
 

Variables

double __CARDZOOMSPEED = 32
 

Macro Definition Documentation

◆ TRACE

#define TRACE (   s)

Definition at line 13 of file cardrgnmouse.cpp.

Function Documentation

◆ ClipCard()

int ClipCard ( HDC  hdc,
int  x,
int  y,
int  width,
int  height 
)

Definition at line 198 of file cardrgndraw.cpp.

199{
200 ExcludeClipRect(hdc, x+2, y, x+2+width-4, y+ height);
201 ExcludeClipRect(hdc, x, y+2, x+1, y+2+height-4);
202 ExcludeClipRect(hdc, x+1, y+1, x+2, y+1+height-2);
203 ExcludeClipRect(hdc, x+width-2, y+1, x+width-2+1, y+1+height-2);
204 ExcludeClipRect(hdc, x+width-1, y+2, x+width-1+1, y+2+height-4);
205 return 0;
206}
GLint GLint GLint GLint GLint x
Definition: gl.h:1548
GLint GLint GLint GLint GLint GLint y
Definition: gl.h:1548
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
GLint GLint GLsizei width
Definition: gl.h:1546
HDC hdc
Definition: main.c:9
int WINAPI ExcludeClipRect(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int)

Referenced by CardRegion::Clip(), and CardRegion::MoveDragCardTo().

◆ ClippedBitBlt()

BOOL ClippedBitBlt ( HDC  hdcDest,
int  x,
int  y,
int  width,
int  height,
HDC  hdcSrc,
int  srcx,
int  srcy,
DWORD  dwROP 
)

Definition at line 405 of file cardrgnmouse.cpp.

406{
407 if(srcx < 0)
408 {
409 x = 0 - srcx;
410 width = width + srcx;
411 srcx = 0;
412 }
413
414 if(srcy < 0)
415 {
416 y = 0 - srcy;
417 height = height + srcy;
418 srcy = 0;
419 }
420
421 return BitBlt(hdcDest, x, y, width, height, hdcSrc, srcx, srcy, dwROP);
422}
static VOID BitBlt(_In_ ULONG Left, _In_ ULONG Top, _In_ ULONG Width, _In_ ULONG Height, _In_reads_bytes_(Delta *Height) PUCHAR Buffer, _In_ ULONG BitsPerPixel, _In_ ULONG Delta)
Definition: common.c:57
static HDC hdcSrc
Definition: xlate.c:32

Referenced by CardRegion::MoveDragCardTo().

◆ DrawCard()

void DrawCard ( HDC  hdc,
int  x,
int  y,
HDC  hdcSource,
int  width,
int  height 
)

Definition at line 180 of file cardrgndraw.cpp.

181{
182 //draw main center band
183 BitBlt(hdc, x+2, y, width - 4, height, hdcDragCard, 2, 0, SRCCOPY);
184
185 //draw the two bits to the left
186 BitBlt(hdc, x, y+2, 1, height - 4, hdcDragCard, 0, 2, SRCCOPY);
187 BitBlt(hdc, x+1, y+1, 1, height - 2, hdcDragCard, 1, 1, SRCCOPY);
188
189 //draw the two bits to the right
190 BitBlt(hdc, x+width-2, y+1, 1, height - 2, hdcDragCard, width-2, 1, SRCCOPY);
191 BitBlt(hdc, x+width-1, y+2, 1, height - 4, hdcDragCard, width-1, 2, SRCCOPY);
192}
#define SRCCOPY
Definition: wingdi.h:333

Referenced by CardRegion::MoveDragCardTo(), CardRegion::PrepareDragBitmaps(), CardRegion::PrepareDragBitmapsThreed(), and CardRegion::Render().

Variable Documentation

◆ __CARDZOOMSPEED

double __CARDZOOMSPEED = 32

Definition at line 18 of file cardrgnmouse.cpp.

Referenced by CardLib_SetZoomSpeed(), and CardRegion::ZoomCard().