Commit 5d0873a7 authored by Mike McCormack's avatar Mike McCormack Committed by Alexandre Julliard

shdocvw: Implement IEWinMain using a simple window frame.

parent 11132d2c
...@@ -16,6 +16,7 @@ C_SRCS = \ ...@@ -16,6 +16,7 @@ C_SRCS = \
events.c \ events.c \
factory.c \ factory.c \
frame.c \ frame.c \
iexplore.c \
navigate.c \ navigate.c \
oleobject.c \ oleobject.c \
persist.c \ persist.c \
......
...@@ -185,5 +185,8 @@ static inline void SHDOCVW_LockModule(void) { InterlockedIncrement( &SHDOCVW_ref ...@@ -185,5 +185,8 @@ static inline void SHDOCVW_LockModule(void) { InterlockedIncrement( &SHDOCVW_ref
static inline void SHDOCVW_UnlockModule(void) { InterlockedDecrement( &SHDOCVW_refCount ); } static inline void SHDOCVW_UnlockModule(void) { InterlockedDecrement( &SHDOCVW_refCount ); }
extern HINSTANCE shdocvw_hinstance; extern HINSTANCE shdocvw_hinstance;
extern void register_iewindow_class(void);
extern void unregister_iewindow_class(void);
extern BOOL create_ie_window(LPCWSTR url);
#endif /* __WINE_SHDOCVW_H */ #endif /* __WINE_SHDOCVW_H */
...@@ -100,18 +100,20 @@ static BOOL SHDOCVW_GetMozctlPath( LPWSTR szPath, DWORD sz ) ...@@ -100,18 +100,20 @@ static BOOL SHDOCVW_GetMozctlPath( LPWSTR szPath, DWORD sz )
*/ */
BOOL WINAPI DllMain(HINSTANCE hinst, DWORD fdwReason, LPVOID fImpLoad) BOOL WINAPI DllMain(HINSTANCE hinst, DWORD fdwReason, LPVOID fImpLoad)
{ {
TRACE("%p 0x%lx %p\n", hinst, fdwReason, fImpLoad); TRACE("%p 0x%lx %p\n", hinst, fdwReason, fImpLoad);
switch (fdwReason) switch (fdwReason)
{ {
case DLL_PROCESS_ATTACH: case DLL_PROCESS_ATTACH:
shdocvw_hinstance = hinst; shdocvw_hinstance = hinst;
break; register_iewindow_class();
case DLL_PROCESS_DETACH: break;
if (SHDOCVW_hshell32) FreeLibrary(SHDOCVW_hshell32); case DLL_PROCESS_DETACH:
if (hMozCtl && hMozCtl != (HMODULE)~0UL) FreeLibrary(hMozCtl); if (SHDOCVW_hshell32) FreeLibrary(SHDOCVW_hshell32);
break; if (hMozCtl && hMozCtl != (HMODULE)~0UL) FreeLibrary(hMozCtl);
} unregister_iewindow_class();
return TRUE; break;
}
return TRUE;
} }
/************************************************************************* /*************************************************************************
...@@ -664,7 +666,25 @@ DWORD WINAPI StopWatchAFORWARD(DWORD dwClass, LPCSTR lpszStr, DWORD dwUnknown, ...@@ -664,7 +666,25 @@ DWORD WINAPI StopWatchAFORWARD(DWORD dwClass, LPCSTR lpszStr, DWORD dwUnknown,
*/ */
DWORD WINAPI IEWinMain(LPSTR szCommandLine, int nShowWindow) DWORD WINAPI IEWinMain(LPSTR szCommandLine, int nShowWindow)
{ {
LPWSTR url;
DWORD len;
FIXME("%s %d\n", debugstr_a(szCommandLine), nShowWindow); FIXME("%s %d\n", debugstr_a(szCommandLine), nShowWindow);
CoInitialize(NULL);
/* FIXME: parse the command line properly, handle -Embedding */
len = MultiByteToWideChar(CP_ACP, 0, szCommandLine, -1, NULL, 0);
url = HeapAlloc(GetProcessHeap(),0,len*sizeof(WCHAR));
MultiByteToWideChar(CP_ACP, 0, szCommandLine, -1, url, len);
create_ie_window(url);
HeapFree(GetProcessHeap(), 0, url);
CoUninitialize();
ExitProcess(0); ExitProcess(0);
return 0; return 0;
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment