]> git.saurik.com Git - wxWidgets.git/commitdiff
Don't consider lack of connection points an error in wxActiveXContainer.
authorVadim Zeitlin <vadim@wxwidgets.org>
Sun, 24 Oct 2010 22:41:29 +0000 (22:41 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Sun, 24 Oct 2010 22:41:29 +0000 (22:41 +0000)
Handle CONNECT_E_NOCONNECTION return value from IConnectionPointContainer::
FindConnectionPoint() as an expected error and don't complain about it.

See #11566.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65910 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/msw/ole/activex.cpp

index 92a5a1186b892bcacaa3dcaa67c81f5a6de38a74..e2661bda65fe5dc78ad38ee0ec78a6afc417c133 100644 (file)
@@ -1020,7 +1020,13 @@ void wxActiveXContainer::CreateActiveX(REFIID iid, IUnknown* pUnk)
 
                 HRESULT hret =
                     cpContainer->FindConnectionPoint(ta->guid, cp.GetRef());
-                CHECK_HR(hret);
+
+                // Notice that the return value of CONNECT_E_NOCONNECTION is
+                // expected if the interface doesn't support connection points.
+                if ( hret != CONNECT_E_NOCONNECTION )
+                {
+                    CHECK_HR(hret);
+                }
 
                 if ( cp )
                 {