Make sure that all calls use the extended structures which are a
[wine.git] / multimedia / oss.c
blob1e7c421309b58c6e38f63dc9c168c8e5b05988a0
1 /* -*- tab-width: 8; c-basic-offset: 4 -*- */
2 /*
3 * Wine Driver for Open Sound System
5 * Copyright 1999 Eric Pouech
6 */
8 #include "winuser.h"
9 #include "driver.h"
10 #include "mmddk.h"
11 #include "oss.h"
13 static struct WINE_OSS* oss = NULL;
15 /**************************************************************************
16 * OSS_drvOpen [internal]
18 static DWORD OSS_drvOpen(LPSTR str)
20 if (oss)
21 return 0;
23 /* I know, this is ugly, but who cares... */
24 oss = (struct WINE_OSS*)1;
25 return 1;
28 /**************************************************************************
29 * OSS_drvClose [internal]
31 static DWORD OSS_drvClose(DWORD dwDevID)
33 if (oss) {
34 oss = NULL;
35 return 1;
37 return 0;
40 /**************************************************************************
41 * OSS_DriverProc [internal]
43 LONG CALLBACK OSS_DriverProc(DWORD dwDevID, HDRVR hDriv, DWORD wMsg,
44 DWORD dwParam1, DWORD dwParam2)
46 /* EPP TRACE("(%08lX, %04X, %08lX, %08lX, %08lX)\n", */
47 /* EPP dwDevID, hDriv, wMsg, dwParam1, dwParam2); */
49 switch(wMsg) {
50 case DRV_LOAD: return 1;
51 case DRV_FREE: return 1;
52 case DRV_OPEN: return OSS_drvOpen((LPSTR)dwParam1);
53 case DRV_CLOSE: return OSS_drvClose(dwDevID);
54 case DRV_ENABLE: return 1;
55 case DRV_DISABLE: return 1;
56 case DRV_QUERYCONFIGURE: return 1;
57 case DRV_CONFIGURE: MessageBoxA(0, "OSS MultiMedia Driver !", "OSS Driver", MB_OK); return 1;
58 case DRV_INSTALL: return DRVCNF_RESTART;
59 case DRV_REMOVE: return DRVCNF_RESTART;
60 default:
61 return DefDriverProc(dwDevID, hDriv, wMsg, dwParam1, dwParam2);