From 064f170f763135d459c18c52d6e491a586d9e9c3 Mon Sep 17 00:00:00 2001 From: Marcus Meissner Date: Sun, 28 Feb 1999 19:14:33 +0000 Subject: [PATCH] More include optimisations and fixes. --- controls/menu.c | 3 --- dlls/shell32/dataobject.c | 6 +----- dlls/shell32/shlfolder.c | 2 -- include/oleobj.h | 2 -- include/shlobj.h | 2 ++ include/wine/obj_channel.h | 3 +-- include/wine/obj_clientserver.h | 3 +-- include/wine/obj_control.h | 3 +++ include/wine/obj_dataobject.h | 3 +++ include/wine/obj_dragdrop.h | 4 ++-- include/wine/obj_inplace.h | 1 + include/wine/obj_marshal.h | 4 ++-- include/wine/obj_misc.h | 3 +-- include/wine/obj_moniker.h | 8 +++----- include/wine/obj_oleaut.h | 5 +---- include/wine/obj_olefont.h | 4 ++-- include/wine/obj_propertystorage.h | 4 ++-- include/wine/obj_storage.h | 6 ++---- include/wine/winuser16.h | 1 + library/winestub.c | 2 +- memory/string.c | 5 +++-- misc/sound.c | 1 + multimedia/mmsystem.c | 2 -- ole/bindctx.c | 2 -- ole/filemoniker.c | 4 +--- ole/ifs.c | 1 - ole/itemmoniker.c | 2 -- ole/moniker.c | 2 -- ole/ole2.c | 9 ++------- ole/ole2disp.c | 4 ---- ole/ole2nls.c | 1 - ole/olecli.c | 4 +--- ole/oledlg.c | 2 +- ole/olefont.c | 1 - ole/oleobj.c | 5 ++--- ole/olesvr.c | 1 - ole/safearray.c | 13 ++++++------- ole/stg_bigblockfile.c | 5 +---- ole/stg_stream.c | 5 +---- ole/storage.c | 1 - ole/storage32.c | 12 +++--------- ole/typelib.c | 7 +++---- ole/variant.c | 1 - tools/fnt2bdf.c | 2 +- windows/display.c | 2 +- 45 files changed, 56 insertions(+), 107 deletions(-) diff --git a/controls/menu.c b/controls/menu.c index d6f36bfb253..4754eff6636 100644 --- a/controls/menu.c +++ b/controls/menu.c @@ -17,7 +17,6 @@ #include #include -#include "bitmap.h" #include "win.h" #include "wine/winbase16.h" #include "wine/winuser16.h" @@ -25,8 +24,6 @@ #include "task.h" #include "heap.h" #include "menu.h" -#include "module.h" -#include "neexe.h" #include "nonclient.h" #include "user.h" #include "message.h" diff --git a/dlls/shell32/dataobject.c b/dlls/shell32/dataobject.c index fb9201e420d..1e7bd651919 100644 --- a/dlls/shell32/dataobject.c +++ b/dlls/shell32/dataobject.c @@ -7,15 +7,11 @@ */ #include -#include "debug.h" -#include "wintypes.h" -#include "wine/obj_base.h" -#include "wine/obj_storage.h" -#include "wine/obj_moniker.h" #include "wine/obj_dataobject.h" #include "pidl.h" #include "winerror.h" #include "shell32_main.h" +#include "debug.h" UINT cfShellIDList=0; UINT cfFileGroupDesc=0; diff --git a/dlls/shell32/shlfolder.c b/dlls/shell32/shlfolder.c index fd9d6bd60ed..12bf21f4db7 100644 --- a/dlls/shell32/shlfolder.c +++ b/dlls/shell32/shlfolder.c @@ -12,13 +12,11 @@ #include "debug.h" #include "winerror.h" -#include "objbase.h" #include "wine/obj_base.h" #include "wine/obj_dragdrop.h" #include "shlguid.h" #include "pidl.h" -#include "objbase.h" #include "shlobj.h" #include "shell32_main.h" diff --git a/include/oleobj.h b/include/oleobj.h index d846d97ac2c..0f3e9d437b2 100644 --- a/include/oleobj.h +++ b/include/oleobj.h @@ -1,8 +1,6 @@ #ifndef _WINE_OLEOBJ_H #define _WINE_OLEOBJ_H -#include "ole.h" -#include "ole2.h" #include "wine/obj_base.h" #include "wine/obj_storage.h" #include "wine/obj_moniker.h" diff --git a/include/shlobj.h b/include/shlobj.h index 1b8262a8537..5d82bc3f83b 100644 --- a/include/shlobj.h +++ b/include/shlobj.h @@ -2,8 +2,10 @@ #define __WINE_SHLOBJ_H #include "wintypes.h" +#include "winbase.h" /* WIN32_FIND_* */ #include "wine/obj_base.h" #include "wine/obj_shelllink.h" +#include "ole2.h" #include "shell.h" #include "oleobj.h" #include "commctrl.h" diff --git a/include/wine/obj_channel.h b/include/wine/obj_channel.h index da0c9ff3576..1f9cf4812ab 100644 --- a/include/wine/obj_channel.h +++ b/include/wine/obj_channel.h @@ -1,12 +1,11 @@ /* * Defines undocumented Microsoft COM interfaces and APIs seemingly related to some 'channel' notion. - * - * Depends on 'obj_base.h'. */ #ifndef __WINE_WINE_OBJ_CHANNEL_H #define __WINE_WINE_OBJ_CHANNEL_H +#include "wine/obj_base.h" /***************************************************************************** * Predeclare the interfaces diff --git a/include/wine/obj_clientserver.h b/include/wine/obj_clientserver.h index bafa86596ba..dd0fb6c4ed3 100644 --- a/include/wine/obj_clientserver.h +++ b/include/wine/obj_clientserver.h @@ -1,12 +1,11 @@ /* * Defines the COM interfaces and APIs related to client/server aspects. - * - * Depends on 'obj_base.h'. */ #ifndef __WINE_WINE_OBJ_CLIENTSERVER_H #define __WINE_WINE_OBJ_CLIENTSERVER_H +#include "wine/obj_base.h" /***************************************************************************** * Predeclare the interfaces diff --git a/include/wine/obj_control.h b/include/wine/obj_control.h index a1c4864fda9..7fb380f02d6 100644 --- a/include/wine/obj_control.h +++ b/include/wine/obj_control.h @@ -9,6 +9,9 @@ #include "winbase.h" +#include "winuser.h" +#include "wine/obj_inplace.h" +#include "wine/obj_dragdrop.h" /***************************************************************************** diff --git a/include/wine/obj_dataobject.h b/include/wine/obj_dataobject.h index 78f4823bca0..136deee6582 100644 --- a/include/wine/obj_dataobject.h +++ b/include/wine/obj_dataobject.h @@ -7,6 +7,9 @@ #ifndef __WINE_WINE_OBJ_DATAOBJECT_H #define __WINE_WINE_OBJ_DATAOBJECT_H +#include "wine/obj_base.h" +#include "wine/obj_storage.h" +#include "wine/obj_moniker.h" /***************************************************************************** * Predeclare the structures diff --git a/include/wine/obj_dragdrop.h b/include/wine/obj_dragdrop.h index b5736fac1c5..719275066fb 100644 --- a/include/wine/obj_dragdrop.h +++ b/include/wine/obj_dragdrop.h @@ -1,7 +1,5 @@ /* * Defines the COM interfaces and APIs related to OLE Drag and Drop. - * - * Depends on 'obj_base.h'. */ #ifndef __WINE_WINE_OBJ_DRAGDROP_H @@ -9,6 +7,8 @@ #include "winnt.h" #include "windef.h" +#include "wine/obj_base.h" +#include "wine/obj_dataobject.h" /***************************************************************************** * Predeclare the interfaces diff --git a/include/wine/obj_inplace.h b/include/wine/obj_inplace.h index 8e29c91be6d..d4d47349e89 100644 --- a/include/wine/obj_inplace.h +++ b/include/wine/obj_inplace.h @@ -10,6 +10,7 @@ #include "winbase.h" #include "winuser.h" +#include "wine/obj_moniker.h" /***************************************************************************** * Predeclare the structures diff --git a/include/wine/obj_marshal.h b/include/wine/obj_marshal.h index 5054cb6390e..b7422f7d91b 100644 --- a/include/wine/obj_marshal.h +++ b/include/wine/obj_marshal.h @@ -1,13 +1,13 @@ /* * Defines the COM interfaces and APIs that allow an interface to * specify a custom marshaling for its objects. - * - * Depends on 'obj_storage.h' and 'obj_base.h'. */ #ifndef __WINE_WINE_OBJ_MARSHAL_H #define __WINE_WINE_OBJ_MARSHAL_H +#include "wine/obj_base.h" +#include "wine/obj_storage.h" /***************************************************************************** * Predeclare the interfaces diff --git a/include/wine/obj_misc.h b/include/wine/obj_misc.h index 8472c84e53a..c0f716482b7 100644 --- a/include/wine/obj_misc.h +++ b/include/wine/obj_misc.h @@ -3,13 +3,12 @@ * These did not really fit into the other categories, whould have * required their own specific category or are too rarely used to be * put in 'obj_base.h'. - * - * Depends on 'obj_base.h'. */ #ifndef __WINE_WINE_OBJ_MISC_H #define __WINE_WINE_OBJ_MISC_H +#include "wine/obj_base.h" /***************************************************************************** * Predeclare the interfaces diff --git a/include/wine/obj_moniker.h b/include/wine/obj_moniker.h index 58c3f13ffb6..8e84c0969c0 100644 --- a/include/wine/obj_moniker.h +++ b/include/wine/obj_moniker.h @@ -1,15 +1,13 @@ /* * Defines the COM interfaces and APIs related to the moniker functionality. - * - * This file depends on 'obj_storage.h' and 'obj_base.h' and 'obj_misc.h' (IEnumString). */ - - - #ifndef __WINE_WINE_OBJ_MONIKER_H #define __WINE_WINE_OBJ_MONIKER_H +#include "wine/obj_base.h" +#include "wine/obj_storage.h" #include "wine/obj_misc.h" + /***************************************************************************** * Predeclare the interfaces */ diff --git a/include/wine/obj_oleaut.h b/include/wine/obj_oleaut.h index dd4e6210e46..6f5dece5b69 100644 --- a/include/wine/obj_oleaut.h +++ b/include/wine/obj_oleaut.h @@ -1,14 +1,11 @@ /* * Defines the COM interfaces and APIs related to OLE automation support. - * - * Depends on 'obj_base.h'. */ #ifndef __WINE_WINE_OBJ_OLEAUT_H #define __WINE_WINE_OBJ_OLEAUT_H -#include "windows.h" -#include "wintypes.h" +#include "wine/obj_base.h" /***************************************************************************** * Predeclare the interfaces diff --git a/include/wine/obj_olefont.h b/include/wine/obj_olefont.h index 8293f2a2a40..52b06f130e0 100644 --- a/include/wine/obj_olefont.h +++ b/include/wine/obj_olefont.h @@ -7,8 +7,8 @@ #ifndef __WINE_WINE_OBJ_OLEFONT_H #define __WINE_WINE_OBJ_OLEFONT_H -#include "windows.h" -#include "wintypes.h" +#include "wine/obj_base.h" +#include "wingdi.h" /* TEXTMETRIC*/ /***************************************************************************** * Predeclare the interfaces diff --git a/include/wine/obj_propertystorage.h b/include/wine/obj_propertystorage.h index 1e7de55626d..eed3a55849a 100644 --- a/include/wine/obj_propertystorage.h +++ b/include/wine/obj_propertystorage.h @@ -1,12 +1,12 @@ /* * Defines the COM interfaces and APIs related to saving properties to file. - * - * Depends on 'obj_storage.h' and 'obj_base.h'. */ #ifndef __WINE_WINE_OBJ_PROPERTYSTORAGE_H #define __WINE_WINE_OBJ_PROPERTYSTORAGE_H +#include "wine/obj_base.h" +#include "wine/obj_storage.h" /***************************************************************************** * Predeclare the interfaces diff --git a/include/wine/obj_storage.h b/include/wine/obj_storage.h index 63f230267dc..fb281748bfd 100644 --- a/include/wine/obj_storage.h +++ b/include/wine/obj_storage.h @@ -1,15 +1,13 @@ /* * Defines the COM interfaces and APIs related to structured data storage. - * - * Depends on 'obj_base.h'. */ #ifndef __WINE_WINE_OBJ_STORAGE_H #define __WINE_WINE_OBJ_STORAGE_H -#include "winbase.h" - +#include "winnt.h" +#include "wine/obj_base.h" /***************************************************************************** * Predeclare the structures diff --git a/include/wine/winuser16.h b/include/wine/winuser16.h index 8313681da24..f10e12e1ddf 100644 --- a/include/wine/winuser16.h +++ b/include/wine/winuser16.h @@ -1,6 +1,7 @@ #ifndef __WINE_WINUSER16_H #define __WINE_WINUSER16_H +#include "wintypes.h" #include "winbase.h" #include "winuser.h" diff --git a/library/winestub.c b/library/winestub.c index f761634c8d5..b76463fcfc0 100644 --- a/library/winestub.c +++ b/library/winestub.c @@ -1,7 +1,7 @@ /* Sample winestub.c file for compiling programs with libwine.so. */ #include -#include "windows.h" +#include "winuser.h" #include "xmalloc.h" extern int PASCAL WinMain(HINSTANCE,HINSTANCE,LPSTR,int); diff --git a/memory/string.c b/memory/string.c index 700db59ad57..974fe072362 100644 --- a/memory/string.c +++ b/memory/string.c @@ -7,8 +7,9 @@ #include #include -#include "winbase.h" -#include "winuser.h" +#include "wine/winbase16.h" +#include "wine/winuser16.h" +#include "wine/keyboard16.h" #include "winerror.h" #include "ldt.h" #include "debug.h" diff --git a/misc/sound.c b/misc/sound.c index f4f4e9fd0c9..40f11add429 100644 --- a/misc/sound.c +++ b/misc/sound.c @@ -4,6 +4,7 @@ #include #include "wintypes.h" +#include "wine/winesound.h" #include "debug.h" INT16 WINAPI OpenSound16(void) diff --git a/multimedia/mmsystem.c b/multimedia/mmsystem.c index 7106493ec33..83f910d9b82 100644 --- a/multimedia/mmsystem.c +++ b/multimedia/mmsystem.c @@ -24,12 +24,10 @@ #include "winbase.h" #include "windef.h" #include "wine/winbase16.h" -#include "wine/winuser16.h" #include "heap.h" #include "ldt.h" #include "user.h" #include "driver.h" -#include "mmsystem.h" #include "multimedia.h" #include "callback.h" #include "module.h" diff --git a/ole/bindctx.c b/ole/bindctx.c index 923ad7309a6..68f3fc90c64 100644 --- a/ole/bindctx.c +++ b/ole/bindctx.c @@ -9,8 +9,6 @@ #include #include #include "winerror.h" -#include "wine/obj_base.h" -#include "wine/obj_storage.h" #include "wine/obj_moniker.h" #include "debug.h" #include "heap.h" diff --git a/ole/filemoniker.c b/ole/filemoniker.c index 50de54425ce..8d77deff746 100644 --- a/ole/filemoniker.c +++ b/ole/filemoniker.c @@ -8,10 +8,8 @@ #include #include #include -#include "winerror.h" -#include "wine/obj_base.h" -#include "wine/obj_storage.h" #include "wine/obj_moniker.h" +#include "winerror.h" #include "debug.h" #include "heap.h" diff --git a/ole/ifs.c b/ole/ifs.c index defe8911878..e87309d2b86 100644 --- a/ole/ifs.c +++ b/ole/ifs.c @@ -13,7 +13,6 @@ #include "heap.h" #include "wine/winbase16.h" #include "wine/obj_base.h" -#include "objbase.h" #include "local.h" #include "module.h" #include "debug.h" diff --git a/ole/itemmoniker.c b/ole/itemmoniker.c index 52aaf847c82..1312e19a43a 100644 --- a/ole/itemmoniker.c +++ b/ole/itemmoniker.c @@ -9,8 +9,6 @@ #include #include #include "winerror.h" -#include "wine/obj_base.h" -#include "wine/obj_storage.h" #include "wine/obj_moniker.h" #include "debug.h" #include "heap.h" diff --git a/ole/moniker.c b/ole/moniker.c index 04329d5f579..aa0dc4688dd 100644 --- a/ole/moniker.c +++ b/ole/moniker.c @@ -10,8 +10,6 @@ #include #include #include "winerror.h" -#include "wine/obj_base.h" -#include "wine/obj_storage.h" #include "wine/obj_moniker.h" #include "debug.h" diff --git a/ole/ole2.c b/ole/ole2.c index 61f909d46df..1e4ad28f18b 100644 --- a/ole/ole2.c +++ b/ole/ole2.c @@ -7,17 +7,12 @@ #include -#include "windows.h" +#include "winuser.h" #include "winerror.h" #include "ole2.h" #include "process.h" -#include "debug.h" -#include "objbase.h" -#include "objidl.h" -#include "wine/obj_base.h" #include "wine/obj_clientserver.h" -#include "wine/obj_storage.h" -#include "wine/obj_moniker.h" +#include "debug.h" /****************************************************************************** * These are static/global variables and internal data structures that the diff --git a/ole/ole2disp.c b/ole/ole2disp.c index fe0c5b44a7a..68026e9247d 100644 --- a/ole/ole2disp.c +++ b/ole/ole2disp.c @@ -5,14 +5,10 @@ */ #include -#include "windows.h" #include "winerror.h" #include "ole.h" -#include "ole2.h" #include "oleauto.h" -#include "wtypes.h" #include "wine/obj_base.h" -#include "objbase.h" #include "heap.h" #include "ldt.h" #include "debug.h" diff --git a/ole/ole2nls.c b/ole/ole2nls.c index 6a2671ade1b..77ddbf6b712 100644 --- a/ole/ole2nls.c +++ b/ole/ole2nls.c @@ -10,7 +10,6 @@ #include #include "winuser.h" #include "heap.h" -#include "ole.h" #include "options.h" #include "winnls.h" #include "winreg.h" diff --git a/ole/olecli.c b/ole/olecli.c index 6db40467e75..2c0effeea19 100644 --- a/ole/olecli.c +++ b/ole/olecli.c @@ -7,13 +7,11 @@ /* At the moment, these are only empty stubs. */ -#include "windows.h" #include "winerror.h" #include "ole.h" #include "gdi.h" +#include "wine/obj_dataobject.h" #include "debug.h" -#include "ole2.h" -#include "objidl.h" extern LONG OLE_current_handle; diff --git a/ole/oledlg.c b/ole/oledlg.c index 2adca0e5128..526b1933078 100644 --- a/ole/oledlg.c +++ b/ole/oledlg.c @@ -4,8 +4,8 @@ * Copyright 1998 Patrik Stridvall */ -#include "windows.h" #include "wintypes.h" +#include "winbase.h" #include "winerror.h" #include "ole.h" #include "oledlg.h" diff --git a/ole/olefont.c b/ole/olefont.c index 6f3e78e70a8..c8d58d96bc8 100644 --- a/ole/olefont.c +++ b/ole/olefont.c @@ -8,7 +8,6 @@ */ #include #include -#include "windows.h" #include "winerror.h" #include "oleauto.h" #include "ocidl.h" diff --git a/ole/oleobj.c b/ole/oleobj.c index 361c4121758..9744a4664e2 100644 --- a/ole/oleobj.c +++ b/ole/oleobj.c @@ -6,14 +6,13 @@ #include -#include "ole.h" -#include "ole2.h" +#include "oleobj.h" +#include "winbase.h" #include "winerror.h" #include "wine/obj_base.h" #include "wine/obj_storage.h" #include "wine/obj_moniker.h" #include "wine/obj_dataobject.h" -#include "oleobj.h" #include "debug.h" diff --git a/ole/olesvr.c b/ole/olesvr.c index f7ca59d113b..5b216bf35f5 100644 --- a/ole/olesvr.c +++ b/ole/olesvr.c @@ -7,7 +7,6 @@ /* At the moment, these are only empty stubs. */ -#include "windows.h" #include "ole.h" #include "debug.h" diff --git a/ole/safearray.c b/ole/safearray.c index 45e19daf167..26749a1665d 100644 --- a/ole/safearray.c +++ b/ole/safearray.c @@ -7,15 +7,14 @@ * Copyright 1999 Sylvain St-Germain */ -#include -#include -#include -#include -#include -#include #include -#include +#include +#include "wintypes.h" +#include "winerror.h" +#include "winbase.h" +#include "oleauto.h" #include "wine/obj_base.h" +#include "debug.h" /* Localy used methods */ static INT diff --git a/ole/stg_bigblockfile.c b/ole/stg_bigblockfile.c index e523a576f25..82cdaa677e3 100644 --- a/ole/stg_bigblockfile.c +++ b/ole/stg_bigblockfile.c @@ -23,11 +23,8 @@ #include #include -#include "windows.h" +#include "winbase.h" #include "winerror.h" -#include "ole.h" -#include "ole2.h" -#include "wine/obj_base.h" #include "wine/obj_storage.h" #include "storage32.h" diff --git a/ole/stg_stream.c b/ole/stg_stream.c index 2d82e572e8d..010a8267739 100644 --- a/ole/stg_stream.c +++ b/ole/stg_stream.c @@ -13,11 +13,8 @@ #include #include -#include "windows.h" +#include "winbase.h" #include "winerror.h" -#include "ole.h" -#include "ole2.h" -#include "wine/obj_base.h" #include "wine/obj_storage.h" #include "storage32.h" diff --git a/ole/storage.c b/ole/storage.c index f9b18379b4f..0e29d7d3113 100644 --- a/ole/storage.c +++ b/ole/storage.c @@ -18,7 +18,6 @@ #include "ole.h" #include "wine/obj_base.h" #include "wine/obj_storage.h" -#include "objbase.h" #include "heap.h" #include "module.h" #include "ldt.h" diff --git a/ole/storage32.c b/ole/storage32.c index 549264e88a6..7dc0ca2e8f0 100644 --- a/ole/storage32.c +++ b/ole/storage32.c @@ -15,18 +15,12 @@ #include #include -#include "windows.h" +#include "winbase.h" #include "winerror.h" -#include "file.h" -#include "ole.h" -#include "ole2.h" -#include "objbase.h" +#include "wine/obj_storage.h" +#include "wine/winestring.h" #include "crtdll.h" #include "tchar.h" -#include "heap.h" - -#include "winnt.h" -#include "winbase.h" #include "debug.h" #include "storage32.h" diff --git a/ole/typelib.c b/ole/typelib.c index bd87d1e0d06..62bd118bd72 100644 --- a/ole/typelib.c +++ b/ole/typelib.c @@ -8,13 +8,12 @@ #include #include #include "wintypes.h" +#include "winerror.h" +#include "winreg.h" +#include "oleauto.h" #include "wine/winbase16.h" #include "heap.h" -#include "winreg.h" -#include "winerror.h" -#include "oleauto.h" #include "wine/obj_base.h" -#include "objbase.h" #include "debug.h" #include "winversion.h" diff --git a/ole/variant.c b/ole/variant.c index 045e2a88423..3c3e4296947 100644 --- a/ole/variant.c +++ b/ole/variant.c @@ -25,7 +25,6 @@ #include "heap.h" #include "debug.h" #include "winerror.h" -#include "mapidefs.h" #include "parsedt.h" #include diff --git a/tools/fnt2bdf.c b/tools/fnt2bdf.c index a90e55fb0a4..991d76ab26e 100644 --- a/tools/fnt2bdf.c +++ b/tools/fnt2bdf.c @@ -15,7 +15,7 @@ #include #include -#include "windows.h" +#include "winuser.h" #include "fnt2bdf.h" #include "neexe.h" #include "module.h" diff --git a/windows/display.c b/windows/display.c index c40fdc28bfe..a96a0a64860 100644 --- a/windows/display.c +++ b/windows/display.c @@ -7,8 +7,8 @@ #include "config.h" -#include "debug.h" #include "display.h" +#include "debug.h" #include "wintypes.h" #ifndef X_DISPLAY_MISSING