1*c2c66affSColin Finck /*
2*c2c66affSColin Finck  * The Wine project - Xinput Joystick Library
3*c2c66affSColin Finck  * Copyright 2008 Andrew Fenn
4*c2c66affSColin Finck  *
5*c2c66affSColin Finck  * This library is free software; you can redistribute it and/or
6*c2c66affSColin Finck  * modify it under the terms of the GNU Lesser General Public
7*c2c66affSColin Finck  * License as published by the Free Software Foundation; either
8*c2c66affSColin Finck  * version 2.1 of the License, or (at your option) any later version.
9*c2c66affSColin Finck  *
10*c2c66affSColin Finck  * This library is distributed in the hope that it will be useful,
11*c2c66affSColin Finck  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12*c2c66affSColin Finck  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13*c2c66affSColin Finck  * Lesser General Public License for more details.
14*c2c66affSColin Finck  *
15*c2c66affSColin Finck  * You should have received a copy of the GNU Lesser General Public
16*c2c66affSColin Finck  * License along with this library; if not, write to the Free Software
17*c2c66affSColin Finck  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
18*c2c66affSColin Finck  */
19*c2c66affSColin Finck 
20*c2c66affSColin Finck #include <config.h>
21*c2c66affSColin Finck #include <stdarg.h>
22*c2c66affSColin Finck 
23*c2c66affSColin Finck #include <windef.h>
24*c2c66affSColin Finck #include <winbase.h>
25*c2c66affSColin Finck 
DllMain(HINSTANCE inst,DWORD reason,LPVOID reserved)26*c2c66affSColin Finck BOOL WINAPI DllMain(HINSTANCE inst, DWORD reason, LPVOID reserved)
27*c2c66affSColin Finck {
28*c2c66affSColin Finck     switch(reason)
29*c2c66affSColin Finck     {
30*c2c66affSColin Finck     case DLL_WINE_PREATTACH:
31*c2c66affSColin Finck         return FALSE; /* prefer native version */
32*c2c66affSColin Finck     case DLL_PROCESS_ATTACH:
33*c2c66affSColin Finck         DisableThreadLibraryCalls(inst);
34*c2c66affSColin Finck         break;
35*c2c66affSColin Finck     }
36*c2c66affSColin Finck     return TRUE;
37*c2c66affSColin Finck }
38