[IEFRAME] Sync with Wine Staging 1.9.4. CORE-10912
authorAmine Khaldi <amine.khaldi@reactos.org>
Wed, 2 Mar 2016 10:41:57 +0000 (10:41 +0000)
committerAmine Khaldi <amine.khaldi@reactos.org>
Wed, 2 Mar 2016 10:41:57 +0000 (10:41 +0000)
svn path=/trunk/; revision=70865

reactos/dll/win32/ieframe/dochost.c
reactos/dll/win32/ieframe/ieframe.h
reactos/dll/win32/ieframe/iexplore.c
reactos/dll/win32/ieframe/intshcut.c
reactos/dll/win32/ieframe/navigate.c
reactos/dll/win32/ieframe/oleobject.c
reactos/dll/win32/ieframe/webbrowser.c
reactos/media/doc/README.WINE

index 820cb6c..6213aa4 100644 (file)
@@ -73,7 +73,7 @@ void abort_dochost_tasks(DocHost *This, task_proc_t proc)
     }
 }
 
-void on_commandstate_change(DocHost *doc_host, LONG command, VARIANT_BOOL enable)
+void on_commandstate_change(DocHost *doc_host, LONG command, BOOL enable)
 {
     DISPPARAMS dispparams;
     VARIANTARG params[2];
@@ -648,13 +648,13 @@ static HRESULT WINAPI ClOleCommandTarget_QueryStatus(IOleCommandTarget *iface,
         const GUID *pguidCmdGroup, ULONG cCmds, OLECMD prgCmds[], OLECMDTEXT *pCmdText)
 {
     DocHost *This = impl_from_IOleCommandTarget(iface);
-    ULONG i= 0;
-    FIXME("(%p)->(%s %u %p %p)\n", This, debugstr_guid(pguidCmdGroup), cCmds, prgCmds,
+    ULONG i;
+
+    TRACE("(%p)->(%s %u %p %p)\n", This, debugstr_guid(pguidCmdGroup), cCmds, prgCmds,
           pCmdText);
-    while (prgCmds && (cCmds > i)) {
-        FIXME("command_%u: %u, 0x%x\n", i, prgCmds[i].cmdID, prgCmds[i].cmdf);
-        i++;
-    }
+    for(i=0; prgCmds && i < cCmds; i++)
+        TRACE("unsupported command %u (%x)\n", prgCmds[i].cmdID, prgCmds[i].cmdf);
+
     return E_NOTIMPL;
 }
 
@@ -683,7 +683,7 @@ static HRESULT WINAPI ClOleCommandTarget_Exec(IOleCommandTarget *iface,
             notify_download_state(This, V_I4(pvaIn));
             return S_OK;
         default:
-            FIXME("Unimplemented cmdid %d\n", nCmdID);
+            TRACE("Unimplemented cmdid %d\n", nCmdID);
             return E_NOTIMPL;
         }
     }
@@ -735,7 +735,7 @@ static HRESULT WINAPI ClOleCommandTarget_Exec(IOleCommandTarget *iface,
         }
 
         default:
-            FIXME("unsupported command %d of CGID_DocHostCmdPriv\n", nCmdID);
+            TRACE("unsupported command %d of CGID_DocHostCmdPriv\n", nCmdID);
             return E_NOTIMPL;
         }
     }
@@ -748,7 +748,7 @@ static HRESULT WINAPI ClOleCommandTarget_Exec(IOleCommandTarget *iface,
             return S_OK;
 
         default:
-            FIXME("Unimplemented cmdid %d of CGID_Explorer\n", nCmdID);
+            TRACE("Unimplemented cmdid %d of CGID_Explorer\n", nCmdID);
             return E_NOTIMPL;
         }
     }
@@ -756,7 +756,7 @@ static HRESULT WINAPI ClOleCommandTarget_Exec(IOleCommandTarget *iface,
     if(IsEqualGUID(pguidCmdGroup, &CGID_ShellDocView)) {
         switch(nCmdID) {
         default:
-            FIXME("Unimplemented cmdid %d of CGID_ShellDocView\n", nCmdID);
+            TRACE("Unimplemented cmdid %d of CGID_ShellDocView\n", nCmdID);
             return E_NOTIMPL;
         }
     }
@@ -767,7 +767,7 @@ static HRESULT WINAPI ClOleCommandTarget_Exec(IOleCommandTarget *iface,
         return IOleCommandTarget_Exec(This->olecmd, pguidCmdGroup, nCmdID, nCmdexecopt, pvaIn, pvaOut);
     }
 
-    FIXME("Unimplemented cmdid %d of group %s\n", nCmdID, debugstr_guid(pguidCmdGroup));
+    TRACE("Unimplemented cmdid %d of group %s\n", nCmdID, debugstr_guid(pguidCmdGroup));
     return E_NOTIMPL;
 }
 
index 36a0867..48471dd 100644 (file)
@@ -295,7 +295,7 @@ HRESULT dochost_object_available(DocHost*,IUnknown*) DECLSPEC_HIDDEN;
 void set_doc_state(DocHost*,READYSTATE) DECLSPEC_HIDDEN;
 void deactivate_document(DocHost*) DECLSPEC_HIDDEN;
 void create_doc_view_hwnd(DocHost*) DECLSPEC_HIDDEN;
-void on_commandstate_change(DocHost*,LONG,VARIANT_BOOL) DECLSPEC_HIDDEN;
+void on_commandstate_change(DocHost*,LONG,BOOL) DECLSPEC_HIDDEN;
 void notify_download_state(DocHost*,BOOL) DECLSPEC_HIDDEN;
 void update_navigation_commands(DocHost *dochost) DECLSPEC_HIDDEN;
 
index 06c86b4..c1b4fa3 100644 (file)
@@ -458,7 +458,7 @@ static void create_rebar(InternetExplorer *ie)
     add_tb_button(ie, 4, ID_BROWSE_HOME, IDS_TB_HOME);
     add_tb_separator(ie);
     add_tb_button(ie, 5, ID_BROWSE_PRINT, IDS_TB_PRINT);
-    SendMessageW(ie->toolbar_hwnd, TB_SETBUTTONSIZE, 0, MAKELPARAM(55,50));
+    SendMessageW(ie->toolbar_hwnd, TB_SETBUTTONSIZE, 0, MAKELPARAM(65,50));
     SendMessageW(ie->toolbar_hwnd, TB_GETMAXSIZE, 0, (LPARAM)&toolbar_size);
 
     bandinf.cbSize = sizeof(bandinf);
index d47d867..73eb396 100644 (file)
@@ -490,8 +490,7 @@ static HRESULT WINAPI PersistFile_Load(IPersistFile *pFile, LPCOLESTR pszFileNam
                                           STGM_READWRITE | STGM_SHARE_EXCLUSIVE,
                                           &pPropStg);
 
-            get_profile_string(str_header, str_iconfile, pszFileName, &iconfile);
-            if (iconfile != NULL)
+            if (get_profile_string(str_header, str_iconfile, pszFileName, &iconfile))
             {
                 PROPSPEC ps;
                 PROPVARIANT pv;
@@ -504,13 +503,10 @@ static HRESULT WINAPI PersistFile_Load(IPersistFile *pFile, LPCOLESTR pszFileNam
                 {
                     TRACE("Failed to store the iconfile to our property storage.  hr = 0x%x\n", hr);
                 }
-
-                CoTaskMemFree(iconfile);
             }
+            CoTaskMemFree(iconfile);
 
-            get_profile_string(str_header, str_iconindex, pszFileName, &iconindexstring);
-
-            if (iconindexstring != NULL)
+            if (get_profile_string(str_header, str_iconindex, pszFileName, &iconindexstring))
             {
                 int iconindex;
                 PROPSPEC ps;
@@ -527,9 +523,8 @@ static HRESULT WINAPI PersistFile_Load(IPersistFile *pFile, LPCOLESTR pszFileNam
                 {
                     TRACE("Failed to store the iconindex to our property storage.  hr = 0x%x\n", hr);
                 }
-
-                CoTaskMemFree(iconindexstring);
             }
+            CoTaskMemFree(iconindexstring);
 
             IPropertyStorage_Release(pPropStg);
         }
index 7994b09..b1f9f22 100644 (file)
@@ -872,8 +872,8 @@ static HRESULT navigate_bsc(DocHost *This, BindStatusCallback *bsc, IMoniker *mo
     }
 
     notify_download_state(This, TRUE);
-    on_commandstate_change(This, CSC_NAVIGATEBACK, VARIANT_FALSE);
-    on_commandstate_change(This, CSC_NAVIGATEFORWARD, VARIANT_FALSE);
+    on_commandstate_change(This, CSC_NAVIGATEBACK, FALSE);
+    on_commandstate_change(This, CSC_NAVIGATEFORWARD, FALSE);
 
     if(This->document)
         deactivate_document(This);
index 4fe6aa7..b1520d6 100644 (file)
@@ -301,11 +301,6 @@ static void release_client_site(WebBrowser *This)
         IOleInPlaceUIWindow_Release(This->uiwindow);
         This->uiwindow = NULL;
     }
-
-    if(This->sink) {
-        IAdviseSink_Release(This->sink);
-        This->sink = NULL;
-    }
 }
 
 typedef struct {
@@ -461,8 +456,8 @@ static HRESULT WINAPI OleObject_SetClientSite(IOleObject *iface, LPOLECLIENTSITE
     release_client_site(This);
 
     if(!pClientSite) {
-        on_commandstate_change(&This->doc_host, CSC_NAVIGATEBACK, VARIANT_FALSE);
-        on_commandstate_change(&This->doc_host, CSC_NAVIGATEFORWARD, VARIANT_FALSE);
+        on_commandstate_change(&This->doc_host, CSC_NAVIGATEBACK, FALSE);
+        on_commandstate_change(&This->doc_host, CSC_NAVIGATEFORWARD, FALSE);
 
         if(This->doc_host.document)
             deactivate_document(&This->doc_host);
index b733305..88abd89 100644 (file)
@@ -160,6 +160,9 @@ static ULONG WINAPI WebBrowser_Release(IWebBrowser2 *iface)
     TRACE("(%p) ref=%d\n", This, ref);
 
     if(!ref) {
+        if(This->sink)
+            IAdviseSink_Release(This->sink);
+
         if(This->doc_host.document)
             IUnknown_Release(This->doc_host.document);
 
index 7992a50..fbc9fbb 100644 (file)
@@ -74,7 +74,7 @@ reactos/dll/win32/hlink               # Synced to WineStaging-1.7.55
 reactos/dll/win32/hnetcfg             # Synced to WineStaging-1.7.55
 reactos/dll/win32/httpapi             # Synced to WineStaging-1.7.55
 reactos/dll/win32/iccvid              # Synced to WineStaging-1.7.55
-reactos/dll/win32/ieframe             # Synced to WineStaging-1.7.55
+reactos/dll/win32/ieframe             # Synced to WineStaging-1.9.4
 reactos/dll/win32/imaadp32.acm        # Synced to WineStaging-1.7.55
 reactos/dll/win32/imagehlp            # Synced to WineStaging-1.7.55
 reactos/dll/win32/imm32               # Synced to Wine-1.7.27