source: trunk/src/gdi32/CALLBACK.CPP@ 4552

Last change on this file since 4552 was 4552, checked in by sandervl, 25 years ago

OffsetRgn fix + small changes

File size: 1.9 KB
Line 
1/* $Id: CALLBACK.CPP,v 1.6 2000-11-04 16:29:23 sandervl Exp $ */
2
3/*
4 * GDI32 support code for Line DDA callbacks
5 *
6 * Copyright 1998 Sander van Leeuwen (sandervl@xs4all.nl)
7 *
8 * Project Odin Software License can be found in LICENSE.TXT
9 *
10 */
11#include <os2win.h>
12#include <stdarg.h>
13#include "misc.h"
14#include "callback.h"
15#include <wprocess.h>
16
17#define DBG_LOCALLOG DBG_callback
18#include "dbglocal.h"
19
20#ifndef STDCALL_ENUMPROCS
21
22static VOID OPEN32API Callback(int X, int Y, LPARAM lpData);
23
24//******************************************************************************
25//******************************************************************************
26LineDDAProcCallback::LineDDAProcCallback(LINEDDAPROC pUserCallback, LPARAM lpData)
27{
28 lpUserData = lpData;
29 pCallback = (LINEDDAPROC)pUserCallback;
30}
31//******************************************************************************
32//******************************************************************************
33LineDDAProcCallback::~LineDDAProcCallback()
34{
35
36}
37//******************************************************************************
38//******************************************************************************
39LINEDDAPROC_O32 LineDDAProcCallback::GetOS2Callback()
40{
41 return Callback;
42}
43//******************************************************************************
44//******************************************************************************
45static VOID OPEN32API Callback(int X, int Y, LPARAM lpData)
46{
47 LineDDAProcCallback *me = (LineDDAProcCallback *)lpData;
48 USHORT selTIB = SetWin32TIB(); // save current FS selector and set win32 sel
49
50 me->pCallback(X, Y, me->lpUserData);
51 SetFS(selTIB); // switch back to the saved FS selector
52 return;
53}
54//******************************************************************************
55//******************************************************************************
56
57#endif //#ifndef STDCALL_ENUMPROCS
Note: See TracBrowser for help on using the repository browser.