]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/mediactrl.cpp
added wxZipFSHandler::Cleanup() (modified patch 1213615)
[wxWidgets.git] / src / msw / mediactrl.cpp
index 2709461f4ee5152d5035e7105fe63607462e9f6f..6d56bfa700df7c41993fc4fc35dbc15760a56644 100644 (file)
@@ -39,6 +39,7 @@
 #if wxUSE_MEDIACTRL
 
 #include "wx/dcclient.h"
+#include "wx/thread.h"
 
 //---------------------------------------------------------------------------
 // Externals (somewhere in src/msw/app.cpp)
@@ -742,7 +743,7 @@ struct TimeRecord {
 
 #define wxDL_METHOD_LOAD( lib, name, success ) \
     pfn_ ## name = (name ## Type) lib.GetSymbol( wxT(#name), &success ); \
-    if (!success) { wxLog::EnableLogging(true); return false; }
+    if (!success) { wxLog::EnableLogging(bWasLoggingEnabled); return false; }
 
 
 //Class that utilizes Robert Roeblings Dynamic Library Macros
@@ -829,11 +830,11 @@ bool wxQuickTimeLibrary::Initialize()
 {
     m_ok = false;
 
-    wxLog::EnableLogging(false);    //Turn off the wxDynamicLibrary logging
+    bool bWasLoggingEnabled = wxLog::EnableLogging(false);    //Turn off the wxDynamicLibrary logging
 
     if(!m_dll.Load(wxT("qtmlClient.dll")))
     {
-        wxLog::EnableLogging(true);
+        wxLog::EnableLogging(bWasLoggingEnabled);
         return false;
     }
 
@@ -875,7 +876,7 @@ bool wxQuickTimeLibrary::Initialize()
     wxDL_METHOD_LOAD( m_dll, GetMovieVolume, bOk );
     wxDL_METHOD_LOAD( m_dll, SetMovieVolume, bOk );
 
-    wxLog::EnableLogging(true);
+    wxLog::EnableLogging(bWasLoggingEnabled);
     m_ok = true;
 
     return true;
@@ -961,7 +962,7 @@ wxString wxAMMediaBackend::GetErrorString(HRESULT hrdsv)
                                      wxT("(numeric %i)\n")
                                      wxT("occured at line %i in ")
                                      wxT("mediactrl.cpp"),
-                                     (int)hrdsv, szError, __LINE__);
+                                     szError, (int)hrdsv, __LINE__);
     }
     else
     {