source: trunk/src/ddraw/clipper.h@ 10367

Last change on this file since 10367 was 9560, checked in by sandervl, 23 years ago

Cleanup

File size: 2.6 KB
Line 
1/* $Id: clipper.h,v 1.2 2002-12-29 14:11:00 sandervl Exp $ */
2
3/*
4 * DX clipper class definition
5 *
6 * Copyright 1998 Sander va Leeuwen
7 *
8 * Project Odin Software License can be found in LICENSE.TXT
9 *
10 */
11#ifndef __OS2CLIPPER_H__
12#define __OS2CLIPPER_H__
13
14#include "divewrap.h"
15
16#define FAR
17#undef THIS
18#define THIS IDirectDrawClipper*
19class OS2IDirectDrawClipper
20{
21 public:
22 //this one has to go first!
23 IDirectDrawClipperVtbl *lpVtbl;
24 IDirectDrawClipperVtbl Vtbl;
25
26 OS2IDirectDrawClipper(OS2IDirectDraw *lpDirectDraw);
27 OS2IDirectDrawClipper(void);
28 ~OS2IDirectDrawClipper();
29
30 int Referenced;
31 inline HRESULT GetLastError() { return lastError; };
32
33 BOOL IsClipListChangedInt()
34 {
35 BOOL ret = fClipListChangedInt;
36 fClipListChangedInt = FALSE;
37 return ret;
38 }
39 private:
40
41 protected:
42 HRESULT lastError;
43 OS2IDirectDraw *lpDraw;
44 HDIVE hDive;
45 HWND clipWindow;
46
47 LPRGNDATA lpRgnData;
48 BOOL fClipListChanged, fClipListChangedInt;
49 BOOL fDrawingAllowed;
50
51 // Linked list management
52 OS2IDirectDrawClipper* next; // Next OS2IDirectDraw
53 static OS2IDirectDrawClipper* ddraw; // List of OS2IDirectDraw
54
55 friend HRESULT WIN32API ClipQueryInterface(THIS, REFIID riid, LPVOID FAR * ppvObj);
56 friend ULONG WIN32API ClipAddRef(THIS);
57 friend ULONG WIN32API ClipRelease(THIS);
58 friend HRESULT WIN32API ClipGetClipList(THIS, LPRECT, LPRGNDATA, LPDWORD);
59 friend HRESULT WIN32API ClipGetHWnd(THIS, HWND FAR *);
60 friend HRESULT WIN32API ClipInitialize(THIS, LPDIRECTDRAW, DWORD);
61 friend HRESULT WIN32API ClipIsClipListChanged(THIS, BOOL FAR *);
62 friend HRESULT WIN32API ClipSetClipList(THIS, LPRGNDATA,DWORD);
63 friend HRESULT WIN32API ClipSetHWnd(THIS, DWORD, HWND );
64 friend BOOL WIN32API ClipVisRgnCallback(HWND hwnd, BOOL fDrawingAllowed, DWORD dwUserData);
65
66};
67
68HRESULT WIN32API ClipQueryInterface(THIS, REFIID riid, LPVOID FAR * ppvObj);
69ULONG WIN32API ClipAddRef(THIS);
70ULONG WIN32API ClipRelease(THIS);
71HRESULT WIN32API ClipGetClipList(THIS, LPRECT, LPRGNDATA, LPDWORD);
72HRESULT WIN32API ClipGetHWnd(THIS, HWND FAR *);
73HRESULT WIN32API ClipInitialize(THIS, LPDIRECTDRAW, DWORD);
74HRESULT WIN32API ClipIsClipListChanged(THIS, BOOL FAR *);
75HRESULT WIN32API ClipSetClipList(THIS, LPRGNDATA,DWORD);
76HRESULT WIN32API ClipSetHWnd(THIS, DWORD, HWND );
77
78#endif
Note: See TracBrowser for help on using the repository browser.