IWebBrowser2 added and is functional.

This commit is contained in:
MusicalProgrammer
2018-07-06 19:23:52 -04:00
parent f99d18f6ae
commit 03fd38aaa7

View File

@@ -77,11 +77,11 @@ Demo::Demo(const GAppSettings& settings,HWND parentWindow) { //: GApp(settings,w
_hWndMain = parentWindow; _hWndMain = parentWindow;
HMODULE hThisInstance = GetModuleHandle(NULL); HMODULE hThisInstance = GetModuleHandle(NULL);
IWebBrowser2* wb = 0;
_hwndToolbox = CreateWindowEx( _hwndToolbox = CreateWindowEx(
WS_EX_ACCEPTFILES, WS_EX_ACCEPTFILES,
"toolboxHWND", "AX",
"Main test", "{8856F961-340A-11D0-A96B-00C04FD705A2}",
WS_CHILD | WS_VISIBLE, WS_CHILD | WS_VISIBLE,
0, 0,
560, 560,
@@ -92,6 +92,15 @@ Demo::Demo(const GAppSettings& settings,HWND parentWindow) { //: GApp(settings,w
hThisInstance, hThisInstance,
NULL NULL
); );
SendMessage(_hwndToolbox,AX_INPLACE,1,0);
SendMessage(_hwndToolbox,AX_QUERYINTERFACE,(WPARAM)&IID_IWebBrowser2,(LPARAM)&wb);
if (wb)
{
wb->Navigate(L"https://scottbeebiwan.tk/g3d/toolbox/",0,0,0,0);
wb->Release();
}
_buttonTest = CreateWindow( _buttonTest = CreateWindow(
"COMBOBOX", "COMBOBOX",
"", "",
@@ -1562,6 +1571,7 @@ int main(int argc, char** argv) {
OleInitialize(0); OleInitialize(0);
if (!AXRegister()) if (!AXRegister())
return 0; return 0;
tempPath = ((std::string)getenv("temp")) + "/"+PlaceholderName; tempPath = ((std::string)getenv("temp")) + "/"+PlaceholderName;
CreateDirectory(tempPath.c_str(), NULL); CreateDirectory(tempPath.c_str(), NULL);