source: trunk/include/custombuild.h@ 8656

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

SetCustomWndHandleSemName added to override shared semaphore name used to synchronize global window handle array access (to avoid name clash with Odin)

File size: 4.7 KB
RevLine 
[7061]1#ifndef __CUSTOMBUILD_H__
2#define __CUSTOMBUILD_H__
3
[7238]4//HKEY_LOCAL_MACHINE
5#define CUSTOM_BUILD_OPTIONS_KEY "System\\CustomBuild"
6#define DISABLE_AUDIO_KEY "DisableAudio"
[8095]7#define DISABLE_ASPI_KEY "DisableASPI"
[7238]8
[7061]9extern BOOL fCustomBuild;
10
11void InitDirectoriesCustom(char *szSystemDir, char *szWindowsDir);
12
13void DisableOdinIni();
[7078]14void DisableOdinSysMenuItems();
[7061]15
[7246]16
[7763]17typedef HANDLE (* WIN32API PFNDRVOPEN)(LPVOID lpDriverData, DWORD dwAccess, DWORD dwShare, DWORD dwFlags, PVOID *ppHandleData);
18typedef void (* WIN32API PFNDRVCLOSE)(LPVOID lpDriverData, HANDLE hDevice, DWORD dwFlags, PVOID lpHandleData);
19typedef BOOL (* WIN32API PFNDRVIOCTL)(LPVOID lpDriverData, HANDLE hDevice, DWORD dwFlags, DWORD dwIoControlCode,
[7572]20 LPVOID lpInBuffer, DWORD nInBufferSize,
21 LPVOID lpOutBuffer, DWORD nOutBufferSize,
[7756]22 LPDWORD lpBytesReturned, LPOVERLAPPED lpOverlapped,
[7763]23 LPVOID lpHandleData);
[7246]24
[7763]25typedef BOOL (* WIN32API PFNDRVREAD)(LPVOID lpDriverData,
26 HANDLE hDevice,
[7631]27 DWORD dwFlags,
[7572]28 LPCVOID lpBuffer,
29 DWORD nNumberOfBytesToRead,
30 LPDWORD lpNumberOfBytesRead,
31 LPOVERLAPPED lpOverlapped,
[7756]32 LPOVERLAPPED_COMPLETION_ROUTINE lpCompletionRoutine,
[7763]33 LPVOID lpHandleData);
[7572]34
[7763]35typedef BOOL (* WIN32API PFNDRVWRITE)(LPVOID lpDriverData,
36 HANDLE hDevice,
[7631]37 DWORD dwFlags,
[7572]38 LPCVOID lpBuffer,
39 DWORD nNumberOfBytesToWrite,
40 LPDWORD lpNumberOfBytesWrite,
41 LPOVERLAPPED lpOverlapped,
[7756]42 LPOVERLAPPED_COMPLETION_ROUTINE lpCompletionRoutine,
[7763]43 LPVOID lpHandleData);
[7572]44
[7763]45typedef BOOL (* WIN32API PFNDRVCANCELIO)(LPVOID lpDriverData, HANDLE hDevice, DWORD dwFlags, PVOID lpHandleData);
46typedef DWORD (* WIN32API PFNDRVGETOVERLAPPEDRESULT)(LPVOID lpDriverData,
47 HANDLE hDevice,
[7631]48 DWORD dwFlags,
[7629]49 LPOVERLAPPED lpOverlapped,
50 LPDWORD lpcbTransfer,
[7756]51 BOOL fWait,
[7763]52 LPVOID lpHandleData);
[7572]53
[7246]54BOOL WIN32API RegisterCustomDriver(PFNDRVOPEN pfnDriverOpen, PFNDRVCLOSE pfnDriverClose,
[7572]55 PFNDRVIOCTL pfnDriverIOCtl, PFNDRVREAD pfnDriverRead,
[7629]56 PFNDRVWRITE pfnDriverWrite, PFNDRVCANCELIO pfnDriverCancelIo,
57 PFNDRVGETOVERLAPPEDRESULT pfnDriverGetOverlappedResult,
[7763]58 LPCSTR lpDriverName, LPVOID lpDriverData);
[7246]59
[7763]60BOOL WIN32API UnRegisterCustomDriver(LPCSTR lpDriverName);
[7247]61
[7763]62
[7247]63//SetDialogHook can be used by a custom Odin build to register a hook procedure
64//that gets called before or after dialog creation
65
[8132]66#define HODIN_PREDIALOGCREATION 0
67#define HODIN_POSTDIALOGCREATION 1
68#define HODIN_WINDOWCREATED 2
[7247]69
[8132]70HHOOK WIN32API SetOdinHookA(HOOKPROC proc );
71BOOL WIN32API UnhookOdinHook(HHOOK hhook);
72LRESULT HOOK_CallOdinHookA(INT code, WPARAM wParam, LPARAM lParam );
[7247]73
[8112]74//Override LoadImage function
75typedef void (* WIN32API PFNLOADIMAGEW)(HINSTANCE *phinst, LPWSTR *lplpszName, UINT *lpuType);
[7251]76
[8112]77BOOL WIN32API SetCustomLoadImage(PFNLOADIMAGEW pfnLoadImageW);
[8012]78
[7251]79//Set the default language in kernel32
80void WIN32API SetDefaultLanguage(DWORD deflang);
81
[7621]82//Override pm keyboard hook dll name
83void WIN32API SetCustomPMHookDll(LPSTR pszKbdDllName);
[7251]84
[7674]85//Turn off wave audio in winmm
86void WIN32API DisableWaveAudio();
87
[8656]88//Override shared semaphore name used to synchronize global window handle
89//array access (to avoid name clash with Odin)
90void WIN32API SetCustomWndHandleSemName(LPSTR pszSemName);
91
[8095]92//Turn off ASPI
93void WIN32API DisableASPI();
94
[7943]95//force color to mono cursor conversion
96void WIN32API CustForceMonoCursor();
97
[8408]98//force GetVolumeInformation to tell the app all partitions are FAT
99void WIN32API CustForce2GBFileSize();
100
[7061]101#endif /*__CUSTOMBUILD_H__*/
102
Note: See TracBrowser for help on using the repository browser.