git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72282
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
monodll_taskbarx11.o
@COND_TOOLKIT_X11@__ADVANCED_PLATFORM_SRC_OBJECTS_1 = $(COND_TOOLKIT_X11___ADVANCED_PLATFORM_SRC_OBJECTS_1)
@COND_TOOLKIT_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS = \
monodll_taskbarx11.o
@COND_TOOLKIT_X11@__ADVANCED_PLATFORM_SRC_OBJECTS_1 = $(COND_TOOLKIT_X11___ADVANCED_PLATFORM_SRC_OBJECTS_1)
@COND_TOOLKIT_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS = \
-@COND_TOOLKIT_COCOA@ monodll_cocoa_mediactrl.o
+@COND_TOOLKIT_COCOA@ monodll_src_cocoa_mediactrl.o
@COND_TOOLKIT_GTK@__MEDIA_PLATFORM_SRC_OBJECTS = monodll_unix_mediactrl.o
@COND_TOOLKIT_MOTIF@__MEDIA_PLATFORM_SRC_OBJECTS = monodll_unix_mediactrl.o
@COND_TOOLKIT_MSW@__MEDIA_PLATFORM_SRC_OBJECTS = \
@COND_TOOLKIT_GTK@__MEDIA_PLATFORM_SRC_OBJECTS = monodll_unix_mediactrl.o
@COND_TOOLKIT_MOTIF@__MEDIA_PLATFORM_SRC_OBJECTS = monodll_unix_mediactrl.o
@COND_TOOLKIT_MSW@__MEDIA_PLATFORM_SRC_OBJECTS = \
@COND_TOOLKIT_MSW@ monodll_mediactrl_qt.o
@COND_TOOLKIT_OSX_CARBON@__MEDIA_PLATFORM_SRC_OBJECTS \
@COND_TOOLKIT_OSX_CARBON@ = monodll_carbon_mediactrl.o
@COND_TOOLKIT_MSW@ monodll_mediactrl_qt.o
@COND_TOOLKIT_OSX_CARBON@__MEDIA_PLATFORM_SRC_OBJECTS \
@COND_TOOLKIT_OSX_CARBON@ = monodll_carbon_mediactrl.o
-@COND_TOOLKIT_OSX_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS =
+@COND_TOOLKIT_OSX_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS \
+@COND_TOOLKIT_OSX_COCOA@ = monodll_osx_cocoa_mediactrl.o
@COND_TOOLKIT_OSX_IPHONE@__MEDIA_PLATFORM_SRC_OBJECTS =
@COND_TOOLKIT_PM@__MEDIA_PLATFORM_SRC_OBJECTS =
@COND_TOOLKIT_WINCE@__MEDIA_PLATFORM_SRC_OBJECTS = \
@COND_TOOLKIT_OSX_IPHONE@__MEDIA_PLATFORM_SRC_OBJECTS =
@COND_TOOLKIT_PM@__MEDIA_PLATFORM_SRC_OBJECTS =
@COND_TOOLKIT_WINCE@__MEDIA_PLATFORM_SRC_OBJECTS = \
monolib_taskbarx11.o
@COND_TOOLKIT_X11@__ADVANCED_PLATFORM_SRC_OBJECTS_3 = $(COND_TOOLKIT_X11___ADVANCED_PLATFORM_SRC_OBJECTS_3)
@COND_TOOLKIT_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS_1 = \
monolib_taskbarx11.o
@COND_TOOLKIT_X11@__ADVANCED_PLATFORM_SRC_OBJECTS_3 = $(COND_TOOLKIT_X11___ADVANCED_PLATFORM_SRC_OBJECTS_3)
@COND_TOOLKIT_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS_1 = \
-@COND_TOOLKIT_COCOA@ monolib_cocoa_mediactrl.o
+@COND_TOOLKIT_COCOA@ monolib_src_cocoa_mediactrl.o
@COND_TOOLKIT_GTK@__MEDIA_PLATFORM_SRC_OBJECTS_1 = \
@COND_TOOLKIT_GTK@ monolib_unix_mediactrl.o
@COND_TOOLKIT_MOTIF@__MEDIA_PLATFORM_SRC_OBJECTS_1 = \
@COND_TOOLKIT_GTK@__MEDIA_PLATFORM_SRC_OBJECTS_1 = \
@COND_TOOLKIT_GTK@ monolib_unix_mediactrl.o
@COND_TOOLKIT_MOTIF@__MEDIA_PLATFORM_SRC_OBJECTS_1 = \
@COND_TOOLKIT_MSW@ monolib_mediactrl_qt.o
@COND_TOOLKIT_OSX_CARBON@__MEDIA_PLATFORM_SRC_OBJECTS_1 \
@COND_TOOLKIT_OSX_CARBON@ = monolib_carbon_mediactrl.o
@COND_TOOLKIT_MSW@ monolib_mediactrl_qt.o
@COND_TOOLKIT_OSX_CARBON@__MEDIA_PLATFORM_SRC_OBJECTS_1 \
@COND_TOOLKIT_OSX_CARBON@ = monolib_carbon_mediactrl.o
-@COND_TOOLKIT_OSX_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS_1 =
+@COND_TOOLKIT_OSX_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS_1 \
+@COND_TOOLKIT_OSX_COCOA@ = monolib_osx_cocoa_mediactrl.o
@COND_TOOLKIT_OSX_IPHONE@__MEDIA_PLATFORM_SRC_OBJECTS_1 =
@COND_TOOLKIT_PM@__MEDIA_PLATFORM_SRC_OBJECTS_1 =
@COND_TOOLKIT_WINCE@__MEDIA_PLATFORM_SRC_OBJECTS_1 = \
@COND_TOOLKIT_OSX_IPHONE@__MEDIA_PLATFORM_SRC_OBJECTS_1 =
@COND_TOOLKIT_PM@__MEDIA_PLATFORM_SRC_OBJECTS_1 =
@COND_TOOLKIT_WINCE@__MEDIA_PLATFORM_SRC_OBJECTS_1 = \
@COND_USE_SOVERSOLARIS_1@__mediadll___so_symlinks_uninst_cmd = $(COND_USE_SOVERSOLARIS_1___mediadll___so_symlinks_uninst_cmd)
@COND_PLATFORM_WIN32_1@__mediadll___win32rc = mediadll_version_rc.o
@COND_TOOLKIT_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS_2 = \
@COND_USE_SOVERSOLARIS_1@__mediadll___so_symlinks_uninst_cmd = $(COND_USE_SOVERSOLARIS_1___mediadll___so_symlinks_uninst_cmd)
@COND_PLATFORM_WIN32_1@__mediadll___win32rc = mediadll_version_rc.o
@COND_TOOLKIT_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS_2 = \
-@COND_TOOLKIT_COCOA@ mediadll_cocoa_mediactrl.o
+@COND_TOOLKIT_COCOA@ mediadll_src_cocoa_mediactrl.o
@COND_TOOLKIT_GTK@__MEDIA_PLATFORM_SRC_OBJECTS_2 = \
@COND_TOOLKIT_GTK@ mediadll_unix_mediactrl.o
@COND_TOOLKIT_MOTIF@__MEDIA_PLATFORM_SRC_OBJECTS_2 = \
@COND_TOOLKIT_GTK@__MEDIA_PLATFORM_SRC_OBJECTS_2 = \
@COND_TOOLKIT_GTK@ mediadll_unix_mediactrl.o
@COND_TOOLKIT_MOTIF@__MEDIA_PLATFORM_SRC_OBJECTS_2 = \
@COND_TOOLKIT_MSW@__MEDIA_PLATFORM_SRC_OBJECTS_2 = $(COND_TOOLKIT_MSW___MEDIA_PLATFORM_SRC_OBJECTS_2)
@COND_TOOLKIT_OSX_CARBON@__MEDIA_PLATFORM_SRC_OBJECTS_2 \
@COND_TOOLKIT_OSX_CARBON@ = mediadll_carbon_mediactrl.o
@COND_TOOLKIT_MSW@__MEDIA_PLATFORM_SRC_OBJECTS_2 = $(COND_TOOLKIT_MSW___MEDIA_PLATFORM_SRC_OBJECTS_2)
@COND_TOOLKIT_OSX_CARBON@__MEDIA_PLATFORM_SRC_OBJECTS_2 \
@COND_TOOLKIT_OSX_CARBON@ = mediadll_carbon_mediactrl.o
-@COND_TOOLKIT_OSX_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS_2 =
+@COND_TOOLKIT_OSX_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS_2 \
+@COND_TOOLKIT_OSX_COCOA@ = mediadll_osx_cocoa_mediactrl.o
@COND_TOOLKIT_OSX_IPHONE@__MEDIA_PLATFORM_SRC_OBJECTS_2 =
@COND_TOOLKIT_PM@__MEDIA_PLATFORM_SRC_OBJECTS_2 =
@COND_TOOLKIT_WINCE@__MEDIA_PLATFORM_SRC_OBJECTS_2 = \
@COND_TOOLKIT_OSX_IPHONE@__MEDIA_PLATFORM_SRC_OBJECTS_2 =
@COND_TOOLKIT_PM@__MEDIA_PLATFORM_SRC_OBJECTS_2 =
@COND_TOOLKIT_WINCE@__MEDIA_PLATFORM_SRC_OBJECTS_2 = \
@COND_USE_PCH_1@_____pch_wxprec_medialib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_medialib/wx/wxprec.h.gch
@COND_TOOLKIT_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS_3 = \
@COND_USE_PCH_1@_____pch_wxprec_medialib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_medialib/wx/wxprec.h.gch
@COND_TOOLKIT_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS_3 = \
-@COND_TOOLKIT_COCOA@ medialib_cocoa_mediactrl.o
+@COND_TOOLKIT_COCOA@ medialib_src_cocoa_mediactrl.o
@COND_TOOLKIT_GTK@__MEDIA_PLATFORM_SRC_OBJECTS_3 = \
@COND_TOOLKIT_GTK@ medialib_unix_mediactrl.o
@COND_TOOLKIT_MOTIF@__MEDIA_PLATFORM_SRC_OBJECTS_3 = \
@COND_TOOLKIT_GTK@__MEDIA_PLATFORM_SRC_OBJECTS_3 = \
@COND_TOOLKIT_GTK@ medialib_unix_mediactrl.o
@COND_TOOLKIT_MOTIF@__MEDIA_PLATFORM_SRC_OBJECTS_3 = \
@COND_TOOLKIT_MSW@__MEDIA_PLATFORM_SRC_OBJECTS_3 = $(COND_TOOLKIT_MSW___MEDIA_PLATFORM_SRC_OBJECTS_3)
@COND_TOOLKIT_OSX_CARBON@__MEDIA_PLATFORM_SRC_OBJECTS_3 \
@COND_TOOLKIT_OSX_CARBON@ = medialib_carbon_mediactrl.o
@COND_TOOLKIT_MSW@__MEDIA_PLATFORM_SRC_OBJECTS_3 = $(COND_TOOLKIT_MSW___MEDIA_PLATFORM_SRC_OBJECTS_3)
@COND_TOOLKIT_OSX_CARBON@__MEDIA_PLATFORM_SRC_OBJECTS_3 \
@COND_TOOLKIT_OSX_CARBON@ = medialib_carbon_mediactrl.o
-@COND_TOOLKIT_OSX_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS_3 =
+@COND_TOOLKIT_OSX_COCOA@__MEDIA_PLATFORM_SRC_OBJECTS_3 \
+@COND_TOOLKIT_OSX_COCOA@ = medialib_osx_cocoa_mediactrl.o
@COND_TOOLKIT_OSX_IPHONE@__MEDIA_PLATFORM_SRC_OBJECTS_3 =
@COND_TOOLKIT_PM@__MEDIA_PLATFORM_SRC_OBJECTS_3 =
@COND_TOOLKIT_WINCE@__MEDIA_PLATFORM_SRC_OBJECTS_3 = \
@COND_TOOLKIT_OSX_IPHONE@__MEDIA_PLATFORM_SRC_OBJECTS_3 =
@COND_TOOLKIT_PM@__MEDIA_PLATFORM_SRC_OBJECTS_3 =
@COND_TOOLKIT_WINCE@__MEDIA_PLATFORM_SRC_OBJECTS_3 = \
monodll_carbon_mediactrl.o: $(srcdir)/src/osx/carbon/mediactrl.cpp $(MONODLL_ODEP)
$(CXXC) -c -o $@ $(MONODLL_CXXFLAGS) $(srcdir)/src/osx/carbon/mediactrl.cpp
monodll_carbon_mediactrl.o: $(srcdir)/src/osx/carbon/mediactrl.cpp $(MONODLL_ODEP)
$(CXXC) -c -o $@ $(MONODLL_CXXFLAGS) $(srcdir)/src/osx/carbon/mediactrl.cpp
-monodll_cocoa_mediactrl.o: $(srcdir)/src/cocoa/mediactrl.mm $(MONODLL_ODEP)
+monodll_osx_cocoa_mediactrl.o: $(srcdir)/src/osx/cocoa/mediactrl.mm $(MONODLL_ODEP)
+ $(CXXC) -c -o $@ $(MONODLL_OBJCXXFLAGS) $(srcdir)/src/osx/cocoa/mediactrl.mm
+
+monodll_src_cocoa_mediactrl.o: $(srcdir)/src/cocoa/mediactrl.mm $(MONODLL_ODEP)
$(CXXC) -c -o $@ $(MONODLL_OBJCXXFLAGS) $(srcdir)/src/cocoa/mediactrl.mm
monodll_helpbest.o: $(srcdir)/src/msw/helpbest.cpp $(MONODLL_ODEP)
$(CXXC) -c -o $@ $(MONODLL_OBJCXXFLAGS) $(srcdir)/src/cocoa/mediactrl.mm
monodll_helpbest.o: $(srcdir)/src/msw/helpbest.cpp $(MONODLL_ODEP)
monolib_carbon_mediactrl.o: $(srcdir)/src/osx/carbon/mediactrl.cpp $(MONOLIB_ODEP)
$(CXXC) -c -o $@ $(MONOLIB_CXXFLAGS) $(srcdir)/src/osx/carbon/mediactrl.cpp
monolib_carbon_mediactrl.o: $(srcdir)/src/osx/carbon/mediactrl.cpp $(MONOLIB_ODEP)
$(CXXC) -c -o $@ $(MONOLIB_CXXFLAGS) $(srcdir)/src/osx/carbon/mediactrl.cpp
-monolib_cocoa_mediactrl.o: $(srcdir)/src/cocoa/mediactrl.mm $(MONOLIB_ODEP)
+monolib_osx_cocoa_mediactrl.o: $(srcdir)/src/osx/cocoa/mediactrl.mm $(MONOLIB_ODEP)
+ $(CXXC) -c -o $@ $(MONOLIB_OBJCXXFLAGS) $(srcdir)/src/osx/cocoa/mediactrl.mm
+
+monolib_src_cocoa_mediactrl.o: $(srcdir)/src/cocoa/mediactrl.mm $(MONOLIB_ODEP)
$(CXXC) -c -o $@ $(MONOLIB_OBJCXXFLAGS) $(srcdir)/src/cocoa/mediactrl.mm
monolib_helpbest.o: $(srcdir)/src/msw/helpbest.cpp $(MONOLIB_ODEP)
$(CXXC) -c -o $@ $(MONOLIB_OBJCXXFLAGS) $(srcdir)/src/cocoa/mediactrl.mm
monolib_helpbest.o: $(srcdir)/src/msw/helpbest.cpp $(MONOLIB_ODEP)
mediadll_carbon_mediactrl.o: $(srcdir)/src/osx/carbon/mediactrl.cpp $(MEDIADLL_ODEP)
$(CXXC) -c -o $@ $(MEDIADLL_CXXFLAGS) $(srcdir)/src/osx/carbon/mediactrl.cpp
mediadll_carbon_mediactrl.o: $(srcdir)/src/osx/carbon/mediactrl.cpp $(MEDIADLL_ODEP)
$(CXXC) -c -o $@ $(MEDIADLL_CXXFLAGS) $(srcdir)/src/osx/carbon/mediactrl.cpp
-mediadll_cocoa_mediactrl.o: $(srcdir)/src/cocoa/mediactrl.mm $(MEDIADLL_ODEP)
+mediadll_osx_cocoa_mediactrl.o: $(srcdir)/src/osx/cocoa/mediactrl.mm $(MEDIADLL_ODEP)
+ $(CXXC) -c -o $@ $(MEDIADLL_OBJCXXFLAGS) $(srcdir)/src/osx/cocoa/mediactrl.mm
+
+mediadll_src_cocoa_mediactrl.o: $(srcdir)/src/cocoa/mediactrl.mm $(MEDIADLL_ODEP)
$(CXXC) -c -o $@ $(MEDIADLL_OBJCXXFLAGS) $(srcdir)/src/cocoa/mediactrl.mm
@COND_TOOLKIT_MSW@mediadll_mediactrl_am.o: $(srcdir)/src/msw/mediactrl_am.cpp $(MEDIADLL_ODEP)
$(CXXC) -c -o $@ $(MEDIADLL_OBJCXXFLAGS) $(srcdir)/src/cocoa/mediactrl.mm
@COND_TOOLKIT_MSW@mediadll_mediactrl_am.o: $(srcdir)/src/msw/mediactrl_am.cpp $(MEDIADLL_ODEP)
medialib_carbon_mediactrl.o: $(srcdir)/src/osx/carbon/mediactrl.cpp $(MEDIALIB_ODEP)
$(CXXC) -c -o $@ $(MEDIALIB_CXXFLAGS) $(srcdir)/src/osx/carbon/mediactrl.cpp
medialib_carbon_mediactrl.o: $(srcdir)/src/osx/carbon/mediactrl.cpp $(MEDIALIB_ODEP)
$(CXXC) -c -o $@ $(MEDIALIB_CXXFLAGS) $(srcdir)/src/osx/carbon/mediactrl.cpp
-medialib_cocoa_mediactrl.o: $(srcdir)/src/cocoa/mediactrl.mm $(MEDIALIB_ODEP)
+medialib_osx_cocoa_mediactrl.o: $(srcdir)/src/osx/cocoa/mediactrl.mm $(MEDIALIB_ODEP)
+ $(CXXC) -c -o $@ $(MEDIALIB_OBJCXXFLAGS) $(srcdir)/src/osx/cocoa/mediactrl.mm
+
+medialib_src_cocoa_mediactrl.o: $(srcdir)/src/cocoa/mediactrl.mm $(MEDIALIB_ODEP)
$(CXXC) -c -o $@ $(MEDIALIB_OBJCXXFLAGS) $(srcdir)/src/cocoa/mediactrl.mm
@COND_TOOLKIT_MSW@medialib_mediactrl_am.o: $(srcdir)/src/msw/mediactrl_am.cpp $(MEDIALIB_ODEP)
$(CXXC) -c -o $@ $(MEDIALIB_OBJCXXFLAGS) $(srcdir)/src/cocoa/mediactrl.mm
@COND_TOOLKIT_MSW@medialib_mediactrl_am.o: $(srcdir)/src/msw/mediactrl_am.cpp $(MEDIALIB_ODEP)
</set>
<set var="MEDIA_OSX_COCOA_SRC" hints="files">
</set>
<set var="MEDIA_OSX_COCOA_SRC" hints="files">
- <!-- src/osx/cocoa/mediactrl.mm -->
+ src/osx/cocoa/mediactrl.mm
</set>
<set var="MEDIA_OSX_COCOA_HDR" hints="files">
</set>
</set>
<set var="MEDIA_OSX_COCOA_HDR" hints="files">
</set>
+
+ elif test "$wxUSE_MAC" = 1; then
+ GST_LIBS="-framework QTKit"
fi
if test $USE_MEDIA = 1; then
fi
if test $USE_MEDIA = 1; then
+
+ elif test "$wxUSE_MAC" = 1; then
+ dnl We always have the necessary libraries under Mac
+ dnl but we need to link with it explicitly.
+ GST_LIBS="-framework QTKit"
fi
if test $USE_MEDIA = 1; then
fi
if test $USE_MEDIA = 1; then
#include "wx/cocoa/autorelease.h"
#include "wx/cocoa/string.h"
#include "wx/cocoa/autorelease.h"
#include "wx/cocoa/string.h"
-#import <AppKit/NSMovie.h>
-#import <AppKit/NSMovieView.h>
-
class WXDLLIMPEXP_FWD_MEDIA wxQTMediaBackend;
@interface wxQTMovie : QTMovie {
class WXDLLIMPEXP_FWD_MEDIA wxQTMediaBackend;
@interface wxQTMovie : QTMovie {
--(void)loadStateChanged:(QTMovie *)movie
+-(void)loadStateChanged:(NSNotification *)notification
+ QTMovie *movie = [notification object];
long loadState = [[movie attributeForKey:QTMovieLoadStateAttribute] longValue];
if (loadState >= QTMovieLoadStatePlayable)
{
long loadState = [[movie attributeForKey:QTMovieLoadStateAttribute] longValue];
if (loadState >= QTMovieLoadStatePlayable)
{
bool wxQTMediaBackend::Load(const wxURI& location)
{
wxCFStringRef uri(location.BuildURI());
bool wxQTMediaBackend::Load(const wxURI& location)
{
wxCFStringRef uri(location.BuildURI());
-
- [m_movie release];
- wxQTMovie* movie = [[wxQTMovie alloc] initWithURL: [NSURL URLWithString: uri.AsNSString()] error: nil ];
+ NSURL *url = [NSURL URLWithString: uri.AsNSString()];
+
+ if (! [wxQTMovie canInitWithURL:url])
+ return false;
+ [m_movie release];
+ wxQTMovie* movie = [[wxQTMovie alloc] initWithURL:url error: nil ];
+
- [m_movie setBackend:this];
- [m_movieview setMovie:movie];
+ if (movie != nil)
+ {
+ [m_movie setBackend:this];
+ [m_movieview setMovie:movie];
+
+ // If the media file is able to be loaded quickly then there may not be
+ // any QTMovieLoadStateDidChangeNotification message sent, so we need to
+ // also check the load state here and finish our initialization if it has
+ // been loaded.
+ long loadState = [[m_movie attributeForKey:QTMovieLoadStateAttribute] longValue];
+ if (loadState >= QTMovieLoadStateLoaded)
+ {
+ FinishLoad();
+ }
+ }
{
DoShowPlayerControls(m_interfaceflags);
{
DoShowPlayerControls(m_interfaceflags);
- NSRect r =[m_movieview movieBounds];
- m_bestSize.x = r.size.width;
- m_bestSize.y = r.size.height;
+ NSSize s = [[m_movie attributeForKey:QTMovieNaturalSizeAttribute] sizeValue];
+ m_bestSize = wxSize(s.width, s.height);
}
bool wxQTMediaBackend::Play()
}
bool wxQTMediaBackend::Play()