mirror of
https://github.com/reactos/reactos.git
synced 2025-07-31 12:02:02 +00:00
Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys.
This commit is contained in:
parent
b94e2d8ca0
commit
c2c66aff7d
24198 changed files with 0 additions and 37285 deletions
39
sdk/lib/3rdparty/cardlib/dropzone.h
vendored
Normal file
39
sdk/lib/3rdparty/cardlib/dropzone.h
vendored
Normal file
|
@ -0,0 +1,39 @@
|
|||
#ifndef DROPZONE_INCLUDED
|
||||
#define DROPZONE_INCLUDED
|
||||
|
||||
//
|
||||
// define a drop-zone, which can be used to over-ride
|
||||
// drop-behaviour for any card stacks which fall under it
|
||||
//
|
||||
|
||||
class CardStack;
|
||||
|
||||
class DropZone
|
||||
{
|
||||
friend class CardWindow;
|
||||
|
||||
DropZone(int Id, RECT *rect, pDropZoneProc proc) :
|
||||
id(Id), DropZoneCallback(proc) { CopyRect(&zone, rect); }
|
||||
|
||||
public:
|
||||
|
||||
void SetZone(RECT *rect) { CopyRect(&zone, rect); }
|
||||
void GetZone(RECT *rect) { CopyRect(rect, &zone); }
|
||||
void SetCallback(pDropZoneProc callback) { DropZoneCallback = callback; }
|
||||
|
||||
int DropCards(CardStack &cardstack)
|
||||
{
|
||||
if(DropZoneCallback)
|
||||
return DropZoneCallback(id, cardstack);
|
||||
else
|
||||
return -1;
|
||||
}
|
||||
|
||||
private:
|
||||
|
||||
int id;
|
||||
RECT zone;
|
||||
pDropZoneProc DropZoneCallback;
|
||||
};
|
||||
|
||||
#endif /* DROPZONE_INCLUDED */
|
Loading…
Add table
Add a link
Reference in a new issue