ReactOS  0.4.15-dev-1386-g5cb9f87
shlwapi_main.c File Reference
#include <stdarg.h>
#include "windef.h"
#include "winbase.h"
#include "shlwapi.h"
#include "wine/debug.h"
Include dependency graph for shlwapi_main.c:

Go to the source code of this file.

Macros

#define NO_SHLWAPI_REG
 
#define NO_SHLWAPI_STREAM
 

Functions

 WINE_DEFAULT_DEBUG_CHANNEL (shell)
 
BOOL WINAPI DllMain (HINSTANCE hinstDLL, DWORD fdwReason, LPVOID fImpLoad)
 
HRESULT WINAPI DllGetVersion (DLLVERSIONINFO *pdvi)
 

Variables

DECLSPEC_HIDDEN HINSTANCE shlwapi_hInstance = 0
 
DECLSPEC_HIDDEN DWORD SHLWAPI_ThreadRef_index = TLS_OUT_OF_INDEXES
 

Macro Definition Documentation

◆ NO_SHLWAPI_REG

#define NO_SHLWAPI_REG

Definition at line 26 of file shlwapi_main.c.

◆ NO_SHLWAPI_STREAM

#define NO_SHLWAPI_STREAM

Definition at line 27 of file shlwapi_main.c.

Function Documentation

◆ DllGetVersion()

HRESULT WINAPI DllGetVersion ( DLLVERSIONINFO pdvi)

Definition at line 91 of file shlwapi_main.c.

92 {
93  DLLVERSIONINFO2 *pdvi2 = (DLLVERSIONINFO2*)pdvi;
94 
95  TRACE("(%p)\n",pdvi);
96 
97  if (!pdvi)
98  return E_INVALIDARG;
99 
100  switch (pdvi2->info1.cbSize)
101  {
102  case sizeof(DLLVERSIONINFO2):
103  pdvi2->dwFlags = 0;
104  pdvi2->ullVersion = MAKEDLLVERULL(6, 0, 2800, 1612);
105  /* Fall through */
106  case sizeof(DLLVERSIONINFO):
107  pdvi2->info1.dwMajorVersion = 6;
108  pdvi2->info1.dwMinorVersion = 0;
109  pdvi2->info1.dwBuildNumber = 2800;
111  return S_OK;
112  }
113 
114  WARN("pdvi->cbSize = %d, unhandled\n", pdvi2->info1.cbSize);
115  return E_INVALIDARG;
116 }
DWORD dwMinorVersion
Definition: shlwapi.h:1956
#define WARN(fmt,...)
Definition: debug.h:112
struct _DLLVERSIONINFO2 DLLVERSIONINFO2
DWORD dwBuildNumber
Definition: shlwapi.h:1957
DLLVERSIONINFO info1
Definition: shlwapi.h:1972
#define E_INVALIDARG
Definition: ddrawi.h:101
DWORD dwMajorVersion
Definition: shlwapi.h:1955
#define MAKEDLLVERULL(mjr, mnr, bld, qfe)
Definition: shlwapi.h:1982
#define TRACE(s)
Definition: solgame.cpp:4
DWORD dwPlatformID
Definition: shlwapi.h:1958
#define S_OK
Definition: intsafe.h:51
struct _DllVersionInfo DLLVERSIONINFO
#define DLLVER_PLATFORM_WINDOWS
Definition: shlwapi.h:1961

◆ DllMain()

BOOL WINAPI DllMain ( HINSTANCE  hinstDLL,
DWORD  fdwReason,
LPVOID  fImpLoad 
)

Definition at line 56 of file shlwapi_main.c.

57 {
58  TRACE("%p 0x%x %p\n", hinstDLL, fdwReason, fImpLoad);
59  switch (fdwReason)
60  {
61  case DLL_PROCESS_ATTACH:
62  DisableThreadLibraryCalls(hinstDLL);
63  shlwapi_hInstance = hinstDLL;
65  break;
66  case DLL_PROCESS_DETACH:
67  if (fImpLoad) break;
69  break;
70  }
71  return TRUE;
72 }
#define TRUE
Definition: types.h:120
BOOL WINAPI DisableThreadLibraryCalls(IN HMODULE hLibModule)
Definition: loader.c:85
#define DLL_PROCESS_ATTACH
Definition: compat.h:131
DECLSPEC_HIDDEN DWORD SHLWAPI_ThreadRef_index
Definition: shlwapi_main.c:34
#define DLL_PROCESS_DETACH
Definition: compat.h:130
#define TRACE(s)
Definition: solgame.cpp:4
BOOL WINAPI TlsFree(IN DWORD Index)
Definition: thread.c:1154
DWORD WINAPI TlsAlloc(VOID)
Definition: thread.c:1088
#define TLS_OUT_OF_INDEXES
Definition: winbase.h:530
DWORD LPVOID fImpLoad
Definition: misc.cpp:155
DECLSPEC_HIDDEN HINSTANCE shlwapi_hInstance
Definition: shlwapi_main.c:33

◆ WINE_DEFAULT_DEBUG_CHANNEL()

WINE_DEFAULT_DEBUG_CHANNEL ( shell  )

Variable Documentation

◆ shlwapi_hInstance

◆ SHLWAPI_ThreadRef_index

DECLSPEC_HIDDEN DWORD SHLWAPI_ThreadRef_index = TLS_OUT_OF_INDEXES

Definition at line 34 of file shlwapi_main.c.

Referenced by DllMain(), SHGetThreadRef(), and SHSetThreadRef().