wine/dlls/winmm/wineoss/oss.c

82 lines
2.3 KiB
C
Raw Normal View History

/* -*- tab-width: 8; c-basic-offset: 4 -*- */
2002-05-31 23:06:46 +00:00
/*
* Wine Driver for Open Sound System
*
* Copyright 1999 Eric Pouech
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#include "config.h"
#include <stdarg.h>
#include "windef.h"
#include "winbase.h"
#include "wingdi.h"
#include "winuser.h"
#include "mmddk.h"
#include "oss.h"
#ifdef HAVE_OSS
/**************************************************************************
2002-05-31 23:06:46 +00:00
* OSS_drvOpen [internal]
*/
static LRESULT OSS_drvOpen(LPSTR str)
{
return 1;
}
/**************************************************************************
2002-05-31 23:06:46 +00:00
* OSS_drvClose [internal]
*/
static LRESULT OSS_drvClose(DWORD_PTR dwDevID)
{
return 1;
}
#endif
/**************************************************************************
2001-07-11 18:56:41 +00:00
* DriverProc (WINEOSS.1)
*/
LRESULT CALLBACK OSS_DriverProc(DWORD_PTR dwDevID, HDRVR hDriv, UINT wMsg,
LPARAM dwParam1, LPARAM dwParam2)
{
/* EPP TRACE("(%08lX, %04X, %08lX, %08lX, %08lX)\n", */
/* EPP dwDevID, hDriv, wMsg, dwParam1, dwParam2); */
2002-05-31 23:06:46 +00:00
switch(wMsg) {
#ifdef HAVE_OSS
2002-05-31 23:06:46 +00:00
case DRV_LOAD: OSS_WaveInit();
OSS_MidiInit();
return 1;
case DRV_FREE: return 1;
case DRV_OPEN: return OSS_drvOpen((LPSTR)dwParam1);
case DRV_CLOSE: return OSS_drvClose(dwDevID);
case DRV_ENABLE: return 1;
case DRV_DISABLE: return 1;
case DRV_QUERYCONFIGURE: return 1;
case DRV_CONFIGURE: MessageBoxA(0, "OSS MultiMedia Driver !", "OSS Driver", MB_OK); return 1;
case DRV_INSTALL: return DRVCNF_RESTART;
case DRV_REMOVE: return DRVCNF_RESTART;
#endif
default:
return DefDriverProc(dwDevID, hDriv, wMsg, dwParam1, dwParam2);
}
}