X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/4b60077b404e4200e5574ed5256776f37a372184..c6e7099c5d69879bd1bcbad39e5e608e4868fe25:/src/mac/carbon/mediactrl.cpp diff --git a/src/mac/carbon/mediactrl.cpp b/src/mac/carbon/mediactrl.cpp index 4124a096ee..7a1dd947f7 100644 --- a/src/mac/carbon/mediactrl.cpp +++ b/src/mac/carbon/mediactrl.cpp @@ -118,7 +118,11 @@ public: void FinishLoad(); wxSize m_bestSize; //Original movie size +#ifdef __WXMAC_OSX__ struct MovieType** m_movie; //QT Movie handle/instance +#else + Movie m_movie ; +#endif wxControl* m_ctrl; //Parent control bool m_bVideo; //Whether or not we have video class _wxQTTimer* m_timer; //Timer for streaming the movie @@ -220,7 +224,7 @@ wxQTMediaBackend::~wxQTMediaBackend() if(m_timer) Cleanup(); - //Note that ExitMovies() is not neccessary... + //Note that ExitMovies() is not necessary... ExitMovies(); } @@ -294,6 +298,12 @@ bool wxQTMediaBackend::Load(const wxString& fileName) short movieResFile; FSSpec sfFile; + //FIXME:wxMacFilename2FSSpec crashes on empty string - + //does it crash on other strings too and should this + //"fix" be put in the carbon wxSound? + if (fileName.empty()) + return false; + wxMacFilename2FSSpec( fileName , &sfFile ); if (OpenMovieFile (&sfFile, &movieResFile, fsRdPerm) != noErr) @@ -457,7 +467,7 @@ void wxQTMediaBackend::FinishLoad() // //Here, if the parent of the control has a sizer - we //tell it to recalculate the size of this control since - //the user opened a seperate media file + //the user opened a separate media file // m_ctrl->InvalidateBestSize(); m_ctrl->GetParent()->Layout(); @@ -657,7 +667,7 @@ void wxQTMediaBackend::Move(int x, int y, int w, int h) //in source file that contains stuff you don't directly use -#include +#include "wx/html/forcelnk.h" FORCE_LINK_ME(basewxmediabackends); #endif //wxUSE_MEDIACTRL