ReactOS  r76032
cardlib.h File Reference
#include <stdarg.h>
#include <stdlib.h>
#include <windef.h>
#include <winbase.h>
#include <wingdi.h>
#include <winuser.h>
#include "globals.h"
#include "card.h"
#include "cardbutton.h"
#include "cardcolor.h"
#include "cardstack.h"
#include "cardregion.h"
#include "dropzone.h"
#include "cardwindow.h"
Include dependency graph for cardlib.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define WIN32_NO_STATUS
 
#define CARDLIBPROC   __stdcall
 
#define CS_EI_NONE   0
 
#define CS_EI_SUNK   1
 
#define CS_EI_CIRC   67
 
#define CS_EI_X   66
 
#define CS_DEFXOFF   12
 
#define CS_DEFYOFF   18
 
#define CS_NO3D   1
 
#define CS_DEF3D   10
 
#define CS_DRAG_NONE   0
 
#define CS_DRAG_TOP   1
 
#define CS_DRAG_ALL   2
 
#define CS_DRAG_CALLBACK   3
 
#define CS_DROP_NONE   0
 
#define CS_DROP_ALL   1
 
#define CS_DROP_CALLBACK   2
 
#define CS_XJUST_NONE   0
 
#define CS_XJUST_RIGHT   1
 
#define CS_XJUST_CENTER   2
 
#define CS_YJUST_NONE   0
 
#define CS_YJUST_BOTTOM   1
 
#define CS_YJUST_CENTER   2
 
#define CB_STATIC   0
 
#define CB_PUSHBUTTON   1
 
#define CB_ALIGN_CENTER   0
 
#define CB_ALIGN_LEFT   2
 
#define CB_ALIGN_RIGHT   4
 
#define CS_FACE_UP   0
 
#define CS_FACE_DOWN   1
 
#define CS_FACE_DOWNUP   2
 
#define CS_FACE_UPDOWN   3
 
#define CS_FACE_ANY   4
 
#define CS_DROPZONE_NODROP   -1
 
#define ecbCROSSHATCH   53
 
#define ecbWEAVE1   54
 
#define ecbWEAVE2   55
 
#define ecbROBOT   56
 
#define ecbFLOWERS   57
 
#define ecbVINE1   58
 
#define ecbVINE2   59
 
#define ecbFISH1   60
 
#define ecbFISH2   61
 
#define ecbSHELLS   62
 
#define ecbCASTLE   63
 
#define ecbISLAND   64
 
#define ecbCARDHAND   65
 
#define ecbUNUSED   66
 
#define ecbTHE_X   67
 
#define ecbTHE_O   68
 

Typedefs

typedef int iNumDragging
 
typedef CardStackcards
 
typedef int iNumCards
 
typedef int iNumRemoved
 
typedef int height
 

Functions

void CardBlt (HDC hdc, int x, int y, int nCardNum)
 
void CardLib_SetZoomSpeed (int)
 
typedef bool (CARDLIBPROC *pCanDragProc)(CardRegion &stackobj
 
typedef void (CARDLIBPROC *pClickProc)(CardRegion &stackobj
 
typedef int (CARDLIBPROC *pDropZoneProc)(int dzid
 

Macro Definition Documentation

#define CARDLIBPROC   __stdcall

Definition at line 13 of file cardlib.h.

#define CB_ALIGN_CENTER   0

Definition at line 47 of file cardlib.h.

#define CB_ALIGN_LEFT   2

Definition at line 48 of file cardlib.h.

Referenced by CardButton::Draw().

#define CB_ALIGN_RIGHT   4

Definition at line 49 of file cardlib.h.

Referenced by CardButton::Draw().

#define CB_STATIC   0

Definition at line 45 of file cardlib.h.

#define CS_DEF3D   10

Definition at line 26 of file cardlib.h.

#define CS_DEFXOFF   12

Definition at line 23 of file cardlib.h.

Referenced by CreateSol(), and DeckClickProc().

#define CS_DEFYOFF   18

Definition at line 24 of file cardlib.h.

#define CS_DRAG_ALL   2
#define CS_DRAG_CALLBACK   3
#define CS_DRAG_NONE   0
#define CS_DRAG_TOP   1

Definition at line 29 of file cardlib.h.

Referenced by CardRegion::CanDragCards(), CreateSol(), and CardRegion::SetDragRule().

#define CS_DROP_ALL   1
#define CS_DROP_CALLBACK   2
#define CS_DROP_NONE   0
#define CS_DROPZONE_NODROP   -1

Definition at line 57 of file cardlib.h.

Referenced by CardRegion::OnLButtonUp().

#define CS_FACE_ANY   4
#define CS_FACE_DOWN   1
#define CS_FACE_UP   0
#define CS_FACE_UPDOWN   3

Definition at line 54 of file cardlib.h.

Referenced by CardRegion::SetFaceDirection(), and CardRegion::UpdateFaceDir().

#define CS_NO3D   1

Definition at line 25 of file cardlib.h.

#define CS_XJUST_NONE   0
#define CS_XJUST_RIGHT   1
#define CS_YJUST_BOTTOM   1

Definition at line 42 of file cardlib.h.

Referenced by CardButton::AdjustPosition(), CardRegion::AdjustPosition(), and CreateSpider().

#define CS_YJUST_CENTER   2

Definition at line 43 of file cardlib.h.

Referenced by CardButton::AdjustPosition(), and CardRegion::AdjustPosition().

#define CS_YJUST_NONE   0

Definition at line 41 of file cardlib.h.

Referenced by CardButton::AdjustPosition(), and CardRegion::AdjustPosition().

#define ecbCARDHAND   65

Definition at line 74 of file cardlib.h.

#define ecbCASTLE   63

Definition at line 72 of file cardlib.h.

#define ecbCROSSHATCH   53

Definition at line 62 of file cardlib.h.

#define ecbFISH1   60

Definition at line 69 of file cardlib.h.

#define ecbFISH2   61

Definition at line 70 of file cardlib.h.

#define ecbFLOWERS   57

Definition at line 66 of file cardlib.h.

#define ecbISLAND   64

Definition at line 73 of file cardlib.h.

#define ecbROBOT   56

Definition at line 65 of file cardlib.h.

#define ecbSHELLS   62

Definition at line 71 of file cardlib.h.

#define ecbTHE_O   68

Definition at line 77 of file cardlib.h.

#define ecbTHE_X   67

Definition at line 76 of file cardlib.h.

#define ecbUNUSED   66

Definition at line 75 of file cardlib.h.

#define ecbVINE1   58

Definition at line 67 of file cardlib.h.

#define ecbVINE2   59

Definition at line 68 of file cardlib.h.

#define ecbWEAVE1   54

Definition at line 63 of file cardlib.h.

#define ecbWEAVE2   55

Definition at line 64 of file cardlib.h.

#define WIN32_NO_STATUS

Definition at line 7 of file cardlib.h.

Typedef Documentation

typedef const CardStack & cards

Definition at line 86 of file cardlib.h.

typedef int height

Definition at line 91 of file cardlib.h.

typedef int iNumCards

Definition at line 87 of file cardlib.h.

typedef int iNumDragging

Definition at line 85 of file cardlib.h.

typedef int iNumRemoved

Definition at line 89 of file cardlib.h.

Function Documentation

void CardBlt ( HDC  hdc,
int  x,
int  y,
int  nCardNum 
)

Definition at line 22 of file cardrgndraw.cpp.

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

23 {
24  int sx = nCardNum * __cardwidth;
25  int sy = 0;
26  int width = __cardwidth;
27  int height = __cardheight;
28 
29  //draw main center band
30  BitBlt(hdc, x+2, y, width - 4, height, __hdcCardBitmaps, sx+2, sy+0, SRCCOPY);
31 
32  //draw the two bits to the left
33  BitBlt(hdc, x, y+2, 1, height - 4, __hdcCardBitmaps, sx+0, sy+2, SRCCOPY);
34  BitBlt(hdc, x+1, y+1, 1, height - 2, __hdcCardBitmaps, sx+1, sy+1, SRCCOPY);
35 
36  //draw the two bits to the right
37  BitBlt(hdc, x+width-2, y+1, 1, height - 2, __hdcCardBitmaps, sx+width-2, sy+1, SRCCOPY);
38  BitBlt(hdc, x+width-1, y+2, 1, height - 4, __hdcCardBitmaps, sx+width-1, sy+2, SRCCOPY);
39 }
static VOID NTAPI BitBlt(IN ULONG Left, IN ULONG Top, IN ULONG Width, IN ULONG Height, IN PUCHAR Buffer, IN ULONG BitsPerPixel, IN ULONG Delta)
Definition: vga.c:416
HDC __hdcCardBitmaps
Definition: cardlib.cpp:18
HDC hdc
Definition: msvc.h:53
GLint GLint GLsizei width
Definition: gl.h:1546
int __cardwidth
Definition: cardlib.cpp:25
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
int __cardheight
Definition: cardlib.cpp:26
INT INT y
Definition: msvc.h:62
#define SRCCOPY
Definition: wingdi.h:331
INT x
Definition: msvc.h:62
void CardLib_SetZoomSpeed ( int  )

Definition at line 34 of file cardlib.cpp.

35 {
36  __CARDZOOMSPEED = (double)speed;
37 }
double __CARDZOOMSPEED
static const char mbstate_t *static wchar_t const char mbstate_t *static const wchar_t int *static double
Definition: string.c:79
typedef int ( CARDLIBPROC pDropZoneProc)
typedef void ( CARDLIBPROC pClickProc)