You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openoffice.apache.org by ar...@apache.org on 2019/10/21 01:27:41 UTC

[openoffice] branch AOO418 updated (fe14547 -> 300bfcc)

This is an automated email from the ASF dual-hosted git repository.

arielch pushed a change to branch AOO418
in repository https://gitbox.apache.org/repos/asf/openoffice.git.


    from fe14547  Replaced Orb in options dialog with flat one
     new 95ea275  #i124875# support Mac AV-Foundation API for multimedia content
     new 4ba1660  #i124875# avoid avmedia build problems with multiple active backends
     new 6a7d45e  #i124875# avoid wasteful loading of an AVAsset in MacAVF::Framegrabber
     new 9c30ce9  #i124875# pre-register the Mac AVFoundation component
     new deea6bb  #i124875# use AVAsset's best guess duration if AVPlayerItem isn't ready yet
     new fcb37b4  i127138 Remove the avmedia Quicktime plugin
     new e2b2186  Avoid ordered comparison between pointer and zero
     new 300bfcc  Ensure correct casting

The 8 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 main/avmedia/prj/build.lst                         |   4 +-
 main/avmedia/prj/d.lst                             |   3 +-
 main/avmedia/source/inc/mediamisc.hxx              |   2 +-
 .../avmediaMacAVF.component}                       |   4 +-
 .../macavf_common.hxx}                             |  47 ++-
 .../macavf_framegrabber.cxx}                       | 110 ++---
 .../macavf_framegrabber.hxx}                       |  27 +-
 .../macavf_macavfcommon.hxx}                       |  47 ++-
 .../macavf_macavfuno.cxx}                          |  13 +-
 .../manager.cxx => macavf/macavf_manager.cxx}      |  23 +-
 .../manager.hxx => macavf/macavf_manager.hxx}      |  17 +-
 main/avmedia/source/macavf/macavf_player.cxx       | 463 +++++++++++++++++++++
 .../player.hxx => macavf/macavf_player.hxx}        |  82 ++--
 .../quicktimeuno.cxx => macavf/macavf_uno.cxx}     |  13 +-
 .../window.cxx => macavf/macavf_window.cxx}        | 158 ++++---
 .../window.hxx => macavf/macavf_window.hxx}        |  39 +-
 .../source/{quicktime => macavf}/makefile.mk       |  33 +-
 main/avmedia/source/quicktime/player.cxx           | 460 --------------------
 main/desktop/source/app/officeipcthread.cxx        |   2 +-
 main/desktop/source/deployment/misc/dp_misc.cxx    |   2 +-
 main/postprocess/packcomponents/makefile.mk        |   2 +-
 main/scp2/source/ooo/file_library_ooo.scp          |   5 +-
 main/sd/source/ui/view/viewshe3.cxx                |   2 +-
 main/vcl/Library_vcl.mk                            |   3 -
 main/vcl/aqua/source/dtrans/OSXTransferable.cxx    |   6 +-
 main/vcl/aqua/source/dtrans/PictToBmpFlt.cxx       |   1 -
 main/vcl/util/makefile.mk                          |   5 -
 27 files changed, 795 insertions(+), 778 deletions(-)
 rename main/avmedia/source/{quicktime/avmediaQuickTime.component => macavf/avmediaMacAVF.component} (89%)
 copy main/avmedia/source/{quicktime/quicktimecommon.hxx => macavf/macavf_common.hxx} (56%)
 rename main/avmedia/source/{quicktime/framegrabber.cxx => macavf/macavf_framegrabber.cxx} (54%)
 rename main/avmedia/source/{quicktime/framegrabber.hxx => macavf/macavf_framegrabber.hxx} (75%)
 rename main/avmedia/source/{quicktime/quicktimecommon.hxx => macavf/macavf_macavfcommon.hxx} (56%)
 copy main/avmedia/source/{quicktime/quicktimeuno.cxx => macavf/macavf_macavfuno.cxx} (85%)
 rename main/avmedia/source/{quicktime/manager.cxx => macavf/macavf_manager.cxx} (88%)
 rename main/avmedia/source/{quicktime/manager.hxx => macavf/macavf_manager.hxx} (90%)
 create mode 100644 main/avmedia/source/macavf/macavf_player.cxx
 rename main/avmedia/source/{quicktime/player.hxx => macavf/macavf_player.hxx} (56%)
 rename main/avmedia/source/{quicktime/quicktimeuno.cxx => macavf/macavf_uno.cxx} (85%)
 rename main/avmedia/source/{quicktime/window.cxx => macavf/macavf_window.cxx} (75%)
 rename main/avmedia/source/{quicktime/window.hxx => macavf/macavf_window.hxx} (88%)
 rename main/avmedia/source/{quicktime => macavf}/makefile.mk (72%)
 delete mode 100644 main/avmedia/source/quicktime/player.cxx


[openoffice] 03/08: #i124875# avoid wasteful loading of an AVAsset in MacAVF::Framegrabber

Posted by ar...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

arielch pushed a commit to branch AOO418
in repository https://gitbox.apache.org/repos/asf/openoffice.git

commit 6a7d45efb49169f8345719aa163722d8b8f2c22f
Author: Herbert Dürr <hd...@apache.org>
AuthorDate: Mon May 12 16:07:09 2014 +0000

    #i124875# avoid wasteful loading of an AVAsset in MacAVF::Framegrabber
    
    FrameGrabber used to load its own copy of a movie. Since multimedia content
    is often very data-intensive this should and can be avoided by using the
    movie asset already available in the Player.
    
    
    git-svn-id: https://svn.apache.org/repos/asf/openoffice/trunk@1594017 13f79535-47bb-0310-9956-ffa450edef68
    (cherry picked from commit 32322404843edfd777f7b843f7e0e2e38f46fabf)
---
 main/avmedia/source/macavf/macavf_framegrabber.cxx | 12 ++++++++---
 main/avmedia/source/macavf/macavf_framegrabber.hxx |  1 +
 main/avmedia/source/macavf/macavf_player.cxx       | 23 ++++------------------
 main/avmedia/source/macavf/macavf_player.hxx       |  4 +---
 4 files changed, 15 insertions(+), 25 deletions(-)

diff --git a/main/avmedia/source/macavf/macavf_framegrabber.cxx b/main/avmedia/source/macavf/macavf_framegrabber.cxx
index f9fb5a6..df5d9f9 100644
--- a/main/avmedia/source/macavf/macavf_framegrabber.cxx
+++ b/main/avmedia/source/macavf/macavf_framegrabber.cxx
@@ -51,8 +51,6 @@ FrameGrabber::~FrameGrabber()
 
 bool FrameGrabber::create( const ::rtl::OUString& rURL )
 {
-    // TODO: use AVPlayer's movie directly instead of loading it here?
-
     NSString* pNSStr = [NSString stringWithCharacters:rURL.getStr() length:rURL.getLength()];
     NSURL* pNSURL = [NSURL URLWithString: [pNSStr stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding]];
     AVAsset* pMovie = [AVURLAsset URLAssetWithURL:pNSURL options:nil];
@@ -61,9 +59,17 @@ bool FrameGrabber::create( const ::rtl::OUString& rURL )
         OSL_TRACE( "AVGrabber::create() cannot load url=\"%s\"", [pNSStr UTF8String] );
         return false;
     }
+
+    return create( pMovie );
+}
+
+// ------------------------------------------------------------------------------
+
+bool FrameGrabber::create( AVAsset* pMovie )
+{
     if( [[pMovie tracksWithMediaType:AVMediaTypeVideo] count] == 0)
     {
-        OSL_TRACE( "AVGrabber::create() found no video in url=\"%s\"", [pNSStr UTF8String] );
+        OSL_TRACE( "AVGrabber::create() found no video content!" );
         return false;
     }
 
diff --git a/main/avmedia/source/macavf/macavf_framegrabber.hxx b/main/avmedia/source/macavf/macavf_framegrabber.hxx
index c483eda..24c42c6 100644
--- a/main/avmedia/source/macavf/macavf_framegrabber.hxx
+++ b/main/avmedia/source/macavf/macavf_framegrabber.hxx
@@ -42,6 +42,7 @@ public:
     virtual  ~FrameGrabber();
 
     bool    create( const ::rtl::OUString& rURL );
+    bool    create( AVAsset* pMovie );
 
     // XFrameGrabber
     virtual ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic > SAL_CALL grabFrame( double fMediaTime ) throw (::com::sun::star::uno::RuntimeException);
diff --git a/main/avmedia/source/macavf/macavf_player.cxx b/main/avmedia/source/macavf/macavf_player.cxx
index 27fd644..34c76d4 100644
--- a/main/avmedia/source/macavf/macavf_player.cxx
+++ b/main/avmedia/source/macavf/macavf_player.cxx
@@ -112,17 +112,6 @@ Player::~Player()
 
 // ------------------------------------------------------------------------------
 
-AVAsset* Player::getMovie()
-{
-    if( !mpPlayer )
-        return nil;
-    AVAsset* pMovie = [[mpPlayer currentItem] asset];
-    OSL_ASSERT( pMovie ); 
-    return pMovie;
-}
-
-// ------------------------------------------------------------------------------
-
 bool Player::handleObservation( NSString* pKeyPath )
 {
     OSL_TRACE( "AVPlayer::handleObservation key=\"%s\"", [pKeyPath UTF8String]);
@@ -139,8 +128,6 @@ bool Player::handleObservation( NSString* pKeyPath )
 
 bool Player::create( const ::rtl::OUString& rURL )
 {
-    maURL = rURL;
-
     // get the media asset
     NSString* aNSStr = [NSString stringWithCharacters:rURL.getStr() length:rURL.getLength()];
     NSURL* aNSURL = [NSURL URLWithString: [aNSStr stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding]];
@@ -433,12 +420,10 @@ uno::Reference< media::XFrameGrabber > SAL_CALL Player::createFrameGrabber()
     uno::Reference< media::XFrameGrabber > xRet;
     OSL_TRACE ("Player::createFrameGrabber");
 
-    if( !maURL.isEmpty() )
-    {
-        FrameGrabber* pGrabber = new FrameGrabber( mxMgr );
-        if( pGrabber->create( maURL ) )
-            xRet = pGrabber;
-    }
+    FrameGrabber* pGrabber = new FrameGrabber( mxMgr );
+    AVAsset* pMovie = [[mpPlayer currentItem] asset];
+    if( pGrabber->create( pMovie ) )
+        xRet = pGrabber;
 
     return xRet;
 }
diff --git a/main/avmedia/source/macavf/macavf_player.hxx b/main/avmedia/source/macavf/macavf_player.hxx
index 45f6f86..05c5220 100644
--- a/main/avmedia/source/macavf/macavf_player.hxx
+++ b/main/avmedia/source/macavf/macavf_player.hxx
@@ -46,6 +46,7 @@ public:
     virtual  ~Player();
 
     bool create( const ::rtl::OUString& rURL );
+    bool create( AVAsset* );
 
     // XPlayer
     virtual void SAL_CALL start() throw (::com::sun::star::uno::RuntimeException);
@@ -72,15 +73,12 @@ public:
     virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException);
     virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames(  ) throw (::com::sun::star::uno::RuntimeException);
  
-    AVAsset* getMovie();
     AVPlayer* getAVPlayer() const { return mpPlayer; }
     virtual bool handleObservation( NSString* pKeyPath );
 
 private:
     ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > mxMgr;
 
-    ::rtl::OUString     maURL;
-    
     AVPlayer*           mpPlayer;
 
     float               mfUnmutedVolume;


[openoffice] 01/08: #i124875# support Mac AV-Foundation API for multimedia content

Posted by ar...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

arielch pushed a commit to branch AOO418
in repository https://gitbox.apache.org/repos/asf/openoffice.git

commit 95ea2752778b7dc1604587fd3fb48734ef686251
Author: Herbert Dürr <hd...@apache.org>
AuthorDate: Mon May 12 13:39:08 2014 +0000

    #i124875# support Mac AV-Foundation API for multimedia content
    
    
    git-svn-id: https://svn.apache.org/repos/asf/openoffice/trunk@1593965 13f79535-47bb-0310-9956-ffa450edef68
    (cherry picked from commit eb7664d6c5c9be8a69ece33db9cd896580c512b8)
---
 main/avmedia/prj/build.lst                         |   1 +
 main/avmedia/prj/d.lst                             |   2 +
 main/avmedia/source/inc/mediamisc.hxx              |   2 +-
 main/avmedia/source/macavf/avmediaMacAVF.component |  28 ++
 main/avmedia/source/macavf/framegrabber.cxx        | 137 ++++++
 main/avmedia/source/macavf/framegrabber.hxx        |  66 +++
 main/avmedia/source/macavf/macavfcommon.hxx        |  89 ++++
 main/avmedia/source/macavf/macavfuno.cxx           |  71 +++
 main/avmedia/source/macavf/makefile.mk             |  89 ++++
 main/avmedia/source/macavf/manager.cxx             |  90 ++++
 main/avmedia/source/macavf/manager.hxx             |  59 +++
 main/avmedia/source/macavf/player.cxx              | 475 +++++++++++++++++++++
 main/avmedia/source/macavf/player.hxx              |  97 +++++
 main/avmedia/source/macavf/window.cxx              | 342 +++++++++++++++
 main/avmedia/source/macavf/window.hxx              | 123 ++++++
 main/scp2/source/ooo/file_library_ooo.scp          |   8 +
 16 files changed, 1678 insertions(+), 1 deletion(-)

diff --git a/main/avmedia/prj/build.lst b/main/avmedia/prj/build.lst
index 7d9343b..6b4ba9c 100644
--- a/main/avmedia/prj/build.lst
+++ b/main/avmedia/prj/build.lst
@@ -7,5 +7,6 @@ av  avmedia\source\framework	nmake	-	all	av_framework	        								NULL
 av  avmedia\source\win	    	nmake	-	all	av_win	            									NULL
 av	avmedia\source\java			nmake	-	all	av_java	            									NULL
 av	avmedia\source\quicktime	nmake	-	all	av_quicktime											NULL
+av	avmedia\source\macavf	nmake	-	all	av_macavf											NULL
 av	avmedia\source\gstreamer	nmake	-	all	av_gstreamer	            							NULL
 av	avmedia\util				nmake	-	all	av_util av_viewer av_framework av_win av_java av_quicktime av_gstreamer	NULL
diff --git a/main/avmedia/prj/d.lst b/main/avmedia/prj/d.lst
index eb140ed..86c6119 100644
--- a/main/avmedia/prj/d.lst
+++ b/main/avmedia/prj/d.lst
@@ -19,5 +19,7 @@ mkdir: %_DEST%\inc%_EXT%\avmedia
 ..\%__SRC%\misc\avmedia.component %_DEST%\xml%_EXT%\avmedia.component
 ..\%__SRC%\misc\avmedia.jar.component %_DEST%\xml%_EXT%\avmedia.jar.component
 ..\%__SRC%\misc\avmediaQuickTime.component %_DEST%\xml%_EXT%\avmediaQuickTime.component
+..\%__SRC%\misc\avmediaMacAVF.component %_DEST%\xml%_EXT%\avmediaMacAVF.component
 ..\%__SRC%\misc\avmediagst.component %_DEST%\xml%_EXT%\avmediagst.component
 ..\%__SRC%\misc\avmediawin.component %_DEST%\xml%_EXT%\avmediawin.component
+
diff --git a/main/avmedia/source/inc/mediamisc.hxx b/main/avmedia/source/inc/mediamisc.hxx
index 03a8fbf..5a4a276 100644
--- a/main/avmedia/source/inc/mediamisc.hxx
+++ b/main/avmedia/source/inc/mediamisc.hxx
@@ -39,7 +39,7 @@ class ResMgr;
 #define AVMEDIA_MANAGER_SERVICE_NAME                    "com.sun.star.comp.avmedia.Manager_QuickTime"
 #define AVMEDIA_MANAGER_SERVICE_IS_JAVABASED            sal_False
 
-#define AVMEDIA_MANAGER_SERVICE_NAME_FALLBACK1           ""
+#define AVMEDIA_MANAGER_SERVICE_NAME_FALLBACK1           "com.sun.star.comp.avmedia.Manager_MacAVF"
 #define AVMEDIA_MANAGER_SERVICE_IS_JAVABASED_FALLBACK1  sal_False
 
 #else
diff --git a/main/avmedia/source/macavf/avmediaMacAVF.component b/main/avmedia/source/macavf/avmediaMacAVF.component
new file mode 100644
index 0000000..6485b70
--- /dev/null
+++ b/main/avmedia/source/macavf/avmediaMacAVF.component
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--***********************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ ***********************************************************-->
+
+<component loader="com.sun.star.loader.SharedLibrary"
+    xmlns="http://openoffice.org/2010/uno-components">
+  <implementation name="com.sun.star.comp.avmedia.Manager_MacAVF">
+    <service name="com.sun.star.media.Manager_MacAVF"/>
+  </implementation>
+</component>
diff --git a/main/avmedia/source/macavf/framegrabber.cxx b/main/avmedia/source/macavf/framegrabber.cxx
new file mode 100644
index 0000000..1129b90
--- /dev/null
+++ b/main/avmedia/source/macavf/framegrabber.cxx
@@ -0,0 +1,137 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#include "framegrabber.hxx"
+#include "player.hxx"
+
+#include <tools/stream.hxx>
+#include <vcl/graph.hxx>
+#include <vcl/cvtgrf.hxx>
+#include <unotools/localfilehelper.hxx>
+
+using namespace ::com::sun::star;
+
+namespace avmedia { namespace macavf {
+
+// ----------------
+// - FrameGrabber -
+// ----------------
+
+FrameGrabber::FrameGrabber( const uno::Reference< lang::XMultiServiceFactory >& /*rxMgr*/ )
+:   mpImageGen( NULL )
+{}
+
+// ------------------------------------------------------------------------------
+
+FrameGrabber::~FrameGrabber()
+{
+    if( mpImageGen )
+        CFRelease( mpImageGen );
+}
+
+// ------------------------------------------------------------------------------
+
+bool FrameGrabber::create( const ::rtl::OUString& rURL )
+{
+    // TODO: use AVPlayer's movie directly instead of loading it here?
+
+    NSString* pNSStr = [NSString stringWithCharacters:rURL.getStr() length:rURL.getLength()];
+    NSURL* pNSURL = [NSURL URLWithString: [pNSStr stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding]];
+    AVAsset* pMovie = [AVURLAsset URLAssetWithURL:pNSURL options:nil];
+    if( !pMovie )
+    {
+        OSL_TRACE( "AVGrabber::create() cannot load url=\"%s\"", [pNSStr UTF8String] );
+        return false;
+    }
+    if( [[pMovie tracksWithMediaType:AVMediaTypeVideo] count] == 0)
+    {
+        OSL_TRACE( "AVGrabber::create() found no video in url=\"%s\"", [pNSStr UTF8String] );
+        return false;
+    }
+
+    mpImageGen = [AVAssetImageGenerator assetImageGeneratorWithAsset:pMovie];
+    CFRetain( mpImageGen );
+    return true;
+}
+
+// ------------------------------------------------------------------------------
+
+uno::Reference< graphic::XGraphic > SAL_CALL FrameGrabber::grabFrame( double fMediaTime )
+    throw (uno::RuntimeException)
+{
+    uno::Reference< graphic::XGraphic > xRet;
+    if( !mpImageGen )
+        return xRet;
+    OSL_TRACE( "AVPlayer::grabFrame( %.3fsec)", fMediaTime );
+
+    // get the requested image from the movie
+    CGImage* pCGImage = [mpImageGen copyCGImageAtTime:CMTimeMakeWithSeconds(fMediaTime,1000) actualTime:NULL error:NULL];
+
+    // convert the image to a TIFF-formatted byte-array
+    CFMutableDataRef pCFData = CFDataCreateMutable( kCFAllocatorDefault, 0 );
+    CGImageDestination* pCGImgDest = CGImageDestinationCreateWithData( pCFData, kUTTypeTIFF, 1, 0 );
+    CGImageDestinationAddImage( pCGImgDest, pCGImage, NULL );
+    CGImageDestinationFinalize( pCGImgDest );
+    CFRelease( pCGImgDest );
+    const long nBitmapLen = CFDataGetLength( pCFData );
+    void* pBitmapBytes = (void*)CFDataGetBytePtr( pCFData );
+
+    // convert the image into the return-value type which is a graphic::XGraphic
+    SvMemoryStream aMemStm( pBitmapBytes, nBitmapLen, STREAM_READ | STREAM_WRITE );
+    Graphic aGraphic;
+    if( GraphicConverter::Import( aMemStm, aGraphic, CVT_TIF ) == ERRCODE_NONE )
+        xRet = aGraphic.GetXGraphic();
+
+    // clean up resources
+    CFRelease( pCFData );
+    return xRet;
+}
+
+// ------------------------------------------------------------------------------
+
+::rtl::OUString SAL_CALL FrameGrabber::getImplementationName(  )
+    throw (uno::RuntimeException)
+{
+    return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( AVMEDIA_MACAVF_FRAMEGRABBER_IMPLEMENTATIONNAME ) );
+}
+
+// ------------------------------------------------------------------------------
+
+sal_Bool SAL_CALL FrameGrabber::supportsService( const ::rtl::OUString& ServiceName )
+    throw (uno::RuntimeException)
+{
+    return ServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM ( AVMEDIA_MACAVF_FRAMEGRABBER_SERVICENAME ) );
+}
+
+// ------------------------------------------------------------------------------
+
+uno::Sequence< ::rtl::OUString > SAL_CALL FrameGrabber::getSupportedServiceNames(  )
+    throw (uno::RuntimeException)
+{
+    uno::Sequence< ::rtl::OUString > aRet(1);
+    aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( AVMEDIA_MACAVF_FRAMEGRABBER_SERVICENAME ) );
+
+    return aRet;
+}
+
+} // namespace macavf
+} // namespace avmedia
+
diff --git a/main/avmedia/source/macavf/framegrabber.hxx b/main/avmedia/source/macavf/framegrabber.hxx
new file mode 100644
index 0000000..bcc095d
--- /dev/null
+++ b/main/avmedia/source/macavf/framegrabber.hxx
@@ -0,0 +1,66 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+
+
+#ifndef _FRAMEGRABBER_HXX
+#define _FRAMEGRABBER_HXX
+
+#include "macavfcommon.hxx"
+
+#include "com/sun/star/media/XFrameGrabber.hdl"
+
+namespace avmedia { namespace macavf {
+
+// ----------------
+// - FrameGrabber -
+// ----------------
+
+class FrameGrabber : public ::cppu::WeakImplHelper2 < ::com::sun::star::media::XFrameGrabber,
+                                                      ::com::sun::star::lang::XServiceInfo >
+{
+public:
+
+    explicit FrameGrabber( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& );
+    virtual  ~FrameGrabber();
+
+    bool    create( const ::rtl::OUString& rURL );
+
+    // XFrameGrabber
+    virtual ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic > SAL_CALL grabFrame( double fMediaTime ) throw (::com::sun::star::uno::RuntimeException);
+
+    // XServiceInfo
+    virtual ::rtl::OUString SAL_CALL getImplementationName(  ) throw (::com::sun::star::uno::RuntimeException);
+    virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException);
+    virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames(  ) throw (::com::sun::star::uno::RuntimeException);
+
+private:
+
+    ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >    mxMgr;
+
+    AVAssetImageGenerator* mpImageGen;
+};
+
+} // namespace macavf
+} // namespace avmedia
+
+#endif // _FRAMEGRABBER_HXX
+
diff --git a/main/avmedia/source/macavf/macavfcommon.hxx b/main/avmedia/source/macavf/macavfcommon.hxx
new file mode 100644
index 0000000..ba27e40
--- /dev/null
+++ b/main/avmedia/source/macavf/macavfcommon.hxx
@@ -0,0 +1,89 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef MACAVF_COMMON_HXX
+#define MACAVF_COMMON_HXX
+
+#ifdef MACOSX
+#include <premac.h>
+#import <Cocoa/Cocoa.h>
+#import <AVFoundation/AVFoundation.h>
+#include <postmac.h>
+#endif
+#include <osl/mutex.hxx>
+#include <rtl/ustring.hxx>
+#include <tools/debug.hxx>
+#include <tools/stream.hxx>
+#include <tools/string.hxx>
+#include <tools/urlobj.hxx>
+#include <cppuhelper/implbase1.hxx>
+#include <cppuhelper/implbase2.hxx>
+#include <cppuhelper/weak.hxx>
+#include <cppuhelper/factory.hxx>
+
+#include <com/sun/star/uno/Reference.h>
+#include <com/sun/star/uno/RuntimeException.hpp>
+#include <com/sun/star/lang/XMultiServiceFactory.hpp>
+#include <com/sun/star/lang/XComponent.hpp>
+#include <com/sun/star/registry/XRegistryKey.hpp>
+#include <com/sun/star/lang/XComponent.hpp>
+#include <com/sun/star/lang/XServiceInfo.hpp>
+#include <com/sun/star/awt/Rectangle.hpp>
+#include <com/sun/star/awt/KeyModifier.hpp>
+#include <com/sun/star/awt/MouseButton.hpp>
+#include <com/sun/star/media/XManager.hpp>
+
+
+#define AVMEDIA_MACAVF_MANAGER_IMPLEMENTATIONNAME "com.sun.star.comp.avmedia.Manager_MacAVF"
+#define AVMEDIA_MACAVF_MANAGER_SERVICENAME "com.sun.star.media.Manager_MacAVF"
+
+#define AVMEDIA_MACAVF_PLAYER_IMPLEMENTATIONNAME "com.sun.star.comp.avmedia.Player_MacAVF"
+#define AVMEDIA_MACAVF_PLAYER_SERVICENAME "com.sun.star.media.Player_MacAVF"
+
+#define AVMEDIA_MACAVF_WINDOW_IMPLEMENTATIONNAME "com.sun.star.comp.avmedia.Window_MacAVF"
+#define AVMEDIA_MACAVF_WINDOW_SERVICENAME "com.sun.star.media.Window_MacAVF"
+
+#define AVMEDIA_MACAVF_FRAMEGRABBER_IMPLEMENTATIONNAME "com.sun.star.comp.avmedia.FrameGrabber_MacAVF"
+#define AVMEDIA_MACAVF_FRAMEGRABBER_SERVICENAME "com.sun.star.media.FrameGrabber_MacAVF"
+
+
+// MacAVObserver handles the notifications used in the AVFoundation framework
+
+@interface MacAVObserverObject : NSObject
+- (void)observeValueForKeyPath:(NSString*)pKeyPath ofObject:(id)pObject change:(NSDictionary*)pChangeDict context:(void*)pContext;
+- (void)onNotification:(NSNotification*)pNotification;
+@end
+
+namespace avmedia { namespace macavf {
+
+class MacAVObserverHandler
+{
+private:
+    static MacAVObserverObject* mpMacAVObserverObject;
+public:
+    MacAVObserverObject* getObserver( void ) const;
+    virtual bool handleObservation( NSString* pKeyPath ) = 0;
+};
+
+}}
+
+#endif // MACAVF_COMMON_HXX
+
diff --git a/main/avmedia/source/macavf/macavfuno.cxx b/main/avmedia/source/macavf/macavfuno.cxx
new file mode 100644
index 0000000..acc0d93
--- /dev/null
+++ b/main/avmedia/source/macavf/macavfuno.cxx
@@ -0,0 +1,71 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#include "macavfcommon.hxx"
+#include "manager.hxx"
+
+using namespace ::com::sun::star;
+
+// -------------------
+// - factory methods -
+// -------------------
+
+static uno::Reference< uno::XInterface > SAL_CALL create_MediaPlayer( const uno::Reference< lang::XMultiServiceFactory >& rxFact )
+{
+	return uno::Reference< uno::XInterface >( *new ::avmedia::macavf::Manager( rxFact ) );
+}
+
+// ------------------------------------------
+// - component_getImplementationEnvironment -
+// ------------------------------------------
+
+extern "C" void SAL_CALL component_getImplementationEnvironment( const sal_Char ** ppEnvTypeName, uno_Environment ** /* ppEnv */ )
+{
+	*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
+}
+
+// ------------------------
+// - component_getFactory -
+// ------------------------
+
+extern "C" void* SAL_CALL component_getFactory( const sal_Char* pImplName, void* pServiceManager, void* /* pRegistryKey */ )
+{
+	uno::Reference< lang::XSingleServiceFactory > xFactory;
+	void*									pRet = 0;
+
+	if( rtl_str_compare( pImplName, AVMEDIA_MACAVF_MANAGER_IMPLEMENTATIONNAME ) == 0 )
+	{
+		const ::rtl::OUString aServiceName( ::rtl::OUString::createFromAscii( AVMEDIA_MACAVF_MANAGER_SERVICENAME ) );
+
+		xFactory = uno::Reference< lang::XSingleServiceFactory >( ::cppu::createSingleFactory(
+						reinterpret_cast< lang::XMultiServiceFactory* >( pServiceManager ),
+						::rtl::OUString::createFromAscii( AVMEDIA_MACAVF_MANAGER_IMPLEMENTATIONNAME ),
+						create_MediaPlayer, uno::Sequence< ::rtl::OUString >( &aServiceName, 1 ) ) );
+	}
+
+	if( xFactory.is() )
+	{
+		xFactory->acquire();
+		pRet = xFactory.get();
+	}
+
+	return pRet;
+}
diff --git a/main/avmedia/source/macavf/makefile.mk b/main/avmedia/source/macavf/makefile.mk
new file mode 100644
index 0000000..542ba0a
--- /dev/null
+++ b/main/avmedia/source/macavf/makefile.mk
@@ -0,0 +1,89 @@
+#**************************************************************
+#  
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#  
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+#  
+#**************************************************************
+
+PRJ=..$/..
+PRJNAME=avmedia
+TARGET=avmediaMacAVF
+
+.IF "$(GUIBASE)" != "aqua"
+dummy:
+	@echo " Nothing to build for GUIBASE=$(GUIBASE)"
+.ELSE
+
+# --- Settings ----------------------------------
+
+.INCLUDE :  	settings.mk
+
+.IF "$(verbose)"!="" || "$(VERBOSE)"!=""
+CDEFS+= -DVERBOSE
+.ENDIF
+
+# --- Files ----------------------------------
+
+CFLAGSCXX+=$(OBJCXXFLAGS)
+
+SLOFILES= \
+		$(SLO)$/macavfuno.obj  \
+		$(SLO)$/framegrabber.obj        \
+		$(SLO)$/manager.obj       \
+		$(SLO)$/window.obj        \
+		$(SLO)$/player.obj
+
+EXCEPTIONSFILES= \
+		$(SLO)$/framegrabber.obj        \
+		$(SLO)$/macavfuno.obj
+
+SHL1TARGET= $(TARGET)$(DLLPOSTFIX)
+
+SHL1STDLIBS= \
+             $(CPPULIB) \
+             $(SALLIB)  \
+             $(COMPHELPERLIB) \
+             $(CPPUHELPERLIB) \
+             $(TOOLSLIB) \
+             $(VCLLIB) 
+
+SHL1STDLIBS+= \
+             -framework Cocoa \
+             -framework AVFoundation \
+             -framework CoreMedia
+
+# build DLL
+SHL1LIBS=$(SLB)$/$(TARGET).lib
+SHL1IMPLIB=i$(TARGET)
+SHL1DEF=$(MISC)$/$(SHL1TARGET).def
+
+SHL1VERSIONMAP=$(SOLARENV)/src/component.map
+
+# --- Targets ------------------------------------------------------
+
+.INCLUDE : target.mk
+
+.ENDIF
+
+ALLTAR : $(MISC)/avmediaMacAVF.component
+
+$(MISC)/avmediaMacAVF.component .ERRREMOVE : \
+        $(SOLARENV)/bin/createcomponent.xslt avmediaMacAVF.component
+    $(XSLTPROC) --nonet --stringparam uri \
+        '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
+        $(SOLARENV)/bin/createcomponent.xslt avmediaMacAVF.component
+
diff --git a/main/avmedia/source/macavf/manager.cxx b/main/avmedia/source/macavf/manager.cxx
new file mode 100644
index 0000000..c11eb19
--- /dev/null
+++ b/main/avmedia/source/macavf/manager.cxx
@@ -0,0 +1,90 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#include "manager.hxx"
+#include "player.hxx"
+#include <tools/urlobj.hxx>
+
+using namespace ::com::sun::star;
+
+namespace avmedia { namespace macavf {
+
+// ----------------
+// - Manager -
+// ----------------
+
+Manager::Manager( const uno::Reference< lang::XMultiServiceFactory >& rxMgr ) :
+    mxMgr( rxMgr )
+{
+    OSL_TRACE( "Constructing avmedia::macavf::Manager" );
+}
+
+// ------------------------------------------------------------------------------
+
+Manager::~Manager()
+{}
+
+// ------------------------------------------------------------------------------
+
+uno::Reference< media::XPlayer > SAL_CALL Manager::createPlayer( const ::rtl::OUString& rURL )
+    throw (uno::RuntimeException)
+{
+    Player*                             pPlayer( new Player( mxMgr ) );
+    uno::Reference< media::XPlayer >    xRet( pPlayer );
+    INetURLObject                       aURL( rURL );
+
+    OSL_TRACE( "avmediamacavf: Manager::createPlayer" );
+
+    if( !pPlayer->create( aURL.GetMainURL( INetURLObject::DECODE_UNAMBIGUOUS ) )  )
+        xRet = uno::Reference< media::XPlayer >();
+
+    return xRet;
+}
+
+// ------------------------------------------------------------------------------
+
+::rtl::OUString SAL_CALL Manager::getImplementationName(  )
+    throw (uno::RuntimeException)
+{
+    return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( AVMEDIA_MACAVF_MANAGER_IMPLEMENTATIONNAME ) );
+}
+
+// ------------------------------------------------------------------------------
+
+sal_Bool SAL_CALL Manager::supportsService( const ::rtl::OUString& ServiceName )
+    throw (uno::RuntimeException)
+{
+    return ServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM ( AVMEDIA_MACAVF_MANAGER_SERVICENAME ) );
+}
+
+// ------------------------------------------------------------------------------
+
+uno::Sequence< ::rtl::OUString > SAL_CALL Manager::getSupportedServiceNames(  )
+    throw (uno::RuntimeException)
+{
+    uno::Sequence< ::rtl::OUString > aRet(1);
+    aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( AVMEDIA_MACAVF_MANAGER_SERVICENAME ) );
+
+    return aRet;
+}
+
+} // namespace macavf
+} // namespace avmedia
diff --git a/main/avmedia/source/macavf/manager.hxx b/main/avmedia/source/macavf/manager.hxx
new file mode 100644
index 0000000..f8f6ea9
--- /dev/null
+++ b/main/avmedia/source/macavf/manager.hxx
@@ -0,0 +1,59 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef _MANAGER_HXX
+#define _MANAGER_HXX
+
+#include "macavfcommon.hxx"
+
+#include "com/sun/star/media/XManager.hdl"
+
+// -----------
+// - Manager -
+// -----------
+
+namespace avmedia { namespace macavf {
+
+class Manager : public ::cppu::WeakImplHelper2 < ::com::sun::star::media::XManager,
+                                                 ::com::sun::star::lang::XServiceInfo >
+{
+public:
+
+    Manager( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& rxMgr );
+    ~Manager();
+
+    // XManager
+    virtual ::com::sun::star::uno::Reference< ::com::sun::star::media::XPlayer > SAL_CALL createPlayer( const ::rtl::OUString& aURL ) throw (::com::sun::star::uno::RuntimeException);
+
+    // XServiceInfo
+    virtual ::rtl::OUString SAL_CALL getImplementationName(  ) throw (::com::sun::star::uno::RuntimeException);
+    virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException);
+    virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames(  ) throw (::com::sun::star::uno::RuntimeException);
+private:
+
+    ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > mxMgr;
+};
+
+} // namespace macavf
+} // namespace avmedia
+
+#endif // _MANAGER_HXX
+
diff --git a/main/avmedia/source/macavf/player.cxx b/main/avmedia/source/macavf/player.cxx
new file mode 100644
index 0000000..46a8397
--- /dev/null
+++ b/main/avmedia/source/macavf/player.cxx
@@ -0,0 +1,475 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+
+#include "player.hxx"
+#include "framegrabber.hxx"
+#include "window.hxx"
+
+#include <cmath> // for log10()
+
+using namespace ::com::sun::star;
+
+#include <hash_map>
+typedef std::hash_map<NSObject*,avmedia::macavf::MacAVObserverHandler*> HandlersForObject;
+
+@implementation MacAVObserverObject
+{
+    HandlersForObject maHandlersForObject;
+}
+- (void)observeValueForKeyPath:(NSString*)pKeyPath ofObject:(id)pObject change:(NSDictionary*)pChangeDict context:(void*)pContext
+{
+    NSString* pDictStr = [NSString stringWithFormat:@"%@", pChangeDict];
+    OSL_TRACE( "MacAVObserver::onKeyChange k=\"%s\" c=%s", [pKeyPath UTF8String], [pDictStr UTF8String]);
+    avmedia::macavf::MacAVObserverHandler* pHandler = (avmedia::macavf::MacAVObserverHandler*)pContext;
+    pHandler->handleObservation( pKeyPath );
+}
+
+- (void)onNotification:(NSNotification*)pNotification
+{
+    NSString* pNoteName = (NSString*)[pNotification name];
+    OSL_TRACE( "MacAVObserver::onNotification key=\"%s\"", [pNoteName UTF8String]);
+    HandlersForObject::iterator it = maHandlersForObject.find( [pNotification object]);
+    if( it != maHandlersForObject.end() )
+        (*it).second->handleObservation( pNoteName );
+}
+
+- (void)setHandlerForObject:(NSObject*)pObject handler:(avmedia::macavf::MacAVObserverHandler*)pHandler
+{
+    maHandlersForObject[ pObject] = pHandler;
+}
+
+- (void)removeHandlerForObject:(NSObject*)pObject
+{
+    maHandlersForObject.erase( pObject);
+}
+
+@end
+
+
+namespace avmedia { namespace macavf {
+
+MacAVObserverObject* MacAVObserverHandler::mpMacAVObserverObject = NULL;
+ 
+MacAVObserverObject* MacAVObserverHandler::getObserver() const
+{
+    if( !mpMacAVObserverObject)
+    {
+        mpMacAVObserverObject = [MacAVObserverObject alloc];
+        [mpMacAVObserverObject retain];
+    }
+    return mpMacAVObserverObject;
+}
+
+
+// ----------------
+// - Player -
+// ----------------
+
+Player::Player( const uno::Reference< lang::XMultiServiceFactory >& rxMgr )
+:   mxMgr( rxMgr )
+,   mpPlayer( NULL )
+,   mfUnmutedVolume( 0 )
+,   mfStopTime( DBL_MAX )
+,   mbMuted( false )
+,   mbLooping( false )
+{}
+
+// ------------------------------------------------------------------------------
+
+Player::~Player()
+{
+    if( !mpPlayer )
+        return;
+    // remove the observers
+    [mpPlayer removeObserver:getObserver() forKeyPath:@"currentItem.status"];
+    AVPlayerItem* pOldPlayerItem = [mpPlayer currentItem];
+    [[NSNotificationCenter defaultCenter] removeObserver:getObserver()
+        name:AVPlayerItemDidPlayToEndTimeNotification
+        object:pOldPlayerItem];
+    [getObserver() removeHandlerForObject:pOldPlayerItem];
+    // release the AVPlayer
+    CFRelease( mpPlayer );
+}
+
+// ------------------------------------------------------------------------------
+
+AVAsset* Player::getMovie()
+{
+    if( !mpPlayer )
+        return nil;
+    AVAsset* pMovie = [[mpPlayer currentItem] asset];
+    OSL_ASSERT( pMovie ); 
+    return pMovie;
+}
+
+// ------------------------------------------------------------------------------
+
+bool Player::handleObservation( NSString* pKeyPath )
+{
+    OSL_TRACE( "AVPlayer::handleObservation key=\"%s\"", [pKeyPath UTF8String]);
+    if( [pKeyPath isEqualToString:AVPlayerItemDidPlayToEndTimeNotification])
+    {
+        OSL_TRACE( "AVPlayer replay=%d", mbLooping);
+        if( mbLooping )
+            setMediaTime( 0.0);
+    }
+    return true;
+}
+
+// ------------------------------------------------------------------------------
+
+bool Player::create( const ::rtl::OUString& rURL )
+{
+    maURL = rURL;
+
+    // get the media asset
+    NSString* aNSStr = [NSString stringWithCharacters:rURL.getStr() length:rURL.getLength()];
+    NSURL* aNSURL = [NSURL URLWithString: [aNSStr stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding]];
+    // get the matching AVPlayerItem
+    AVPlayerItem* pPlayerItem = [AVPlayerItem playerItemWithURL:aNSURL];
+
+    // create or update the AVPlayer with the new AVPlayerItem
+    if( !mpPlayer )
+    {
+        mpPlayer = [AVPlayer playerWithPlayerItem:pPlayerItem];
+        CFRetain( mpPlayer );
+        [mpPlayer setActionAtItemEnd:AVPlayerActionAtItemEndNone];
+    }
+    else
+    {
+        // remove the obsoleted observers
+        AVPlayerItem* pOldPlayerItem = [mpPlayer currentItem];
+        [mpPlayer removeObserver:getObserver() forKeyPath:@"currentItem.status"];
+        [getObserver() removeHandlerForObject:pOldPlayerItem];
+        [[NSNotificationCenter defaultCenter] removeObserver:getObserver()
+            name:AVPlayerItemDidPlayToEndTimeNotification
+            object:pOldPlayerItem];
+        // replace the playeritem
+        [mpPlayer replaceCurrentItemWithPlayerItem:pPlayerItem];
+    }
+
+    // observe the status of the current player item
+    [mpPlayer addObserver:getObserver() forKeyPath:@"currentItem.status" options:0 context:this];
+
+    // observe playback-end needed for playback looping
+    [[NSNotificationCenter defaultCenter] addObserver:getObserver()
+        selector:@selector(onNotification:)
+        name:AVPlayerItemDidPlayToEndTimeNotification
+        object:pPlayerItem];
+    [getObserver() setHandlerForObject:pPlayerItem handler:this];
+
+    return true;
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Player::start()
+    throw (uno::RuntimeException)
+{
+    if( !mpPlayer )
+        return;
+#if 0
+    const AVPlayerStatus eStatus = [mpPlayer status];
+    OSL_TRACE ("Player::start status=%d", (int)eStatus);
+    if( eStatus == AVPlayerStatusReadyToPlay)
+#endif
+        [mpPlayer play];
+    // else // TODO: delay until it becomes ready
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Player::stop()
+    throw (uno::RuntimeException)
+{
+    if( !mpPlayer )
+        return;
+    const bool bPlaying = isPlaying();
+    OSL_TRACE ("Player::stop() playing=%d", bPlaying);
+    if( bPlaying )
+        [mpPlayer pause];
+}
+
+// ------------------------------------------------------------------------------
+
+sal_Bool SAL_CALL Player::isPlaying()
+    throw (uno::RuntimeException)
+{
+    if( !mpPlayer )
+        return false;
+    const float fRate = [mpPlayer rate];
+    return (fRate != 0.0);
+}
+
+// ------------------------------------------------------------------------------
+
+double SAL_CALL Player::getDuration()
+    throw (uno::RuntimeException)
+{
+    // slideshow checks for non-zero duration, so cheat here
+    double duration = 0.01;
+
+    if( mpPlayer )
+    {
+        AVPlayerItem* pItem = [mpPlayer currentItem];
+        duration = CMTimeGetSeconds( [pItem duration] );
+    }
+
+    return duration;
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Player::setMediaTime( double fTime )
+    throw (uno::RuntimeException)
+{
+    OSL_TRACE ("Player::setMediaTime( %.3fsec)", fTime);
+    if( mpPlayer )
+        [mpPlayer seekToTime: CMTimeMakeWithSeconds(fTime,1000) ];
+}
+
+// ------------------------------------------------------------------------------
+
+double SAL_CALL Player::getMediaTime()
+    throw (uno::RuntimeException)
+{
+    if( !mpPlayer )
+        return 0.0;
+
+    const double position = CMTimeGetSeconds( [mpPlayer currentTime] );
+    OSL_TRACE( "Player::getMediaTime() = %.3fsec", position);
+    if( position >= mfStopTime )
+        if( isPlaying() )
+            stop();
+
+    return position;
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Player::setStopTime( double fTime )
+    throw (uno::RuntimeException)
+{
+    OSL_TRACE ("Player::setStopTime( %.3fsec)", fTime);
+    mfStopTime = fTime;
+}
+
+// ------------------------------------------------------------------------------
+
+double SAL_CALL Player::getStopTime()
+    throw (uno::RuntimeException)
+{
+    return mfStopTime;
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Player::setRate( double fRate )
+    throw (uno::RuntimeException)
+{
+    OSL_TRACE ("Player::setRate( %.3f)", fRate);
+    if( !mpPlayer )
+        return;
+
+    // playback rate: 0 = stop, 1 = normal speed, 2 = double speed, -1 = normal speed backwards
+    [mpPlayer setRate: fRate];
+}
+
+// ------------------------------------------------------------------------------
+
+double SAL_CALL Player::getRate()
+    throw (uno::RuntimeException)
+{
+    // macavf: 0 = stop, 1 = normal speed, 2 = double speed, -1 = normal speed backwards
+    const double fRate = mpPlayer ? (double)[mpPlayer rate] : 1.0;
+    OSL_TRACE ("Player::getRate() = %.3f", fRate);
+    return fRate;
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Player::setPlaybackLoop( sal_Bool bSet )
+    throw (uno::RuntimeException)
+{
+    OSL_TRACE ("Player::setPlaybackLoop( %d)", bSet );
+    mbLooping = bSet;
+}
+
+// ------------------------------------------------------------------------------
+
+sal_Bool SAL_CALL Player::isPlaybackLoop()
+    throw (uno::RuntimeException)
+{
+    const bool bRet = mbLooping;
+    OSL_TRACE ("Player::isPlaybackLoop() = %d", bRet );
+    return bRet;
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Player::setMute( sal_Bool bSet )
+    throw (uno::RuntimeException)
+{
+    OSL_TRACE( "Player::setMute(%d), was-muted: %d unmuted-volume: %.3f", bSet, mbMuted, mfUnmutedVolume );
+
+    if( !mpPlayer )
+        return;
+
+    mbMuted = (bSet == TRUE);
+    [mpPlayer setMuted:mbMuted]; 
+}
+
+// ------------------------------------------------------------------------------
+
+sal_Bool SAL_CALL Player::isMute()
+    throw (uno::RuntimeException)
+{
+    OSL_TRACE ("Player::isMuted() = %d", mbMuted);
+    return mbMuted;
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Player::setVolumeDB( sal_Int16 nVolumeDB ) 
+	throw (uno::RuntimeException)
+{
+    // -40dB <-> AVPlayer volume 0.0
+    //   0dB <-> AVPlayer volume 1.0
+    mfUnmutedVolume = (nVolumeDB <= -40) ? 0.0 : pow( 10.0, nVolumeDB / 20.0 );
+    OSL_TRACE( "Player::setVolume(%ddB), muted=%d, unmuted-volume: %.3f", nVolumeDB, mbMuted, mfUnmutedVolume );
+
+    // change volume
+    if( !mbMuted && mpPlayer )
+        [mpPlayer setVolume:mfUnmutedVolume];
+}
+
+// ------------------------------------------------------------------------------
+    
+sal_Int16 SAL_CALL Player::getVolumeDB() 
+	throw (uno::RuntimeException)
+{
+    if( !mpPlayer )
+        return 0;
+
+    // get the actual volume
+    const float fVolume = [mpPlayer volume];
+
+    // convert into Dezibel value
+    // -40dB <-> AVPlayer volume 0.0
+    //   0dB <-> AVPlayer volume 1.0
+    const int nVolumeDB = (fVolume <= 0) ? -40 : lrint( 20.0*log10(fVolume));
+    
+    return (sal_Int16)nVolumeDB;
+}
+
+// ------------------------------------------------------------------------------
+
+awt::Size SAL_CALL Player::getPreferredPlayerWindowSize()
+    throw (uno::RuntimeException)
+{
+    awt::Size aSize( 0, 0 ); // default size
+
+    AVAsset* pMovie = [[mpPlayer currentItem] asset];
+    NSArray* pVideoTracks = [pMovie tracksWithMediaType:AVMediaTypeVideo];
+    AVAssetTrack* pFirstVideoTrack = (AVAssetTrack*)[pVideoTracks firstObject];
+    if( pFirstVideoTrack )
+    {
+        const CGSize aPrefSize = [pFirstVideoTrack naturalSize];
+        aSize = awt::Size( aPrefSize.width, aPrefSize.height );
+    }
+
+    return aSize;
+}
+
+// ------------------------------------------------------------------------------
+
+uno::Reference< ::media::XPlayerWindow > SAL_CALL Player::createPlayerWindow( const uno::Sequence< uno::Any >& aArguments )
+    throw (uno::RuntimeException)
+{
+    // get the preferred window size
+    const awt::Size aSize( getPreferredPlayerWindowSize() );
+    OSL_TRACE( "Player::createPlayerWindow %dx%d argsLength: %d", aSize.Width, aSize.Height, aArguments.getLength() );
+
+    // get the parent view
+    sal_IntPtr nNSViewPtr = NULL;
+    aArguments[0] >>= nNSViewPtr;
+    NSView* pParentView = reinterpret_cast<NSView*>(nNSViewPtr);
+
+    // check the window parameters
+    uno::Reference< ::media::XPlayerWindow > xRet;
+    if( (aSize.Width <= 0) || (aSize.Height <= 0) || (pParentView == NULL) )
+         return xRet;
+
+    // create the window
+    ::avmedia::macavf::Window* pWindow = new ::avmedia::macavf::Window( mxMgr, *this, pParentView );
+    xRet = pWindow;
+    return xRet;
+}
+
+// ------------------------------------------------------------------------------
+
+uno::Reference< media::XFrameGrabber > SAL_CALL Player::createFrameGrabber() 
+    throw (uno::RuntimeException)
+{
+    uno::Reference< media::XFrameGrabber > xRet;
+    OSL_TRACE ("Player::createFrameGrabber");
+
+    if( !maURL.isEmpty() )
+    {
+        FrameGrabber* pGrabber = new FrameGrabber( mxMgr );
+        if( pGrabber->create( maURL ) )
+            xRet = pGrabber;
+    }
+
+    return xRet;
+}
+
+// ------------------------------------------------------------------------------
+
+::rtl::OUString SAL_CALL Player::getImplementationName(  )
+    throw (uno::RuntimeException)
+{
+    return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( AVMEDIA_MACAVF_PLAYER_IMPLEMENTATIONNAME ) );
+}
+
+// ------------------------------------------------------------------------------
+
+sal_Bool SAL_CALL Player::supportsService( const ::rtl::OUString& ServiceName )
+    throw (uno::RuntimeException)
+{
+    return ServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM ( AVMEDIA_MACAVF_PLAYER_SERVICENAME ) );
+}
+
+// ------------------------------------------------------------------------------
+
+uno::Sequence< ::rtl::OUString > SAL_CALL Player::getSupportedServiceNames(  )
+    throw (uno::RuntimeException)
+{
+    uno::Sequence< ::rtl::OUString > aRet(1);
+    aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( AVMEDIA_MACAVF_PLAYER_SERVICENAME ) );
+
+    return aRet;
+}
+
+} // namespace macavf
+} // namespace avmedia
+
diff --git a/main/avmedia/source/macavf/player.hxx b/main/avmedia/source/macavf/player.hxx
new file mode 100644
index 0000000..10ff013
--- /dev/null
+++ b/main/avmedia/source/macavf/player.hxx
@@ -0,0 +1,97 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+
+
+#ifndef _PLAYER_HXX
+#define _PLAYER_HXX
+
+#include <osl/conditn.h>
+#include "macavfcommon.hxx"
+
+#include "com/sun/star/media/XPlayer.hdl"
+
+namespace avmedia { namespace macavf {
+
+/*
+// ----------
+// - Player -
+// ----------
+*/
+
+class Player
+:   public MacAVObserverHandler
+,   public ::cppu::WeakImplHelper2< ::com::sun::star::media::XPlayer,
+                                    ::com::sun::star::lang::XServiceInfo >
+{
+public:
+    explicit Player( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& );
+    virtual  ~Player();
+
+    bool create( const ::rtl::OUString& rURL );
+
+    // XPlayer
+    virtual void SAL_CALL start() throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL stop() throw (::com::sun::star::uno::RuntimeException);
+    virtual sal_Bool SAL_CALL isPlaying() throw (::com::sun::star::uno::RuntimeException);
+    virtual double SAL_CALL getDuration() throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL setMediaTime( double fTime ) throw (::com::sun::star::uno::RuntimeException);
+    virtual double SAL_CALL getMediaTime() throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL setStopTime( double fTime ) throw (::com::sun::star::uno::RuntimeException);
+    virtual double SAL_CALL getStopTime() throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL setRate( double fRate ) throw (::com::sun::star::uno::RuntimeException);
+    virtual double SAL_CALL getRate() throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL setPlaybackLoop( sal_Bool bSet ) throw (::com::sun::star::uno::RuntimeException);
+    virtual sal_Bool SAL_CALL isPlaybackLoop() throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL setMute( sal_Bool bSet ) throw (::com::sun::star::uno::RuntimeException);
+    virtual sal_Bool SAL_CALL isMute() throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL setVolumeDB( sal_Int16 nVolumeDB ) throw (::com::sun::star::uno::RuntimeException);
+    virtual sal_Int16 SAL_CALL getVolumeDB() throw (::com::sun::star::uno::RuntimeException);
+    virtual ::com::sun::star::awt::Size SAL_CALL getPreferredPlayerWindowSize(  ) throw (::com::sun::star::uno::RuntimeException);
+    virtual ::com::sun::star::uno::Reference< ::com::sun::star::media::XPlayerWindow > SAL_CALL createPlayerWindow( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aArguments ) throw (::com::sun::star::uno::RuntimeException);
+    virtual ::com::sun::star::uno::Reference< ::com::sun::star::media::XFrameGrabber > SAL_CALL createFrameGrabber(  ) throw (::com::sun::star::uno::RuntimeException);
+    // XServiceInfo
+    virtual ::rtl::OUString SAL_CALL getImplementationName() throw (::com::sun::star::uno::RuntimeException);
+    virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException);
+    virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames(  ) throw (::com::sun::star::uno::RuntimeException);
+ 
+    AVAsset* getMovie();
+    AVPlayer* getAVPlayer() const { return mpPlayer; }
+    virtual bool handleObservation( NSString* pKeyPath );
+
+private:
+    ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > mxMgr;
+
+    ::rtl::OUString     maURL;
+    
+    AVPlayer*           mpPlayer;
+
+    float               mfUnmutedVolume;
+    double              mfStopTime;
+    
+    bool                mbMuted;
+    bool                mbLooping;
+};
+
+} // namespace macavf
+} // namespace avmedia
+
+#endif // _PLAYER_HXX
diff --git a/main/avmedia/source/macavf/window.cxx b/main/avmedia/source/macavf/window.cxx
new file mode 100644
index 0000000..f9e68f7
--- /dev/null
+++ b/main/avmedia/source/macavf/window.cxx
@@ -0,0 +1,342 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+
+
+#include <com/sun/star/awt/SystemPointer.hpp>
+#include <com/sun/star/awt/PosSize.hpp>
+
+#include "window.hxx"
+#include "player.hxx"
+
+using namespace ::com::sun::star;
+
+
+namespace avmedia { namespace macavf {
+
+// ---------------
+// - Window -
+// ---------------
+
+Window::Window( const uno::Reference< lang::XMultiServiceFactory >& i_rxMgr, Player& i_rPlayer, NSView* i_pParentView )
+:   mxMgr( i_rxMgr )
+,   maListeners( maMutex )
+,   meZoomLevel( media::ZoomLevel_NOT_AVAILABLE )
+,   mrPlayer( i_rPlayer )
+,   mnPointerType( awt::SystemPointer::ARROW )
+,   mpView( i_pParentView )
+,   mpPlayerLayer( NULL )
+{
+    OSL_TRACE ("Constructing an avmedia::macavf::Window");
+    if( !mpView ) // sanity check
+        return;
+
+    // check the media asset for video content
+    AVPlayer* pAVPlayer = mrPlayer.getAVPlayer();
+    AVAsset* pMovie = [[pAVPlayer currentItem] asset];
+    const int nVideoCount = [pMovie tracksWithMediaType:AVMediaTypeVideo].count;
+    const int nAudioCount = [pMovie tracksWithMediaType:AVMediaTypeAudio].count;
+    OSL_TRACE( "Found %d video and %d audio tracks.", nVideoCount, nAudioCount );
+    (void)nAudioCount;
+    if( nVideoCount <= 0 )
+        return;
+
+    // setup the AVPlayerLayer
+    [pAVPlayer retain];
+    [pAVPlayer pause];
+    mpPlayerLayer = [AVPlayerLayer playerLayerWithPlayer:pAVPlayer];
+    [mpPlayerLayer retain];
+    [mpPlayerLayer setFrame:[mpView frame]];
+    [mpPlayerLayer setHidden:YES];
+    [mpPlayerLayer setVideoGravity:AVLayerVideoGravityResizeAspectFill];
+    [mpPlayerLayer addObserver:getObserver() forKeyPath:@"readyForDisplay" options:0 context:this];
+
+    // setup the target view
+    [mpView setWantsLayer:YES];
+    [mpView.layer addSublayer:mpPlayerLayer];
+}
+
+// ------------------------------------------------------------------------------
+
+Window::~Window()
+{
+    [mpPlayerLayer removeObserver:getObserver() forKeyPath:@"readyForDisplay"];
+    [mpPlayerLayer release];
+}
+
+// ------------------------------------------------------------------------------
+
+bool Window::create( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aArguments )
+{
+    return true;
+}
+
+// ------------------------------------------------------------------------------
+
+bool Window::handleObservation( NSString* pKeyPath )
+{
+    OSL_TRACE( "AVPlayer::handleObservation key=\"%s\"", [pKeyPath UTF8String]);
+    const BOOL bReadyForDisplay = [mpPlayerLayer isReadyForDisplay];
+    [mpPlayerLayer setHidden:!bReadyForDisplay];
+    return true;
+}
+
+// XPlayerWindow
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::update()
+    throw (uno::RuntimeException)
+{}
+
+// ------------------------------------------------------------------------------
+
+sal_Bool SAL_CALL Window::setZoomLevel( media::ZoomLevel eZoomLevel )
+    throw (uno::RuntimeException)
+{
+    return false;
+}
+
+// ------------------------------------------------------------------------------
+
+media::ZoomLevel SAL_CALL Window::getZoomLevel(  )
+    throw (uno::RuntimeException)
+{
+    return meZoomLevel;
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::setPointerType( sal_Int32 nPointerType ) 
+    throw (uno::RuntimeException)
+{
+    mnPointerType = nPointerType;
+}
+
+// XWindow
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::setPosSize( sal_Int32 X, sal_Int32 Y, sal_Int32 Width, sal_Int32 Height, sal_Int16 Flags )
+    throw (uno::RuntimeException)
+{
+    OSL_TRACE( "AVWindow::setPosSize( %dx%d%+d%+d)", (int)Width,(int)Height,(int)X,(int)Y);//######
+    if( !mpView )
+        return;
+    NSRect aRect = [mpView frame];
+    // NOTE: if( (Flags & awt::PosSize::WIDTH) )
+    aRect.size.width = Width;
+    // NOTE: if( (Flags & awt::PosSize::HEIGHT) )
+    aRect.size.height = Height;
+
+    [mpView setFrameSize: aRect.size];
+    [mpPlayerLayer setFrame: [mpView frame]];
+}
+
+// ------------------------------------------------------------------------------
+
+awt::Rectangle SAL_CALL Window::getPosSize()
+    throw (uno::RuntimeException)
+{
+    awt::Rectangle aRet;
+
+    NSRect aRect = [mpView frame];
+    aRet.X = aRet.Y = 0;
+    aRet.Width = aRect.size.width;
+    aRet.Height = aRect.size.height;
+
+    return aRet;
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::setVisible( sal_Bool bVisible )
+    throw (uno::RuntimeException)
+{
+    OSL_TRACE ("Window::setVisible(%d)", bVisible);
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::setEnable( sal_Bool bEnable )
+    throw (uno::RuntimeException)
+{
+    OSL_TRACE ("Window::setEnable(%d)", bEnable);
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::setFocus()
+    throw (uno::RuntimeException)
+{
+    OSL_TRACE ("Window::setFocus");
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::addWindowListener( const uno::Reference< awt::XWindowListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.addInterface( getCppuType( &xListener ), xListener );
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::removeWindowListener( const uno::Reference< awt::XWindowListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.removeInterface( getCppuType( &xListener ), xListener );
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::addFocusListener( const uno::Reference< awt::XFocusListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.addInterface( getCppuType( &xListener ), xListener );
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::removeFocusListener( const uno::Reference< awt::XFocusListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.removeInterface( getCppuType( &xListener ), xListener );
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::addKeyListener( const uno::Reference< awt::XKeyListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.addInterface( getCppuType( &xListener ), xListener );
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::removeKeyListener( const uno::Reference< awt::XKeyListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.removeInterface( getCppuType( &xListener ), xListener );
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::addMouseListener( const uno::Reference< awt::XMouseListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.addInterface( getCppuType( &xListener ), xListener );
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::removeMouseListener( const uno::Reference< awt::XMouseListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.removeInterface( getCppuType( &xListener ), xListener );
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::addMouseMotionListener( const uno::Reference< awt::XMouseMotionListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.addInterface( getCppuType( &xListener ), xListener );
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::removeMouseMotionListener( const uno::Reference< awt::XMouseMotionListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.removeInterface( getCppuType( &xListener ), xListener );
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::addPaintListener( const uno::Reference< awt::XPaintListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.addInterface( getCppuType( &xListener ), xListener );
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::removePaintListener( const uno::Reference< awt::XPaintListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.removeInterface( getCppuType( &xListener ), xListener );
+}
+
+
+// XComponent
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::dispose(  )
+    throw (uno::RuntimeException)
+{
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::addEventListener( const uno::Reference< lang::XEventListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.addInterface( getCppuType( &xListener ), xListener );
+}
+
+// ------------------------------------------------------------------------------
+
+void SAL_CALL Window::removeEventListener( const uno::Reference< lang::XEventListener >& xListener )
+    throw (uno::RuntimeException)
+{
+    maListeners.removeInterface( getCppuType( &xListener ), xListener );
+}
+
+// XServiceInfo
+// ------------------------------------------------------------------------------
+
+::rtl::OUString SAL_CALL Window::getImplementationName(  )
+    throw (uno::RuntimeException)
+{
+    return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( AVMEDIA_MACAVF_WINDOW_IMPLEMENTATIONNAME ) );
+}
+
+// ------------------------------------------------------------------------------
+
+sal_Bool SAL_CALL Window::supportsService( const ::rtl::OUString& ServiceName )
+    throw (uno::RuntimeException)
+{
+    return ServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM ( AVMEDIA_MACAVF_WINDOW_SERVICENAME ) );
+}
+
+// ------------------------------------------------------------------------------
+
+uno::Sequence< ::rtl::OUString > SAL_CALL Window::getSupportedServiceNames(  )
+    throw (uno::RuntimeException)
+{
+    uno::Sequence< ::rtl::OUString > aRet(1);
+    aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( AVMEDIA_MACAVF_WINDOW_SERVICENAME ) );
+
+    return aRet;
+}
+
+} // namespace macavf
+} // namespace avmedia
+
diff --git a/main/avmedia/source/macavf/window.hxx b/main/avmedia/source/macavf/window.hxx
new file mode 100644
index 0000000..83977c2
--- /dev/null
+++ b/main/avmedia/source/macavf/window.hxx
@@ -0,0 +1,123 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef _WINDOW_HXX
+#define _WINDOW_HXX
+
+#include "macavfcommon.hxx"
+#include <cppuhelper/interfacecontainer.h>
+
+#include "com/sun/star/media/XPlayerWindow.hdl"
+
+// ---------------
+// - MyMediaView -
+// ---------------
+
+@interface MyMediaView : NSView
+@property (nonatomic, readonly, strong) AVPlayer* player;
+@property (nonatomic, readonly, strong) AVPlayerLayer* playerLayer;
+@property (nonatomic, retain) NSURL* videoURL;
+- (void) play;
+@end
+
+namespace avmedia { namespace macavf {
+
+// ---------------
+// - Window -
+// ---------------
+
+class Player;
+
+class Window
+:   public MacAVObserverHandler
+,   public ::cppu::WeakImplHelper2 < ::com::sun::star::media::XPlayerWindow,
+                                     ::com::sun::star::lang::XServiceInfo >
+{
+public:
+
+            Window( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& i_rxMgr,
+                    Player& i_rPlayer,
+                    NSView* i_pParentView
+                    );
+    virtual ~Window();
+
+    bool    create( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aArguments );
+    void    processGraphEvent();
+    void    updatePointer();
+
+    // XPlayerWindow
+    virtual void SAL_CALL update(  ) throw (::com::sun::star::uno::RuntimeException);
+    virtual sal_Bool SAL_CALL setZoomLevel( ::com::sun::star::media::ZoomLevel ZoomLevel ) throw (::com::sun::star::uno::RuntimeException);
+    virtual ::com::sun::star::media::ZoomLevel SAL_CALL getZoomLevel(  ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL setPointerType( sal_Int32 nPointerType ) throw (::com::sun::star::uno::RuntimeException);
+
+    // XWindow
+    virtual void SAL_CALL setPosSize( sal_Int32 X, sal_Int32 Y, sal_Int32 Width, sal_Int32 Height, sal_Int16 Flags ) throw (::com::sun::star::uno::RuntimeException);
+    virtual ::com::sun::star::awt::Rectangle SAL_CALL getPosSize(  ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL setVisible( sal_Bool Visible ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL setEnable( sal_Bool Enable ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL setFocus(  ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL addWindowListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL removeWindowListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL addFocusListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XFocusListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL removeFocusListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XFocusListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL addKeyListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XKeyListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL removeKeyListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XKeyListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL addMouseListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XMouseListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL removeMouseListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XMouseListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL addMouseMotionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XMouseMotionListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL removeMouseMotionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XMouseMotionListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL addPaintListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XPaintListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL removePaintListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XPaintListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
+
+    // XComponent
+    virtual void SAL_CALL dispose(  ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL addEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
+    virtual void SAL_CALL removeEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener >& aListener ) throw (::com::sun::star::uno::RuntimeException);
+
+    // XServiceInfo
+    virtual ::rtl::OUString SAL_CALL getImplementationName(  ) throw (::com::sun::star::uno::RuntimeException);
+    virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException);
+    virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames(  ) throw (::com::sun::star::uno::RuntimeException);
+
+    virtual bool handleObservation( NSString* pKeyPath );
+
+private:
+
+    ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > mxMgr;
+
+    ::osl::Mutex                                maMutex;
+    ::cppu::OMultiTypeInterfaceContainerHelper  maListeners;
+    ::com::sun::star::media::ZoomLevel          meZoomLevel;
+    Player&                                     mrPlayer;
+    int                                         mnPointerType;
+
+    NSView*                                     mpView; // parent-view == movie-view
+    AVPlayerLayer*                              mpPlayerLayer;
+
+    void                                        ImplLayoutVideoWindow();
+};
+
+} // namespace macavf
+} // namespace avmedia
+
+#endif // _WINDOW_HXX
+
diff --git a/main/scp2/source/ooo/file_library_ooo.scp b/main/scp2/source/ooo/file_library_ooo.scp
index 6b94241..df8c8b3 100644
--- a/main/scp2/source/ooo/file_library_ooo.scp
+++ b/main/scp2/source/ooo/file_library_ooo.scp
@@ -615,6 +615,14 @@ File gid_File_Lib_avmediaQuickTime
 	Name = LIBNAME(avmediaQuickTime);
 	Dir = SCP2_OOO_BIN_DIR;
 End
+
+File gid_File_Lib_avmediaMacAVF
+	TXT_FILE_BODY;
+	Styles = (PACKED);
+	Name = LIBNAME(avmediaMacAVF);
+	Dir = SCP2_OOO_BIN_DIR;
+End
+
 #endif // MACOSX
 
 #ifdef OS2


[openoffice] 07/08: Avoid ordered comparison between pointer and zero

Posted by ar...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

arielch pushed a commit to branch AOO418
in repository https://gitbox.apache.org/repos/asf/openoffice.git

commit e2b21863b3b4a632ae31f1c3ca37f10c45da9d88
Author: Ariel Constenla-Haile <ar...@apache.org>
AuthorDate: Sun Oct 20 22:15:32 2019 -0300

    Avoid ordered comparison between pointer and zero
---
 main/desktop/source/app/officeipcthread.cxx     | 2 +-
 main/desktop/source/deployment/misc/dp_misc.cxx | 2 +-
 main/sd/source/ui/view/viewshe3.cxx             | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/main/desktop/source/app/officeipcthread.cxx b/main/desktop/source/app/officeipcthread.cxx
index 90ad4d9..c92d4f9 100644
--- a/main/desktop/source/app/officeipcthread.cxx
+++ b/main/desktop/source/app/officeipcthread.cxx
@@ -225,7 +225,7 @@ String CreateMD5FromString( const OUString& aMsg )
 	// BACK: Str "ababab....0f" Hexcode String
 
 	rtlDigest handle = rtl_digest_create( rtl_Digest_AlgorithmMD5 );
-	if ( handle > 0 )
+	if ( handle != NULL)
 	{
 		const sal_uInt8* pData = (const sal_uInt8*)aMsg.getStr();
 		sal_uInt32		 nSize = ( aMsg.getLength() * sizeof( sal_Unicode ));
diff --git a/main/desktop/source/deployment/misc/dp_misc.cxx b/main/desktop/source/deployment/misc/dp_misc.cxx
index 8e60fad..327df8d 100644
--- a/main/desktop/source/deployment/misc/dp_misc.cxx
+++ b/main/desktop/source/deployment/misc/dp_misc.cxx
@@ -103,7 +103,7 @@ const OUString OfficePipeId::operator () ()
 	}
     
     rtlDigest digest = rtl_digest_create( rtl_Digest_AlgorithmMD5 );
-    if (digest <= 0) {
+    if (digest == NULL) {
         throw RuntimeException(
             OUSTR("cannot get digest rtl_Digest_AlgorithmMD5!"), 0 );
     }
diff --git a/main/sd/source/ui/view/viewshe3.cxx b/main/sd/source/ui/view/viewshe3.cxx
index c4e2c60..a7a2bbc 100644
--- a/main/sd/source/ui/view/viewshe3.cxx
+++ b/main/sd/source/ui/view/viewshe3.cxx
@@ -226,7 +226,7 @@ SdPage* ViewShell::CreateOrDuplicatePage (
     // When the given page is NULL then use the first page of the document.
     SdPage* pTemplatePage = pPage;
     if (pTemplatePage == NULL)
-        if (pDocument->GetSdPage(0, ePageKind) > 0)
+        if (pDocument->GetSdPage(0, ePageKind) != NULL)
             pTemplatePage = pDocument->GetSdPage(0, ePageKind); 
     if (pTemplatePage != NULL && pTemplatePage->TRG_HasMasterPage())
         aVisibleLayers = pTemplatePage->TRG_GetMasterPageVisibleLayers();


[openoffice] 04/08: #i124875# pre-register the Mac AVFoundation component

Posted by ar...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

arielch pushed a commit to branch AOO418
in repository https://gitbox.apache.org/repos/asf/openoffice.git

commit 9c30ce91a9c477a3d60dada7ec4f6552462890bf
Author: Herbert Dürr <hd...@apache.org>
AuthorDate: Tue May 13 12:12:12 2014 +0000

    #i124875# pre-register the Mac AVFoundation component
    
    git-svn-id: https://svn.apache.org/repos/asf/openoffice/trunk@1594208 13f79535-47bb-0310-9956-ffa450edef68
    (cherry picked from commit 426294d4cab3231990b92678965a08bf25c4513f)
---
 main/postprocess/packcomponents/makefile.mk | 1 +
 1 file changed, 1 insertion(+)

diff --git a/main/postprocess/packcomponents/makefile.mk b/main/postprocess/packcomponents/makefile.mk
index 0de3e5b..75989ff 100644
--- a/main/postprocess/packcomponents/makefile.mk
+++ b/main/postprocess/packcomponents/makefile.mk
@@ -314,6 +314,7 @@ my_components += \
 .IF "$(OS)" == "MACOSX"
 my_components += \
     avmediaQuickTime \
+    avmediaMacAVF \
     fps_aqua \
     macab1 \
     macbe1 \


[openoffice] 05/08: #i124875# use AVAsset's best guess duration if AVPlayerItem isn't ready yet

Posted by ar...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

arielch pushed a commit to branch AOO418
in repository https://gitbox.apache.org/repos/asf/openoffice.git

commit deea6bb5c5c20c62b55cee14ce360b38efe7881a
Author: Herbert Dürr <hd...@apache.org>
AuthorDate: Thu May 15 09:46:26 2014 +0000

    #i124875# use AVAsset's best guess duration if AVPlayerItem isn't ready yet
    
    in AV Foundation the most accurate media asset duration is available when the
    AVPlayerItem's status changes to AVPlayerItemStatusReadyToPlay. There already
    is an observer for this, but the upper layers expect getDuration() to be
    synchronous and to return within a reasonable time. Since returning an
    approximation is sufficient using the AVAsset's duration as fallback is fine.
    
    
    git-svn-id: https://svn.apache.org/repos/asf/openoffice/trunk@1594838 13f79535-47bb-0310-9956-ffa450edef68
    (cherry picked from commit 020bbb1d88621b9ceb9fc79a93df7017050e38c6)
---
 main/avmedia/source/macavf/macavf_player.cxx | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/main/avmedia/source/macavf/macavf_player.cxx b/main/avmedia/source/macavf/macavf_player.cxx
index 34c76d4..c9653ec 100644
--- a/main/avmedia/source/macavf/macavf_player.cxx
+++ b/main/avmedia/source/macavf/macavf_player.cxx
@@ -218,7 +218,10 @@ double SAL_CALL Player::getDuration()
     if( mpPlayer )
     {
         AVPlayerItem* pItem = [mpPlayer currentItem];
-        duration = CMTimeGetSeconds( [pItem duration] );
+        if( [pItem status] == AVPlayerItemStatusReadyToPlay )
+            duration = CMTimeGetSeconds( [pItem duration] );
+        else // fall back to AVAsset's best guess
+            duration = CMTimeGetSeconds( [[pItem asset] duration] );
     }
 
     return duration;


[openoffice] 02/08: #i124875# avoid avmedia build problems with multiple active backends

Posted by ar...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

arielch pushed a commit to branch AOO418
in repository https://gitbox.apache.org/repos/asf/openoffice.git

commit 4ba1660956c80eb18b1e904dd49c2cd0d4b9c49e
Author: Herbert Dürr <hd...@apache.org>
AuthorDate: Mon May 12 15:50:40 2014 +0000

    #i124875# avoid avmedia build problems with multiple active backends
    
    in the dmake build environment active header and source files with the
    same name result in problems when in the same project. The Quicktime and
    MacAVF files have been renamed so that both can be active concurrently.
    
    
    git-svn-id: https://svn.apache.org/repos/asf/openoffice/trunk@1594013 13f79535-47bb-0310-9956-ffa450edef68
    (cherry picked from commit e8649ecd8d3aee033309e0ffbb2c2bd3e80b6302)
---
 .../source/macavf/{macavfcommon.hxx => macavf_common.hxx}  |  0
 .../macavf/{framegrabber.cxx => macavf_framegrabber.cxx}   |  4 ++--
 .../macavf/{framegrabber.hxx => macavf_framegrabber.hxx}   |  9 ++++-----
 .../macavf/{macavfcommon.hxx => macavf_macavfcommon.hxx}   |  0
 .../source/macavf/{macavfuno.cxx => macavf_macavfuno.cxx}  |  3 +--
 .../source/macavf/{manager.cxx => macavf_manager.cxx}      |  5 +++--
 .../source/macavf/{manager.hxx => macavf_manager.hxx}      |  8 ++++----
 .../source/macavf/{player.cxx => macavf_player.cxx}        |  6 +++---
 .../source/macavf/{player.hxx => macavf_player.hxx}        | 10 +++++-----
 .../source/macavf/{macavfuno.cxx => macavf_uno.cxx}        |  3 +--
 .../source/macavf/{window.cxx => macavf_window.cxx}        |  5 ++---
 .../source/macavf/{window.hxx => macavf_window.hxx}        |  7 ++++---
 main/avmedia/source/macavf/makefile.mk                     | 14 +++++++-------
 main/avmedia/source/quicktime/makefile.mk                  | 14 +++++++-------
 .../quicktime/{quicktimecommon.hxx => qt_common.hxx}       |  7 +++----
 .../quicktime/{framegrabber.cxx => qt_framegrabber.cxx}    |  5 ++---
 .../quicktime/{framegrabber.hxx => qt_framegrabber.hxx}    | 12 +++++-------
 .../source/quicktime/{manager.cxx => qt_manager.cxx}       |  4 ++--
 .../source/quicktime/{manager.hxx => qt_manager.hxx}       | 12 +++++-------
 .../avmedia/source/quicktime/{player.cxx => qt_player.cxx} |  7 +++----
 .../avmedia/source/quicktime/{player.hxx => qt_player.hxx} | 12 +++++-------
 .../source/quicktime/{quicktimeuno.cxx => qt_uno.cxx}      |  6 ++----
 .../avmedia/source/quicktime/{window.cxx => qt_window.cxx} |  5 ++---
 .../avmedia/source/quicktime/{window.hxx => qt_window.hxx} | 12 +++++-------
 24 files changed, 77 insertions(+), 93 deletions(-)

diff --git a/main/avmedia/source/macavf/macavfcommon.hxx b/main/avmedia/source/macavf/macavf_common.hxx
similarity index 100%
copy from main/avmedia/source/macavf/macavfcommon.hxx
copy to main/avmedia/source/macavf/macavf_common.hxx
diff --git a/main/avmedia/source/macavf/framegrabber.cxx b/main/avmedia/source/macavf/macavf_framegrabber.cxx
similarity index 98%
rename from main/avmedia/source/macavf/framegrabber.cxx
rename to main/avmedia/source/macavf/macavf_framegrabber.cxx
index 1129b90..f9fb5a6 100644
--- a/main/avmedia/source/macavf/framegrabber.cxx
+++ b/main/avmedia/source/macavf/macavf_framegrabber.cxx
@@ -19,8 +19,8 @@
  * 
  *************************************************************/
 
-#include "framegrabber.hxx"
-#include "player.hxx"
+#include "macavf_framegrabber.hxx"
+#include "macavf_player.hxx"
 
 #include <tools/stream.hxx>
 #include <vcl/graph.hxx>
diff --git a/main/avmedia/source/macavf/framegrabber.hxx b/main/avmedia/source/macavf/macavf_framegrabber.hxx
similarity index 94%
rename from main/avmedia/source/macavf/framegrabber.hxx
rename to main/avmedia/source/macavf/macavf_framegrabber.hxx
index bcc095d..c483eda 100644
--- a/main/avmedia/source/macavf/framegrabber.hxx
+++ b/main/avmedia/source/macavf/macavf_framegrabber.hxx
@@ -20,11 +20,10 @@
  *************************************************************/
 
 
+#ifndef MACAVF_FRAMEGRABBER_HXX
+#define MACAVF_FRAMEGRABBER_HXX
 
-#ifndef _FRAMEGRABBER_HXX
-#define _FRAMEGRABBER_HXX
-
-#include "macavfcommon.hxx"
+#include "macavf_common.hxx"
 
 #include "com/sun/star/media/XFrameGrabber.hdl"
 
@@ -62,5 +61,5 @@ private:
 } // namespace macavf
 } // namespace avmedia
 
-#endif // _FRAMEGRABBER_HXX
+#endif // MACAVF_FRAMEGRABBER_HXX
 
diff --git a/main/avmedia/source/macavf/macavfcommon.hxx b/main/avmedia/source/macavf/macavf_macavfcommon.hxx
similarity index 100%
rename from main/avmedia/source/macavf/macavfcommon.hxx
rename to main/avmedia/source/macavf/macavf_macavfcommon.hxx
diff --git a/main/avmedia/source/macavf/macavfuno.cxx b/main/avmedia/source/macavf/macavf_macavfuno.cxx
similarity index 98%
copy from main/avmedia/source/macavf/macavfuno.cxx
copy to main/avmedia/source/macavf/macavf_macavfuno.cxx
index acc0d93..6d936eb 100644
--- a/main/avmedia/source/macavf/macavfuno.cxx
+++ b/main/avmedia/source/macavf/macavf_macavfuno.cxx
@@ -19,8 +19,7 @@
  * 
  *************************************************************/
 
-#include "macavfcommon.hxx"
-#include "manager.hxx"
+#include "macavf_manager.hxx"
 
 using namespace ::com::sun::star;
 
diff --git a/main/avmedia/source/macavf/manager.cxx b/main/avmedia/source/macavf/macavf_manager.cxx
similarity index 98%
rename from main/avmedia/source/macavf/manager.cxx
rename to main/avmedia/source/macavf/macavf_manager.cxx
index c11eb19..8edc6af 100644
--- a/main/avmedia/source/macavf/manager.cxx
+++ b/main/avmedia/source/macavf/macavf_manager.cxx
@@ -19,8 +19,9 @@
  * 
  *************************************************************/
 
-#include "manager.hxx"
-#include "player.hxx"
+#include "macavf_manager.hxx"
+#include "macavf_player.hxx"
+
 #include <tools/urlobj.hxx>
 
 using namespace ::com::sun::star;
diff --git a/main/avmedia/source/macavf/manager.hxx b/main/avmedia/source/macavf/macavf_manager.hxx
similarity index 95%
rename from main/avmedia/source/macavf/manager.hxx
rename to main/avmedia/source/macavf/macavf_manager.hxx
index f8f6ea9..3397b0e 100644
--- a/main/avmedia/source/macavf/manager.hxx
+++ b/main/avmedia/source/macavf/macavf_manager.hxx
@@ -19,10 +19,10 @@
  * 
  *************************************************************/
 
-#ifndef _MANAGER_HXX
-#define _MANAGER_HXX
+#ifndef MACAVF_MANAGER_HXX
+#define MACAVF_MANAGER_HXX
 
-#include "macavfcommon.hxx"
+#include "macavf_common.hxx"
 
 #include "com/sun/star/media/XManager.hdl"
 
@@ -55,5 +55,5 @@ private:
 } // namespace macavf
 } // namespace avmedia
 
-#endif // _MANAGER_HXX
+#endif // MACAVF_MANAGER_HXX
 
diff --git a/main/avmedia/source/macavf/player.cxx b/main/avmedia/source/macavf/macavf_player.cxx
similarity index 99%
rename from main/avmedia/source/macavf/player.cxx
rename to main/avmedia/source/macavf/macavf_player.cxx
index 46a8397..27fd644 100644
--- a/main/avmedia/source/macavf/player.cxx
+++ b/main/avmedia/source/macavf/macavf_player.cxx
@@ -20,9 +20,9 @@
  *************************************************************/
 
 
-#include "player.hxx"
-#include "framegrabber.hxx"
-#include "window.hxx"
+#include "macavf_player.hxx"
+#include "macavf_framegrabber.hxx"
+#include "macavf_window.hxx"
 
 #include <cmath> // for log10()
 
diff --git a/main/avmedia/source/macavf/player.hxx b/main/avmedia/source/macavf/macavf_player.hxx
similarity index 97%
rename from main/avmedia/source/macavf/player.hxx
rename to main/avmedia/source/macavf/macavf_player.hxx
index 10ff013..45f6f86 100644
--- a/main/avmedia/source/macavf/player.hxx
+++ b/main/avmedia/source/macavf/macavf_player.hxx
@@ -20,12 +20,11 @@
  *************************************************************/
 
 
-
-#ifndef _PLAYER_HXX
-#define _PLAYER_HXX
+#ifndef MACAVF_PLAYER_HXX
+#define MACAVF_PLAYER_HXX
 
 #include <osl/conditn.h>
-#include "macavfcommon.hxx"
+#include "macavf_common.hxx"
 
 #include "com/sun/star/media/XPlayer.hdl"
 
@@ -94,4 +93,5 @@ private:
 } // namespace macavf
 } // namespace avmedia
 
-#endif // _PLAYER_HXX
+#endif // MACAVF_PLAYER_HXX
+
diff --git a/main/avmedia/source/macavf/macavfuno.cxx b/main/avmedia/source/macavf/macavf_uno.cxx
similarity index 98%
rename from main/avmedia/source/macavf/macavfuno.cxx
rename to main/avmedia/source/macavf/macavf_uno.cxx
index acc0d93..6d936eb 100644
--- a/main/avmedia/source/macavf/macavfuno.cxx
+++ b/main/avmedia/source/macavf/macavf_uno.cxx
@@ -19,8 +19,7 @@
  * 
  *************************************************************/
 
-#include "macavfcommon.hxx"
-#include "manager.hxx"
+#include "macavf_manager.hxx"
 
 using namespace ::com::sun::star;
 
diff --git a/main/avmedia/source/macavf/window.cxx b/main/avmedia/source/macavf/macavf_window.cxx
similarity index 99%
rename from main/avmedia/source/macavf/window.cxx
rename to main/avmedia/source/macavf/macavf_window.cxx
index f9e68f7..2d579ed 100644
--- a/main/avmedia/source/macavf/window.cxx
+++ b/main/avmedia/source/macavf/macavf_window.cxx
@@ -20,12 +20,11 @@
  *************************************************************/
 
 
-
 #include <com/sun/star/awt/SystemPointer.hpp>
 #include <com/sun/star/awt/PosSize.hpp>
 
-#include "window.hxx"
-#include "player.hxx"
+#include "macavf_window.hxx"
+#include "macavf_player.hxx"
 
 using namespace ::com::sun::star;
 
diff --git a/main/avmedia/source/macavf/window.hxx b/main/avmedia/source/macavf/macavf_window.hxx
similarity index 98%
rename from main/avmedia/source/macavf/window.hxx
rename to main/avmedia/source/macavf/macavf_window.hxx
index 83977c2..db2f5fc 100644
--- a/main/avmedia/source/macavf/window.hxx
+++ b/main/avmedia/source/macavf/macavf_window.hxx
@@ -19,10 +19,11 @@
  * 
  *************************************************************/
 
-#ifndef _WINDOW_HXX
-#define _WINDOW_HXX
+#ifndef MACAVF_WINDOW_HXX
+#define MACAVF_WINDOW_HXX
+
+#include "macavf_common.hxx"
 
-#include "macavfcommon.hxx"
 #include <cppuhelper/interfacecontainer.h>
 
 #include "com/sun/star/media/XPlayerWindow.hdl"
diff --git a/main/avmedia/source/macavf/makefile.mk b/main/avmedia/source/macavf/makefile.mk
index 542ba0a..95cc0a8 100644
--- a/main/avmedia/source/macavf/makefile.mk
+++ b/main/avmedia/source/macavf/makefile.mk
@@ -41,15 +41,15 @@ CDEFS+= -DVERBOSE
 CFLAGSCXX+=$(OBJCXXFLAGS)
 
 SLOFILES= \
-		$(SLO)$/macavfuno.obj  \
-		$(SLO)$/framegrabber.obj        \
-		$(SLO)$/manager.obj       \
-		$(SLO)$/window.obj        \
-		$(SLO)$/player.obj
+		$(SLO)$/macavf_uno.obj           \
+		$(SLO)$/macavf_framegrabber.obj  \
+		$(SLO)$/macavf_manager.obj       \
+		$(SLO)$/macavf_window.obj        \
+		$(SLO)$/macavf_player.obj
 
 EXCEPTIONSFILES= \
-		$(SLO)$/framegrabber.obj        \
-		$(SLO)$/macavfuno.obj
+		$(SLO)$/macavf_framegrabber.obj \
+		$(SLO)$/macavf_uno.obj
 
 SHL1TARGET= $(TARGET)$(DLLPOSTFIX)
 
diff --git a/main/avmedia/source/quicktime/makefile.mk b/main/avmedia/source/quicktime/makefile.mk
index 6b83b93..afd0384 100644
--- a/main/avmedia/source/quicktime/makefile.mk
+++ b/main/avmedia/source/quicktime/makefile.mk
@@ -44,15 +44,15 @@ CDEFS+= -DVERBOSE
 CFLAGSCXX+=$(OBJCXXFLAGS)
 
 SLOFILES= \
-		$(SLO)$/quicktimeuno.obj  \
-		$(SLO)$/framegrabber.obj        \
-		$(SLO)$/manager.obj       \
-		$(SLO)$/window.obj        \
-		$(SLO)$/player.obj
+		$(SLO)$/qt_uno.obj  \
+		$(SLO)$/qt_framegrabber.obj        \
+		$(SLO)$/qt_manager.obj       \
+		$(SLO)$/qt_window.obj        \
+		$(SLO)$/qt_player.obj
 
 EXCEPTIONSFILES= \
-		$(SLO)$/framegrabber.obj        \
-		$(SLO)$/quicktimeuno.obj
+		$(SLO)$/qt_framegrabber.obj        \
+		$(SLO)$/qt_uno.obj
 
 SHL1TARGET= $(TARGET)$(DLLPOSTFIX)
 
diff --git a/main/avmedia/source/quicktime/quicktimecommon.hxx b/main/avmedia/source/quicktime/qt_common.hxx
similarity index 96%
rename from main/avmedia/source/quicktime/quicktimecommon.hxx
rename to main/avmedia/source/quicktime/qt_common.hxx
index 42f9634..f4102e6 100644
--- a/main/avmedia/source/quicktime/quicktimecommon.hxx
+++ b/main/avmedia/source/quicktime/qt_common.hxx
@@ -20,9 +20,8 @@
  *************************************************************/
 
 
-
-#ifndef _QUICKTIMECOMMON_HXX
-#define _QUICKTIMECOMMON_HXX
+#ifndef QT_COMMON_HXX
+#define QT_COMMON_HXX
 
 #ifdef MACOSX
 #include <premac.h>
@@ -62,5 +61,5 @@
 #define AVMEDIA_QUICKTIME_WINDOW_IMPLEMENTATIONNAME "com.sun.star.comp.avmedia.Window_QuickTime"
 #define AVMEDIA_QUICKTIME_WINDOW_SERVICENAME "com.sun.star.media.Window_QuickTime"
 
-#endif // _QUICKTIMECOMMOM_HXX
+#endif // QT_COMMOM_HXX
 
diff --git a/main/avmedia/source/quicktime/framegrabber.cxx b/main/avmedia/source/quicktime/qt_framegrabber.cxx
similarity index 98%
rename from main/avmedia/source/quicktime/framegrabber.cxx
rename to main/avmedia/source/quicktime/qt_framegrabber.cxx
index 5d90192..dbbb3f7 100644
--- a/main/avmedia/source/quicktime/framegrabber.cxx
+++ b/main/avmedia/source/quicktime/qt_framegrabber.cxx
@@ -20,9 +20,8 @@
  *************************************************************/
 
 
-
-#include "framegrabber.hxx"
-#include "player.hxx"
+#include "qt_framegrabber.hxx"
+#include "qt_player.hxx"
 
 #include <tools/stream.hxx>
 #include <vcl/graph.hxx>
diff --git a/main/avmedia/source/quicktime/framegrabber.hxx b/main/avmedia/source/quicktime/qt_framegrabber.hxx
similarity index 93%
rename from main/avmedia/source/quicktime/framegrabber.hxx
rename to main/avmedia/source/quicktime/qt_framegrabber.hxx
index 7dc9afe..c59eb6b 100644
--- a/main/avmedia/source/quicktime/framegrabber.hxx
+++ b/main/avmedia/source/quicktime/qt_framegrabber.hxx
@@ -20,15 +20,12 @@
  *************************************************************/
 
 
+#ifndef QT_FRAMEGRABBER_HXX
+#define QT_FRAMEGRABBER_HXX
 
-#ifndef _FRAMEGRABBER_HXX
-#define _FRAMEGRABBER_HXX
+#include "qt_common.hxx"
 
-#include "quicktimecommon.hxx"
-
-#ifndef _COM_SUN_STAR_MEDIA_XFRAMEGRABBER_HDL_
 #include "com/sun/star/media/XFrameGrabber.hdl"
-#endif
 
 namespace avmedia { namespace quicktime {
 
@@ -66,4 +63,5 @@ private:
 } // namespace quicktime
 } // namespace avmedia
 
-#endif // _FRAMEGRABBER_HXX
+#endif // QT_FRAMEGRABBER_HXX
+
diff --git a/main/avmedia/source/quicktime/manager.cxx b/main/avmedia/source/quicktime/qt_manager.cxx
similarity index 98%
rename from main/avmedia/source/quicktime/manager.cxx
rename to main/avmedia/source/quicktime/qt_manager.cxx
index 78794c1..fdf8240 100644
--- a/main/avmedia/source/quicktime/manager.cxx
+++ b/main/avmedia/source/quicktime/qt_manager.cxx
@@ -20,9 +20,9 @@
  *************************************************************/
 
 
+#include "qt_manager.hxx"
+#include "qt_player.hxx"
 
-#include "manager.hxx"
-#include "player.hxx"
 #include <tools/urlobj.hxx>
 
 using namespace ::com::sun::star;
diff --git a/main/avmedia/source/quicktime/manager.hxx b/main/avmedia/source/quicktime/qt_manager.hxx
similarity index 93%
rename from main/avmedia/source/quicktime/manager.hxx
rename to main/avmedia/source/quicktime/qt_manager.hxx
index b90916a..9cceb4a 100644
--- a/main/avmedia/source/quicktime/manager.hxx
+++ b/main/avmedia/source/quicktime/qt_manager.hxx
@@ -20,15 +20,12 @@
  *************************************************************/
 
 
+#ifndef QT_MANAGER_HXX
+#define QT_MANAGER_HXX
 
-#ifndef _MANAGER_HXX
-#define _MANAGER_HXX
+#include "qt_common.hxx"
 
-#include "quicktimecommon.hxx"
-
-#ifndef _COM_SUN_STAR_MEDIA_XMANAGER_HDL_
 #include "com/sun/star/media/XManager.hdl"
-#endif
 
 // -----------
 // - Manager -
@@ -59,4 +56,5 @@ private:
 } // namespace quicktime
 } // namespace avmedia
 
-#endif // _MANAGER_HXX
+#endif // QT_MANAGER_HXX
+
diff --git a/main/avmedia/source/quicktime/player.cxx b/main/avmedia/source/quicktime/qt_player.cxx
similarity index 99%
rename from main/avmedia/source/quicktime/player.cxx
rename to main/avmedia/source/quicktime/qt_player.cxx
index b98693c..fcb88c5 100644
--- a/main/avmedia/source/quicktime/player.cxx
+++ b/main/avmedia/source/quicktime/qt_player.cxx
@@ -20,12 +20,11 @@
  *************************************************************/
 
 
-
 #include <math.h>
 
-#include "player.hxx"
-#include "framegrabber.hxx"
-#include "window.hxx"
+#include "qt_player.hxx"
+#include "qt_framegrabber.hxx"
+#include "qt_window.hxx"
 
 using namespace ::com::sun::star;
 
diff --git a/main/avmedia/source/quicktime/player.hxx b/main/avmedia/source/quicktime/qt_player.hxx
similarity index 97%
rename from main/avmedia/source/quicktime/player.hxx
rename to main/avmedia/source/quicktime/qt_player.hxx
index b9811da..9f9274b 100644
--- a/main/avmedia/source/quicktime/player.hxx
+++ b/main/avmedia/source/quicktime/qt_player.hxx
@@ -20,16 +20,13 @@
  *************************************************************/
 
 
-
-#ifndef _PLAYER_HXX
-#define _PLAYER_HXX
+#ifndef QT_PLAYER_HXX
+#define QT_PLAYER_HXX
 
 #include <osl/conditn.h>
-#include "quicktimecommon.hxx"
+#include "qt_common.hxx"
 
-#ifndef _COM_SUN_STAR_MEDIA_XPLAYER_HDL_
 #include "com/sun/star/media/XPlayer.hdl"
-#endif
 
 namespace avmedia { namespace quicktime {
 
@@ -106,4 +103,5 @@ private:
 } // namespace quicktime
 } // namespace avmedia
 
-#endif // _PLAYER_HXX
+#endif // QT_PLAYER_HXX
+
diff --git a/main/avmedia/source/quicktime/quicktimeuno.cxx b/main/avmedia/source/quicktime/qt_uno.cxx
similarity index 97%
rename from main/avmedia/source/quicktime/quicktimeuno.cxx
rename to main/avmedia/source/quicktime/qt_uno.cxx
index b987f16..1f39fbf 100644
--- a/main/avmedia/source/quicktime/quicktimeuno.cxx
+++ b/main/avmedia/source/quicktime/qt_uno.cxx
@@ -19,10 +19,7 @@
  * 
  *************************************************************/
 
-
-
-#include "quicktimecommon.hxx"
-#include "manager.hxx"
+#include "qt_manager.hxx"
 
 using namespace ::com::sun::star;
 
@@ -71,3 +68,4 @@ extern "C" void* SAL_CALL component_getFactory( const sal_Char* pImplName, void*
 
 	return pRet;
 }
+
diff --git a/main/avmedia/source/quicktime/window.cxx b/main/avmedia/source/quicktime/qt_window.cxx
similarity index 99%
rename from main/avmedia/source/quicktime/window.cxx
rename to main/avmedia/source/quicktime/qt_window.cxx
index b519101..73887ab 100644
--- a/main/avmedia/source/quicktime/window.cxx
+++ b/main/avmedia/source/quicktime/qt_window.cxx
@@ -20,12 +20,11 @@
  *************************************************************/
 
 
-
 #include <com/sun/star/awt/SystemPointer.hpp>
 #include <com/sun/star/awt/PosSize.hpp>
 
-#include "window.hxx"
-#include "player.hxx"
+#include "qt_window.hxx"
+#include "qt_player.hxx"
 
 using namespace ::com::sun::star;
 
diff --git a/main/avmedia/source/quicktime/window.hxx b/main/avmedia/source/quicktime/qt_window.hxx
similarity index 97%
rename from main/avmedia/source/quicktime/window.hxx
rename to main/avmedia/source/quicktime/qt_window.hxx
index 24b837f..9babf0d 100644
--- a/main/avmedia/source/quicktime/window.hxx
+++ b/main/avmedia/source/quicktime/qt_window.hxx
@@ -20,16 +20,13 @@
  *************************************************************/
 
 
+#ifndef QT_WINDOW_HXX
+#define QT_WINDOW_HXX
 
-#ifndef _WINDOW_HXX
-#define _WINDOW_HXX
-
-#include "quicktimecommon.hxx"
+#include "qt_common.hxx"
 #include <cppuhelper/interfacecontainer.h>
 
-#ifndef _COM_SUN_STAR_MEDIA_XPLAYERWINDOW_HDL_
 #include "com/sun/star/media/XPlayerWindow.hdl"
-#endif
 
 namespace avmedia { namespace quicktime {
 
@@ -108,4 +105,5 @@ private:
 } // namespace quicktime
 } // namespace avmedia
 
-#endif // _WINDOW_HXX
+#endif // QT_WINDOW_HXX
+


Re: [openoffice] 06/08: i127138 Remove the avmedia Quicktime plugin

Posted by Jim Jagielski <ji...@jaguNET.com>.
Could you also commit to the AOO42X branch as well, please?

> On Oct 20, 2019, at 9:27 PM, arielch@apache.org wrote:
> 
> This is an automated email from the ASF dual-hosted git repository.
> 
> arielch pushed a commit to branch AOO418
> in repository https://gitbox.apache.org/repos/asf/openoffice.git
> 
> commit fcb37b405ef0ebca13b5f800b6159882d09b3416
> Author: Ariel Constenla-Haile <ar...@apache.org>
> AuthorDate: Sun Oct 20 01:27:11 2019 -0300
> 
>   

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
For additional commands, e-mail: dev-help@openoffice.apache.org


[openoffice] 06/08: i127138 Remove the avmedia Quicktime plugin

Posted by ar...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

arielch pushed a commit to branch AOO418
in repository https://gitbox.apache.org/repos/asf/openoffice.git

commit fcb37b405ef0ebca13b5f800b6159882d09b3416
Author: Ariel Constenla-Haile <ar...@apache.org>
AuthorDate: Sun Oct 20 01:27:11 2019 -0300

    i127138 Remove the avmedia Quicktime plugin
    
    (cherry picked from commit 845e2aaed316432f79097128de0c3797d5756a54)
---
 main/avmedia/prj/build.lst                         |   5 +-
 main/avmedia/prj/d.lst                             |   1 -
 main/avmedia/source/inc/mediamisc.hxx              |   4 +-
 .../source/quicktime/avmediaQuickTime.component    |  28 --
 main/avmedia/source/quicktime/makefile.mk          |  92 -----
 main/avmedia/source/quicktime/qt_common.hxx        |  65 ---
 main/avmedia/source/quicktime/qt_framegrabber.cxx  | 142 -------
 main/avmedia/source/quicktime/qt_framegrabber.hxx  |  67 ---
 main/avmedia/source/quicktime/qt_manager.cxx       |  92 -----
 main/avmedia/source/quicktime/qt_manager.hxx       |  60 ---
 main/avmedia/source/quicktime/qt_player.cxx        | 459 ---------------------
 main/avmedia/source/quicktime/qt_player.hxx        | 107 -----
 main/avmedia/source/quicktime/qt_uno.cxx           |  71 ----
 main/avmedia/source/quicktime/qt_window.cxx        | 348 ----------------
 main/avmedia/source/quicktime/qt_window.hxx        | 109 -----
 main/postprocess/packcomponents/makefile.mk        |   1 -
 main/scp2/source/ooo/file_library_ooo.scp          |   7 -
 main/vcl/Library_vcl.mk                            |   3 -
 main/vcl/aqua/source/dtrans/PictToBmpFlt.cxx       |   1 -
 main/vcl/util/makefile.mk                          |   5 -
 20 files changed, 4 insertions(+), 1663 deletions(-)

diff --git a/main/avmedia/prj/build.lst b/main/avmedia/prj/build.lst
index 6b4ba9c..96f2aa7 100644
--- a/main/avmedia/prj/build.lst
+++ b/main/avmedia/prj/build.lst
@@ -6,7 +6,6 @@ av  avmedia\source\viewer		nmake	-	all	av_viewer	        									NULL
 av  avmedia\source\framework	nmake	-	all	av_framework	        								NULL
 av  avmedia\source\win	    	nmake	-	all	av_win	            									NULL
 av	avmedia\source\java			nmake	-	all	av_java	            									NULL
-av	avmedia\source\quicktime	nmake	-	all	av_quicktime											NULL
-av	avmedia\source\macavf	nmake	-	all	av_macavf											NULL
+av	avmedia\source\macavf       nmake	-	all	av_macavf				    							NULL
 av	avmedia\source\gstreamer	nmake	-	all	av_gstreamer	            							NULL
-av	avmedia\util				nmake	-	all	av_util av_viewer av_framework av_win av_java av_quicktime av_gstreamer	NULL
+av	avmedia\util				nmake	-	all	av_util av_viewer av_framework av_win av_java av_gstreamer	NULL
diff --git a/main/avmedia/prj/d.lst b/main/avmedia/prj/d.lst
index 86c6119..dad565e 100644
--- a/main/avmedia/prj/d.lst
+++ b/main/avmedia/prj/d.lst
@@ -18,7 +18,6 @@ mkdir: %_DEST%\inc%_EXT%\avmedia
 ..\%__SRC%\class\avmedia.jar %_DEST%\bin%_EXT%\avmedia.jar
 ..\%__SRC%\misc\avmedia.component %_DEST%\xml%_EXT%\avmedia.component
 ..\%__SRC%\misc\avmedia.jar.component %_DEST%\xml%_EXT%\avmedia.jar.component
-..\%__SRC%\misc\avmediaQuickTime.component %_DEST%\xml%_EXT%\avmediaQuickTime.component
 ..\%__SRC%\misc\avmediaMacAVF.component %_DEST%\xml%_EXT%\avmediaMacAVF.component
 ..\%__SRC%\misc\avmediagst.component %_DEST%\xml%_EXT%\avmediagst.component
 ..\%__SRC%\misc\avmediawin.component %_DEST%\xml%_EXT%\avmediawin.component
diff --git a/main/avmedia/source/inc/mediamisc.hxx b/main/avmedia/source/inc/mediamisc.hxx
index 5a4a276..1a405d7 100644
--- a/main/avmedia/source/inc/mediamisc.hxx
+++ b/main/avmedia/source/inc/mediamisc.hxx
@@ -36,10 +36,10 @@ class ResMgr;
 #else
 #ifdef QUARTZ
 
-#define AVMEDIA_MANAGER_SERVICE_NAME                    "com.sun.star.comp.avmedia.Manager_QuickTime"
+#define AVMEDIA_MANAGER_SERVICE_NAME                    "com.sun.star.comp.avmedia.Manager_MacAVF"
 #define AVMEDIA_MANAGER_SERVICE_IS_JAVABASED            sal_False
 
-#define AVMEDIA_MANAGER_SERVICE_NAME_FALLBACK1           "com.sun.star.comp.avmedia.Manager_MacAVF"
+#define AVMEDIA_MANAGER_SERVICE_NAME_FALLBACK1           ""
 #define AVMEDIA_MANAGER_SERVICE_IS_JAVABASED_FALLBACK1  sal_False
 
 #else
diff --git a/main/avmedia/source/quicktime/avmediaQuickTime.component b/main/avmedia/source/quicktime/avmediaQuickTime.component
deleted file mode 100644
index dbbd6bd..0000000
--- a/main/avmedia/source/quicktime/avmediaQuickTime.component
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--***********************************************************
- * 
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- * 
- *   http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- * 
- ***********************************************************-->
-
-<component loader="com.sun.star.loader.SharedLibrary"
-    xmlns="http://openoffice.org/2010/uno-components">
-  <implementation name="com.sun.star.comp.avmedia.Manager_QuickTime">
-    <service name="com.sun.star.media.Manager_QuickTime"/>
-  </implementation>
-</component>
diff --git a/main/avmedia/source/quicktime/makefile.mk b/main/avmedia/source/quicktime/makefile.mk
deleted file mode 100644
index afd0384..0000000
--- a/main/avmedia/source/quicktime/makefile.mk
+++ /dev/null
@@ -1,92 +0,0 @@
-#**************************************************************
-#  
-#  Licensed to the Apache Software Foundation (ASF) under one
-#  or more contributor license agreements.  See the NOTICE file
-#  distributed with this work for additional information
-#  regarding copyright ownership.  The ASF licenses this file
-#  to you under the Apache License, Version 2.0 (the
-#  "License"); you may not use this file except in compliance
-#  with the License.  You may obtain a copy of the License at
-#  
-#    http://www.apache.org/licenses/LICENSE-2.0
-#  
-#  Unless required by applicable law or agreed to in writing,
-#  software distributed under the License is distributed on an
-#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-#  KIND, either express or implied.  See the License for the
-#  specific language governing permissions and limitations
-#  under the License.
-#  
-#**************************************************************
-
-
-
-PRJ=..$/..
-PRJNAME=avmedia
-TARGET=avmediaQuickTime
-
-# the QuickTime API has been deprecated since OSX 10.5 and has been removed in the OSX SDK 10.7
-.IF "$(GUIBASE)" != "aqua"
-dummy:
-	@echo " Nothing to build for GUIBASE=$(GUIBASE) and OSX$(MACOSX_DEPLOYMENT_TARGET)"
-.ELSE
-
-# --- Settings ----------------------------------
-
-.INCLUDE :  	settings.mk
-
-.IF "$(verbose)"!="" || "$(VERBOSE)"!=""
-CDEFS+= -DVERBOSE
-.ENDIF
-
-# --- Files ----------------------------------
-
-CFLAGSCXX+=$(OBJCXXFLAGS)
-
-SLOFILES= \
-		$(SLO)$/qt_uno.obj  \
-		$(SLO)$/qt_framegrabber.obj        \
-		$(SLO)$/qt_manager.obj       \
-		$(SLO)$/qt_window.obj        \
-		$(SLO)$/qt_player.obj
-
-EXCEPTIONSFILES= \
-		$(SLO)$/qt_framegrabber.obj        \
-		$(SLO)$/qt_uno.obj
-
-SHL1TARGET= $(TARGET)$(DLLPOSTFIX)
-
-SHL1STDLIBS= \
-             $(CPPULIB) \
-             $(SALLIB)  \
-             $(COMPHELPERLIB) \
-             $(CPPUHELPERLIB) \
-             $(TOOLSLIB) \
-             $(VCLLIB) 
-
-SHL1STDLIBS+= \
-             -framework Cocoa \
-             -framework QTKit \
-             -framework QuickTime
-
-# build DLL
-SHL1LIBS=$(SLB)$/$(TARGET).lib
-SHL1IMPLIB=i$(TARGET)
-SHL1DEF=$(MISC)$/$(SHL1TARGET).def
-
-SHL1VERSIONMAP=$(SOLARENV)/src/component.map
-
-# --- Targets ------------------------------------------------------
-
-.INCLUDE : target.mk
-
-.ENDIF
-
-ALLTAR : $(MISC)/avmediaQuickTime.component
-
-$(MISC)/avmediaQuickTime.component .ERRREMOVE : \
-        $(SOLARENV)/bin/createcomponent.xslt avmediaQuickTime.component
-    $(XSLTPROC) --nonet --stringparam uri \
-        '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
-        $(SOLARENV)/bin/createcomponent.xslt avmediaQuickTime.component
-
diff --git a/main/avmedia/source/quicktime/qt_common.hxx b/main/avmedia/source/quicktime/qt_common.hxx
deleted file mode 100644
index f4102e6..0000000
--- a/main/avmedia/source/quicktime/qt_common.hxx
+++ /dev/null
@@ -1,65 +0,0 @@
-/**************************************************************
- * 
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- * 
- *   http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- * 
- *************************************************************/
-
-
-#ifndef QT_COMMON_HXX
-#define QT_COMMON_HXX
-
-#ifdef MACOSX
-#include <premac.h>
-#import <Cocoa/Cocoa.h>
-#import <QTKit/QTKit.h>
-#include <postmac.h>
-#endif
-#include <osl/mutex.hxx>
-#include <rtl/ustring.hxx>
-#include <tools/debug.hxx>
-#include <tools/stream.hxx>
-#include <tools/string.hxx>
-#include <tools/urlobj.hxx>
-#include <cppuhelper/implbase1.hxx>
-#include <cppuhelper/implbase2.hxx>
-#include <cppuhelper/weak.hxx>
-#include <cppuhelper/factory.hxx>
-
-#include <com/sun/star/uno/Reference.h>
-#include <com/sun/star/uno/RuntimeException.hpp>
-#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#include <com/sun/star/lang/XComponent.hpp>
-#include <com/sun/star/registry/XRegistryKey.hpp>
-#include <com/sun/star/lang/XComponent.hpp>
-#include <com/sun/star/lang/XServiceInfo.hpp>
-#include <com/sun/star/awt/Rectangle.hpp>
-#include <com/sun/star/awt/KeyModifier.hpp>
-#include <com/sun/star/awt/MouseButton.hpp>
-#include <com/sun/star/media/XManager.hpp>
-
-#define AVMEDIA_QUICKTIME_MANAGER_IMPLEMENTATIONNAME "com.sun.star.comp.avmedia.Manager_QuickTime"
-#define AVMEDIA_QUICKTIME_MANAGER_SERVICENAME "com.sun.star.media.Manager_QuickTime"
-
-#define AVMEDIA_QUICKTIME_PLAYER_IMPLEMENTATIONNAME "com.sun.star.comp.avmedia.Player_QuickTime"
-#define AVMEDIA_QUICKTIME_PLAYER_SERVICENAME "com.sun.star.media.Player_QuickTime"
-
-#define AVMEDIA_QUICKTIME_WINDOW_IMPLEMENTATIONNAME "com.sun.star.comp.avmedia.Window_QuickTime"
-#define AVMEDIA_QUICKTIME_WINDOW_SERVICENAME "com.sun.star.media.Window_QuickTime"
-
-#endif // QT_COMMOM_HXX
-
diff --git a/main/avmedia/source/quicktime/qt_framegrabber.cxx b/main/avmedia/source/quicktime/qt_framegrabber.cxx
deleted file mode 100644
index dbbb3f7..0000000
--- a/main/avmedia/source/quicktime/qt_framegrabber.cxx
+++ /dev/null
@@ -1,142 +0,0 @@
-/**************************************************************
- * 
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- * 
- *   http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- * 
- *************************************************************/
-
-
-#include "qt_framegrabber.hxx"
-#include "qt_player.hxx"
-
-#include <tools/stream.hxx>
-#include <vcl/graph.hxx>
-#include <vcl/cvtgrf.hxx>
-#include <unotools/localfilehelper.hxx>
-
-#define AVMEDIA_QUICKTIME_FRAMEGRABBER_IMPLEMENTATIONNAME "com.sun.star.comp.avmedia.FrameGrabber_Quicktime"
-#define AVMEDIA_QUICKTIME_FRAMEGRABBER_SERVICENAME "com.sun.star.media.FrameGrabber_Quicktime"
-
-using namespace ::com::sun::star;
-
-namespace avmedia { namespace quicktime {
-
-// ----------------
-// - FrameGrabber -
-// ----------------
-
-FrameGrabber::FrameGrabber( const uno::Reference< lang::XMultiServiceFactory >& rxMgr ) :
-    mxMgr( rxMgr )
-{
-    OSErr result;
-
-	NSAutoreleasePool* pool	= [[NSAutoreleasePool alloc] init];
-      // we have version 7.01 or later, initialize
-      mpMovie = [QTMovie movie];
-      [mpMovie retain];
-	  mbInitialized = true;
-    [pool release];
-}
-
-// ------------------------------------------------------------------------------
-
-FrameGrabber::~FrameGrabber()
-{
-    if( mbInitialized )
-    {
-        if( mpMovie )
-        {
-            [mpMovie release];
-            mpMovie = nil;
-	    }
-    }
-}
-
-// ------------------------------------------------------------------------------
-
-bool FrameGrabber::create( const ::rtl::OUString& rURL )
-{
-    bool bRet = false;
-    maURL = rURL;
-	NSAutoreleasePool* pool	= [[NSAutoreleasePool alloc] init];
-    NSString* aNSStr = [[[NSString alloc] initWithCharacters: rURL.getStr() length: rURL.getLength()]stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding] ;
-    NSURL* aURL = [NSURL URLWithString:aNSStr ];
-
-    // create the Movie
-
-        mpMovie = [mpMovie initWithURL:aURL error:nil];
-        if(mpMovie)
-        {   
-            [mpMovie retain];
-            bRet = true;
-        }
-
-    [pool release];
-
-    return( bRet );
-}
-
-// ------------------------------------------------------------------------------
-
-uno::Reference< graphic::XGraphic > SAL_CALL FrameGrabber::grabFrame( double fMediaTime )
-    throw (uno::RuntimeException)
-{
-    uno::Reference< graphic::XGraphic > xRet;
-    
-    NSImage* pImage = [mpMovie frameImageAtTime: QTMakeTimeWithTimeInterval(fMediaTime)];
-    NSData *pBitmap = [pImage TIFFRepresentation];
-    long nSize = [pBitmap length];
-    const void* pBitmapData = [pBitmap bytes];
-    SvMemoryStream  aMemStm( (char *)pBitmapData, nSize, STREAM_READ | STREAM_WRITE );
-    Graphic aGraphic;
-    if ( GraphicConverter::Import( aMemStm, aGraphic, CVT_TIF ) == ERRCODE_NONE )
-    {
-        xRet = aGraphic.GetXGraphic();
-    }
-
-    return xRet;
-}
-
-// ------------------------------------------------------------------------------
-
-::rtl::OUString SAL_CALL FrameGrabber::getImplementationName(  )
-    throw (uno::RuntimeException)
-{
-    return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( AVMEDIA_QUICKTIME_FRAMEGRABBER_IMPLEMENTATIONNAME ) );
-}
-
-// ------------------------------------------------------------------------------
-
-sal_Bool SAL_CALL FrameGrabber::supportsService( const ::rtl::OUString& ServiceName )
-    throw (uno::RuntimeException)
-{
-    return ServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM ( AVMEDIA_QUICKTIME_FRAMEGRABBER_SERVICENAME ) );
-}
-
-// ------------------------------------------------------------------------------
-
-uno::Sequence< ::rtl::OUString > SAL_CALL FrameGrabber::getSupportedServiceNames(  )
-    throw (uno::RuntimeException)
-{
-    uno::Sequence< ::rtl::OUString > aRet(1);
-    aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( AVMEDIA_QUICKTIME_FRAMEGRABBER_SERVICENAME ) );
-
-    return aRet;
-}
-
-} // namespace quicktime
-} // namespace avmedia
diff --git a/main/avmedia/source/quicktime/qt_framegrabber.hxx b/main/avmedia/source/quicktime/qt_framegrabber.hxx
deleted file mode 100644
index c59eb6b..0000000
--- a/main/avmedia/source/quicktime/qt_framegrabber.hxx
+++ /dev/null
@@ -1,67 +0,0 @@
-/**************************************************************
- * 
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- * 
- *   http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- * 
- *************************************************************/
-
-
-#ifndef QT_FRAMEGRABBER_HXX
-#define QT_FRAMEGRABBER_HXX
-
-#include "qt_common.hxx"
-
-#include "com/sun/star/media/XFrameGrabber.hdl"
-
-namespace avmedia { namespace quicktime {
-
-// ----------------
-// - FrameGrabber -
-// ----------------
-
-class FrameGrabber : public ::cppu::WeakImplHelper2 < ::com::sun::star::media::XFrameGrabber,
-                                                      ::com::sun::star::lang::XServiceInfo >
-{
-public:
-
-            FrameGrabber( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& rxMgr );
-            ~FrameGrabber();
-
-    bool    create( const ::rtl::OUString& rURL );
-
-    // XFrameGrabber
-    virtual ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic > SAL_CALL grabFrame( double fMediaTime ) throw (::com::sun::star::uno::RuntimeException);
-
-    // XServiceInfo
-    virtual ::rtl::OUString SAL_CALL getImplementationName(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException);
-    virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames(  ) throw (::com::sun::star::uno::RuntimeException);
-
-private:
-
-    ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >    mxMgr;
-    ::rtl::OUString                                                                     maURL;
-	QTMovie*                                                                            mpMovie; 
-    sal_Bool																			mbInitialized;
-    long																				mnVersion;
-};
-
-} // namespace quicktime
-} // namespace avmedia
-
-#endif // QT_FRAMEGRABBER_HXX
-
diff --git a/main/avmedia/source/quicktime/qt_manager.cxx b/main/avmedia/source/quicktime/qt_manager.cxx
deleted file mode 100644
index fdf8240..0000000
--- a/main/avmedia/source/quicktime/qt_manager.cxx
+++ /dev/null
@@ -1,92 +0,0 @@
-/**************************************************************
- * 
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- * 
- *   http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- * 
- *************************************************************/
-
-
-#include "qt_manager.hxx"
-#include "qt_player.hxx"
-
-#include <tools/urlobj.hxx>
-
-using namespace ::com::sun::star;
-
-namespace avmedia { namespace quicktime {
-// ----------------
-// - Manager -
-// ----------------
-
-Manager::Manager( const uno::Reference< lang::XMultiServiceFactory >& rxMgr ) :
-    mxMgr( rxMgr )
-{
-    OSL_TRACE( "avmediaquicktime: Manager::Manager" );
-}
-
-// ------------------------------------------------------------------------------
-
-Manager::~Manager()
-{
-}
-
-// ------------------------------------------------------------------------------
-
-uno::Reference< media::XPlayer > SAL_CALL Manager::createPlayer( const ::rtl::OUString& rURL )
-    throw (uno::RuntimeException)
-{
-    Player*                             pPlayer( new Player( mxMgr ) );
-    uno::Reference< media::XPlayer >    xRet( pPlayer );
-    INetURLObject                       aURL( rURL );
-
-    OSL_TRACE( "avmediaquicktime: Manager::createPlayer" );
-
-    if( !pPlayer->create( aURL.GetMainURL( INetURLObject::DECODE_UNAMBIGUOUS ) )  )
-        xRet = uno::Reference< media::XPlayer >();
-
-    return xRet;
-}
-
-// ------------------------------------------------------------------------------
-
-::rtl::OUString SAL_CALL Manager::getImplementationName(  )
-    throw (uno::RuntimeException)
-{
-    return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( AVMEDIA_QUICKTIME_MANAGER_IMPLEMENTATIONNAME ) );
-}
-
-// ------------------------------------------------------------------------------
-
-sal_Bool SAL_CALL Manager::supportsService( const ::rtl::OUString& ServiceName )
-    throw (uno::RuntimeException)
-{
-    return ServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM ( AVMEDIA_QUICKTIME_MANAGER_SERVICENAME ) );
-}
-
-// ------------------------------------------------------------------------------
-
-uno::Sequence< ::rtl::OUString > SAL_CALL Manager::getSupportedServiceNames(  )
-    throw (uno::RuntimeException)
-{
-    uno::Sequence< ::rtl::OUString > aRet(1);
-    aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( AVMEDIA_QUICKTIME_MANAGER_SERVICENAME ) );
-
-    return aRet;
-}
-
-} // namespace quicktime
-} // namespace avmedia
diff --git a/main/avmedia/source/quicktime/qt_manager.hxx b/main/avmedia/source/quicktime/qt_manager.hxx
deleted file mode 100644
index 9cceb4a..0000000
--- a/main/avmedia/source/quicktime/qt_manager.hxx
+++ /dev/null
@@ -1,60 +0,0 @@
-/**************************************************************
- * 
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- * 
- *   http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- * 
- *************************************************************/
-
-
-#ifndef QT_MANAGER_HXX
-#define QT_MANAGER_HXX
-
-#include "qt_common.hxx"
-
-#include "com/sun/star/media/XManager.hdl"
-
-// -----------
-// - Manager -
-// -----------
-
-namespace avmedia { namespace quicktime {
-
-class Manager : public ::cppu::WeakImplHelper2 < ::com::sun::star::media::XManager,
-                                                 ::com::sun::star::lang::XServiceInfo >
-{
-public:
-
-    Manager( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& rxMgr );
-    ~Manager();
-
-    // XManager
-    virtual ::com::sun::star::uno::Reference< ::com::sun::star::media::XPlayer > SAL_CALL createPlayer( const ::rtl::OUString& aURL ) throw (::com::sun::star::uno::RuntimeException);
-
-    // XServiceInfo
-    virtual ::rtl::OUString SAL_CALL getImplementationName(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException);
-    virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames(  ) throw (::com::sun::star::uno::RuntimeException);
-private:
-
-    ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > mxMgr;
-};
-
-} // namespace quicktime
-} // namespace avmedia
-
-#endif // QT_MANAGER_HXX
-
diff --git a/main/avmedia/source/quicktime/qt_player.cxx b/main/avmedia/source/quicktime/qt_player.cxx
deleted file mode 100644
index fcb88c5..0000000
--- a/main/avmedia/source/quicktime/qt_player.cxx
+++ /dev/null
@@ -1,459 +0,0 @@
-/**************************************************************
- * 
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- * 
- *   http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- * 
- *************************************************************/
-
-
-#include <math.h>
-
-#include "qt_player.hxx"
-#include "qt_framegrabber.hxx"
-#include "qt_window.hxx"
-
-using namespace ::com::sun::star;
-
-namespace avmedia { namespace quicktime {
-
-// ----------------
-// - Player -
-// ----------------
-
-Player::Player( const uno::Reference< lang::XMultiServiceFactory >& rxMgr ) :
-    mxMgr( rxMgr ),
-    mpMovie( nil ),
-    /* GST
-    mbFakeVideo (sal_False ),
-    */
-    mnUnmutedVolume( 0 ),
-    mnStopTime( DBL_MAX ),  //max double
-    mbMuted( false ),
-    mbLooping( false ),
-    mbInitialized( false ),
-    mnWindowID( 0 ),
-    mnDuration( 0 ),
-    mnWidth( 0 ),
-    mnHeight( 0 ),
-    mnVersion( 0 ),
-    maSizeCondition( osl_createCondition() )
-{
-    OSErr result;
-
-    NSApplicationLoad();
-	NSAutoreleasePool* pool	= [[NSAutoreleasePool alloc] init];
-	  mbInitialized = true;
-    [pool release];
-}
-
-// ------------------------------------------------------------------------------
-
-Player::~Player()
-{
-    if( mpMovie )
-    {
-        [mpMovie release];
-        mpMovie = nil;
-    }
-}
-// ------------------------------------------------------------------------------
-
-QTMovie* Player::getMovie()
-{
-    OSL_ASSERT( mpMovie ); 
-    return mpMovie;
-}
-
-// ------------------------------------------------------------------------------
-
-bool Player::create( const ::rtl::OUString& rURL )
-{
-    bool    bRet = false;
-    // create the Movie    
-    if( mbInitialized )
-    {
-        NSAutoreleasePool* pool	= [[NSAutoreleasePool alloc] init];
-        
-        if( mpMovie )
-        {
-            [mpMovie release];
-            mpMovie = nil;
-        }
-        
-        NSString* aNSStr = [[[NSString alloc] initWithCharacters: rURL.getStr() length: rURL.getLength()]stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding] ;
-        NSURL* aURL = [NSURL URLWithString:aNSStr ];
-
-
-        NSError* pErr = nil;
-        mpMovie = [QTMovie movieWithURL:aURL error:&pErr];
-        if(mpMovie)
-        {
-            [mpMovie retain];
-            maURL = rURL;
-            bRet = true;
-        }
-        if( pErr )
-        {
-            OSL_TRACE( "NSMovie create failed with error %ld (%s)",
-                       (long)[pErr code],
-                       [[pErr localizedDescription] UTF8String]
-                       );
-        }
-        [pool release];
-    }
-
-    return bRet;
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Player::start(  )
-    throw (uno::RuntimeException)
-{
-  OSL_TRACE ("Player::start");
-
-  if( mpMovie )
-  {
-      [mpMovie play];
-  }
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Player::stop(  )
-    throw (uno::RuntimeException)
-{
-    OSL_TRACE ("Player::stop");
-    if( mpMovie )
-    {
-        [mpMovie stop];
-    }
-}
-
-// ------------------------------------------------------------------------------
-
-sal_Bool SAL_CALL Player::isPlaying()
-    throw (uno::RuntimeException)
-{
-    bool bRet = false;
-
-    if ( mpMovie )
-    {
-        if ([mpMovie rate] != 0)
-        {
-            bRet = true;
-        }
-    }
-        
-    return bRet;
-}
-
-// ------------------------------------------------------------------------------
-
-double SAL_CALL Player::getDuration(  )
-    throw (uno::RuntimeException)
-{
-    // slideshow checks for non-zero duration, so cheat here
-    double duration = 0.01;
-
-    if ( mpMovie ) // && mnDuration > 0 ) {
-    {   
-        QTTime structDuration =  [mpMovie duration] ;
-        duration = (double)structDuration.timeValue / (double)structDuration.timeScale;
-    }
-
-    return duration;
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Player::setMediaTime( double fTime )
-    throw (uno::RuntimeException)
-{
-    OSL_TRACE ("Player::setMediaTime");
-    
-    if ( mpMovie )
-    {
-        [mpMovie setCurrentTime: QTMakeTimeWithTimeInterval(fTime)];
-    }
-}
-
-// ------------------------------------------------------------------------------
-
-double SAL_CALL Player::getMediaTime(  )
-    throw (uno::RuntimeException)
-{
-  double position = 0.0;
-
-  if ( mpMovie )
-  {
-      QTTime structDuration =  [mpMovie currentTime] ;
-      position = (double)structDuration.timeValue / (double)structDuration.timeScale;
-  }
-
-  if(isPlaying() && position>mnStopTime)
-  {
-      stop();
-  }
-
-  return position;
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Player::setStopTime( double fTime )
-    throw (uno::RuntimeException)
-{
-    OSL_TRACE ("Player::setStopTime %f", fTime);
-
-    mnStopTime = fTime;
-}
-
-// ------------------------------------------------------------------------------
-
-double SAL_CALL Player::getStopTime(  )
-    throw (uno::RuntimeException)
-{
-	double fRet = mnStopTime;
-
-	return fRet;
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Player::setRate( double fRate )
-    throw (uno::RuntimeException)
-{
-    OSL_TRACE ("Player::setRate");
-    
-    // Quicktime: 0 = stop, 1 = normal speed, 2 = double speed, -1 = normal speed backwards
-    if ( mpMovie )
-    {
-        [mpMovie setRate: fRate];
-    }
-}
-
-// ------------------------------------------------------------------------------
-
-double SAL_CALL Player::getRate(  )
-    throw (uno::RuntimeException)
-{
-    // Quicktime: 0 = stop, 1 = normal speed, 2 = double speed, -1 = normal speed backwards
-    double rate = 1.0;
-
-    OSL_TRACE ("Player::getRate");
-        
-    if ( mpMovie )
-    {
-        rate = (double) [mpMovie rate];
-    }
-
-    return rate;
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Player::setPlaybackLoop( sal_Bool bSet )
-    throw (uno::RuntimeException)
-{
-    OSL_TRACE ("Player::setPlaybackLoop? %s", bSet?"True":"False" );
-
-    if(bSet)
-    {
-        [mpMovie setAttribute:[NSNumber numberWithBool:YES] forKey: QTMovieLoopsAttribute]  ;
-    }
-    else
-    {
-         [mpMovie setAttribute:[NSNumber numberWithBool:NO] forKey: QTMovieLoopsAttribute]  ;
-    }
-}
-
-// ------------------------------------------------------------------------------
-
-sal_Bool SAL_CALL Player::isPlaybackLoop(  )
-    throw (uno::RuntimeException)
-{
-	bool bRet = [[mpMovie attributeForKey:QTMovieLoopsAttribute] boolValue];
-
-    OSL_TRACE ("Player::isPlaybackLoop ? %s", bRet?"True":"False" );
-    
-    return bRet;
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Player::setMute( sal_Bool bSet )
-    throw (uno::RuntimeException)
-{
-    OSL_TRACE( "set mute: %d muted: %d unmuted volume: %lf", bSet, mbMuted, mnUnmutedVolume );
-
-    // change the volume to 0 or the unmuted volume
-    if(  mpMovie && mbMuted != bSet )
-    {
-        [mpMovie setMuted: bSet ]; 
-        mbMuted = bSet;
-    }
-
-}
-
-// ------------------------------------------------------------------------------
-
-sal_Bool SAL_CALL Player::isMute(  )
-    throw (uno::RuntimeException)
-{
-    OSL_TRACE ("Player::isMuted");
-
-    return mbMuted;
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Player::setVolumeDB( sal_Int16 nVolumeDB ) 
-	throw (uno::RuntimeException)
-{
-    // OOo db volume -40 = QTVolume 0
-    // OOo db volume 0   = QTvolume 1
-    if(nVolumeDB==-40)
-    {
-        mnUnmutedVolume = 0;
-    }
-    else
-    {
-        mnUnmutedVolume = pow( 10.0, nVolumeDB / 20.0 );
-    }
-    
-    OSL_TRACE( "set volume: %d gst volume: %f", nVolumeDB, mnUnmutedVolume );
-
-    // change volume
-    if( !mbMuted && mpMovie )
-    {
-        [mpMovie setVolume: mnUnmutedVolume ]; 
-    }
-}
-
-// ------------------------------------------------------------------------------
-    
-sal_Int16 SAL_CALL Player::getVolumeDB(  ) 
-	throw (uno::RuntimeException)
-{
-    sal_Int16 nVolumeDB = 0.0;
-    
-    if( mpMovie ) 
-      {
-          float volume = 0.0;
-
-          volume = [mpMovie volume];
-          if(volume>0)            //protect from log10(0)
-          {
-              nVolumeDB = (sal_Int16) ( 20.0*log10 ( volume ) );
-          }
-          else
-          {
-              nVolumeDB = -40 ;  // QT zero volume is no volume, -40db
-          }
-      }
-    
-    return nVolumeDB;
-}
-
-// ------------------------------------------------------------------------------
-
-awt::Size SAL_CALL Player::getPreferredPlayerWindowSize(  )
-    throw (uno::RuntimeException)
-{
-    NSSize  nsSize = [[mpMovie attributeForKey:QTMovieNaturalSizeAttribute] sizeValue];
-    awt::Size aSize( nsSize.width, nsSize.height );
-    return aSize;
-}
-
-
-// ------------------------------------------------------------------------------
-
-uno::Reference< ::media::XPlayerWindow > SAL_CALL Player::createPlayerWindow( const uno::Sequence< uno::Any >& aArguments )
-    throw (uno::RuntimeException)
-{
-    uno::Reference< ::media::XPlayerWindow >    xRet;
-    awt::Size                                   aSize( getPreferredPlayerWindowSize() );
-    NSSize                                      nsSize( NSMakeSize(aSize.Width, aSize.Height) );
-    
-    OSL_TRACE( "Player::createPlayerWindow %d %d length: %d", aSize.Width, aSize.Height, aArguments.getLength() );
-
-    if( aSize.Width > 0 && aSize.Height > 0 )
-    {
-        sal_IntPtr nPtr = NULL;
-        aArguments[0] >>= nPtr;        
-        NSView* pParentView = reinterpret_cast< NSView * >(nPtr);
-
-        ::avmedia::quicktime::Window* pWindow = new ::avmedia::quicktime::Window( mxMgr, *this, pParentView );
-        xRet = pWindow;
-    }
-
-    return xRet;
-}
-
-// ------------------------------------------------------------------------------
-
-uno::Reference< media::XFrameGrabber > SAL_CALL Player::createFrameGrabber(  ) 
-    throw (::com::sun::star::uno::RuntimeException)
-{
-  uno::Reference< media::XFrameGrabber > xRet;
-  OSL_TRACE ("Player::createFrameGrabber");
-
-  if( !maURL.isEmpty() )
-  {
-      FrameGrabber* pGrabber = new FrameGrabber( mxMgr );
-      
-      xRet = pGrabber;
-      
-      if( !pGrabber->create( maURL ) )
-      {
-          xRet.clear();
-      }
-  }
-    
-  return xRet;
-}
-
-// ------------------------------------------------------------------------------
-
-::rtl::OUString SAL_CALL Player::getImplementationName(  )
-    throw (uno::RuntimeException)
-{
-    return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( AVMEDIA_QUICKTIME_PLAYER_IMPLEMENTATIONNAME ) );
-}
-
-// ------------------------------------------------------------------------------
-
-sal_Bool SAL_CALL Player::supportsService( const ::rtl::OUString& ServiceName )
-    throw (uno::RuntimeException)
-{
-    return ServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM ( AVMEDIA_QUICKTIME_PLAYER_SERVICENAME ) );
-}
-
-// ------------------------------------------------------------------------------
-
-uno::Sequence< ::rtl::OUString > SAL_CALL Player::getSupportedServiceNames(  )
-    throw (uno::RuntimeException)
-{
-    uno::Sequence< ::rtl::OUString > aRet(1);
-    aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( AVMEDIA_QUICKTIME_PLAYER_SERVICENAME ) );
-
-    return aRet;
-}
-
-} // namespace quicktime
-} // namespace avmedia
diff --git a/main/avmedia/source/quicktime/qt_player.hxx b/main/avmedia/source/quicktime/qt_player.hxx
deleted file mode 100644
index 9f9274b..0000000
--- a/main/avmedia/source/quicktime/qt_player.hxx
+++ /dev/null
@@ -1,107 +0,0 @@
-/**************************************************************
- * 
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- * 
- *   http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- * 
- *************************************************************/
-
-
-#ifndef QT_PLAYER_HXX
-#define QT_PLAYER_HXX
-
-#include <osl/conditn.h>
-#include "qt_common.hxx"
-
-#include "com/sun/star/media/XPlayer.hdl"
-
-namespace avmedia { namespace quicktime {
-
-/*
-// ----------
-// - Player -
-// ----------
-*/
-
-class Player : public ::cppu::WeakImplHelper2< ::com::sun::star::media::XPlayer,
-                                               ::com::sun::star::lang::XServiceInfo >
-{
-public:
-
-    Player( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& rxMgr );
-    ~Player();
-
-    bool create( const ::rtl::OUString& rURL );
-
-//    void processMessage( GstMessage *message ); 
-
-    // XPlayer
-    virtual void SAL_CALL start(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL stop(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual sal_Bool SAL_CALL isPlaying(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual double SAL_CALL getDuration(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL setMediaTime( double fTime ) throw (::com::sun::star::uno::RuntimeException);
-    virtual double SAL_CALL getMediaTime(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL setStopTime( double fTime ) throw (::com::sun::star::uno::RuntimeException);
-    virtual double SAL_CALL getStopTime(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL setRate( double fRate ) throw (::com::sun::star::uno::RuntimeException);
-    virtual double SAL_CALL getRate(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL setPlaybackLoop( sal_Bool bSet ) throw (::com::sun::star::uno::RuntimeException);
-    virtual sal_Bool SAL_CALL isPlaybackLoop(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL setMute( sal_Bool bSet ) throw (::com::sun::star::uno::RuntimeException);
-    virtual sal_Bool SAL_CALL isMute(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL setVolumeDB( sal_Int16 nVolumeDB ) throw (::com::sun::star::uno::RuntimeException);
-    virtual sal_Int16 SAL_CALL getVolumeDB(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual ::com::sun::star::awt::Size SAL_CALL getPreferredPlayerWindowSize(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual ::com::sun::star::uno::Reference< ::com::sun::star::media::XPlayerWindow > SAL_CALL createPlayerWindow( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aArguments ) throw (::com::sun::star::uno::RuntimeException);
-    virtual ::com::sun::star::uno::Reference< ::com::sun::star::media::XFrameGrabber > SAL_CALL createFrameGrabber(  ) throw (::com::sun::star::uno::RuntimeException);
-    // XServiceInfo
-    virtual ::rtl::OUString SAL_CALL getImplementationName(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException);
-    virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames(  ) throw (::com::sun::star::uno::RuntimeException);
-    
-    QTMovie* getMovie();
-
-private:
-    ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > mxMgr;
-
-    ::rtl::OUString         maURL;
-    
-    QTMovie                 *mpMovie;      // the Movie object
-  /* GST
-    sal_Bool                mbFakeVideo;
-  */
-    float                   mnUnmutedVolume;
-    double                  mnStopTime;
-    
-    sal_Bool                mbMuted;
-    sal_Bool                mbLooping;
-    sal_Bool                mbInitialized;
-
-    long                    mnWindowID;
-    long                    mnDuration;
-    int                     mnWidth;
-    int                     mnHeight;
-
-    long                    mnVersion;
-    oslCondition            maSizeCondition;
-};
-
-} // namespace quicktime
-} // namespace avmedia
-
-#endif // QT_PLAYER_HXX
-
diff --git a/main/avmedia/source/quicktime/qt_uno.cxx b/main/avmedia/source/quicktime/qt_uno.cxx
deleted file mode 100644
index 1f39fbf..0000000
--- a/main/avmedia/source/quicktime/qt_uno.cxx
+++ /dev/null
@@ -1,71 +0,0 @@
-/**************************************************************
- * 
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- * 
- *   http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- * 
- *************************************************************/
-
-#include "qt_manager.hxx"
-
-using namespace ::com::sun::star;
-
-// -------------------
-// - factory methods -
-// -------------------
-
-static uno::Reference< uno::XInterface > SAL_CALL create_MediaPlayer( const uno::Reference< lang::XMultiServiceFactory >& rxFact )
-{
-	return uno::Reference< uno::XInterface >( *new ::avmedia::quicktime::Manager( rxFact ) );
-}
-
-// ------------------------------------------
-// - component_getImplementationEnvironment -
-// ------------------------------------------
-
-extern "C" void SAL_CALL component_getImplementationEnvironment( const sal_Char ** ppEnvTypeName, uno_Environment ** /* ppEnv */ )
-{
-	*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
-}
-
-// ------------------------
-// - component_getFactory -
-// ------------------------
-
-extern "C" void* SAL_CALL component_getFactory( const sal_Char* pImplName, void* pServiceManager, void* /* pRegistryKey */ )
-{
-	uno::Reference< lang::XSingleServiceFactory > xFactory;
-	void*									pRet = 0;
-
-	if( rtl_str_compare( pImplName, AVMEDIA_QUICKTIME_MANAGER_IMPLEMENTATIONNAME ) == 0 )
-	{
-		const ::rtl::OUString aServiceName( ::rtl::OUString::createFromAscii( AVMEDIA_QUICKTIME_MANAGER_SERVICENAME ) );
-
-		xFactory = uno::Reference< lang::XSingleServiceFactory >( ::cppu::createSingleFactory(
-						reinterpret_cast< lang::XMultiServiceFactory* >( pServiceManager ),
-						::rtl::OUString::createFromAscii( AVMEDIA_QUICKTIME_MANAGER_IMPLEMENTATIONNAME ),
-						create_MediaPlayer, uno::Sequence< ::rtl::OUString >( &aServiceName, 1 ) ) );
-	}
-
-	if( xFactory.is() )
-	{
-		xFactory->acquire();
-		pRet = xFactory.get();
-	}
-
-	return pRet;
-}
-
diff --git a/main/avmedia/source/quicktime/qt_window.cxx b/main/avmedia/source/quicktime/qt_window.cxx
deleted file mode 100644
index 73887ab..0000000
--- a/main/avmedia/source/quicktime/qt_window.cxx
+++ /dev/null
@@ -1,348 +0,0 @@
-/**************************************************************
- * 
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- * 
- *   http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- * 
- *************************************************************/
-
-
-#include <com/sun/star/awt/SystemPointer.hpp>
-#include <com/sun/star/awt/PosSize.hpp>
-
-#include "qt_window.hxx"
-#include "qt_player.hxx"
-
-using namespace ::com::sun::star;
-
-namespace avmedia { namespace quicktime {
-
-// -----------
-// - statics -
-// -----------
-
-static ::osl::Mutex& ImplGetOwnStaticMutex()
-{
-    static ::osl::Mutex* pMutex = NULL;
-
-    if( pMutex == NULL )
-    {
-        ::osl::MutexGuard aGuard( ::osl::Mutex::getGlobalMutex() );
-
-        if( pMutex == NULL )
-        {
-            static ::osl::Mutex aMutex;
-            pMutex = &aMutex;
-        }
-    }
-
-    return *pMutex;
-}
-
-// ---------------
-// - Window -
-// ---------------
-
-// ------------------------------------------------------------------------------
-
-Window::Window( const uno::Reference< lang::XMultiServiceFactory >& i_rxMgr, Player& i_rPlayer, NSView* i_pParentView ) :
-    mxMgr( i_rxMgr ),
-    maListeners( maMutex ),
-    meZoomLevel( media::ZoomLevel_NOT_AVAILABLE ),
-    mrPlayer( i_rPlayer ),
-    mnPointerType( awt::SystemPointer::ARROW ),
-    mpParentView( i_pParentView ),
-    mpMovieView( nil )
-{
-    
-    ::osl::MutexGuard aGuard( ImplGetOwnStaticMutex() );
-
-
-    if( mpParentView ) // sanity check
-    {
-       
-        NSRect aViewRect = [mpParentView frame];
-        aViewRect.origin.x = aViewRect.origin.y = 0;
-        mpMovieView = [[QTMovieView alloc] initWithFrame: aViewRect];
-        [mpMovieView setMovie: mrPlayer.getMovie() ];
-        [mpMovieView setControllerVisible: NO];
-        [mpMovieView setPreservesAspectRatio: YES];
-        [mpMovieView setAutoresizingMask: NSViewWidthSizable | NSViewHeightSizable];
-        [mpParentView addSubview: mpMovieView];
-        [mpParentView setAutoresizesSubviews: YES];
-    }
-
-    OSL_TRACE ("Window::Window");
-}
-
-// ------------------------------------------------------------------------------
-
-Window::~Window()
-{
-    if( mpMovieView )
-    {
-        [mpMovieView removeFromSuperview];
-        [mpMovieView setMovie:nil];
-        [mpMovieView release];
-        mpMovieView = nil;
-    }	
-}
-
-bool Window::create( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aArguments )
-{
-    return true;
-}
-
-// XPlayerWindow
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::update(  )
-    throw (uno::RuntimeException)
-{
-    ;
-}
-
-// ------------------------------------------------------------------------------
-
-sal_Bool SAL_CALL Window::setZoomLevel( media::ZoomLevel eZoomLevel )
-    throw (uno::RuntimeException)
-{
-        return false;
-}
-
-// ------------------------------------------------------------------------------
-
-media::ZoomLevel SAL_CALL Window::getZoomLevel(  )
-    throw (uno::RuntimeException)
-{
-    return meZoomLevel;
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::setPointerType( sal_Int32 nPointerType ) 
-    throw (uno::RuntimeException)
-{
-    mnPointerType = nPointerType;
-}
-
-// XWindow
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::setPosSize( sal_Int32 X, sal_Int32 Y, sal_Int32 Width, sal_Int32 Height, sal_Int16 Flags )
-    throw (uno::RuntimeException)
-{
-    if( mpParentView && mpMovieView )
-    {
-        NSRect aRect = [mpMovieView frame];
-        if( (Flags & awt::PosSize::WIDTH) )
-            aRect.size.width = Width;
-        if( (Flags & awt::PosSize::HEIGHT) )
-            aRect.size.height = Height;
-    }
-}
-
-// ------------------------------------------------------------------------------
-
-awt::Rectangle SAL_CALL Window::getPosSize()
-    throw (uno::RuntimeException)
-{
-    awt::Rectangle aRet;
-
-    NSRect aRect = [mpMovieView frame];
-    aRet.X = aRet.Y = 0;
-    aRet.Width = aRect.size.width;
-    aRet.Height = aRect.size.height;
-
-    return aRet;
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::setVisible( sal_Bool bVisible )
-    throw (uno::RuntimeException)
-{
-    OSL_TRACE ("Window::setVisible");
-    
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::setEnable( sal_Bool bEnable )
-    throw (uno::RuntimeException)
-{
-    ;
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::setFocus(  )
-    throw (uno::RuntimeException)
-{
-    OSL_TRACE ("Window::setFocus");
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::addWindowListener( const uno::Reference< awt::XWindowListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.addInterface( getCppuType( &xListener ), xListener );
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::removeWindowListener( const uno::Reference< awt::XWindowListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.removeInterface( getCppuType( &xListener ), xListener );
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::addFocusListener( const uno::Reference< awt::XFocusListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.addInterface( getCppuType( &xListener ), xListener );
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::removeFocusListener( const uno::Reference< awt::XFocusListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.removeInterface( getCppuType( &xListener ), xListener );
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::addKeyListener( const uno::Reference< awt::XKeyListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.addInterface( getCppuType( &xListener ), xListener );
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::removeKeyListener( const uno::Reference< awt::XKeyListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.removeInterface( getCppuType( &xListener ), xListener );
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::addMouseListener( const uno::Reference< awt::XMouseListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.addInterface( getCppuType( &xListener ), xListener );
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::removeMouseListener( const uno::Reference< awt::XMouseListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.removeInterface( getCppuType( &xListener ), xListener );
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::addMouseMotionListener( const uno::Reference< awt::XMouseMotionListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.addInterface( getCppuType( &xListener ), xListener );
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::removeMouseMotionListener( const uno::Reference< awt::XMouseMotionListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.removeInterface( getCppuType( &xListener ), xListener );
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::addPaintListener( const uno::Reference< awt::XPaintListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.addInterface( getCppuType( &xListener ), xListener );
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::removePaintListener( const uno::Reference< awt::XPaintListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.removeInterface( getCppuType( &xListener ), xListener );
-}
-
-
-// XComponent
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::dispose(  )
-    throw (uno::RuntimeException)
-{
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::addEventListener( const uno::Reference< lang::XEventListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.addInterface( getCppuType( &xListener ), xListener );
-}
-
-// ------------------------------------------------------------------------------
-
-void SAL_CALL Window::removeEventListener( const uno::Reference< lang::XEventListener >& xListener )
-    throw (uno::RuntimeException)
-{
-    maListeners.removeInterface( getCppuType( &xListener ), xListener );
-}
-
-// XServiceInfo
-// ------------------------------------------------------------------------------
-
-::rtl::OUString SAL_CALL Window::getImplementationName(  )
-    throw (uno::RuntimeException)
-{
-    return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( AVMEDIA_QUICKTIME_WINDOW_IMPLEMENTATIONNAME ) );
-}
-
-// ------------------------------------------------------------------------------
-
-sal_Bool SAL_CALL Window::supportsService( const ::rtl::OUString& ServiceName )
-    throw (uno::RuntimeException)
-{
-    return ServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM ( AVMEDIA_QUICKTIME_WINDOW_SERVICENAME ) );
-}
-
-// ------------------------------------------------------------------------------
-
-uno::Sequence< ::rtl::OUString > SAL_CALL Window::getSupportedServiceNames(  )
-    throw (uno::RuntimeException)
-{
-    uno::Sequence< ::rtl::OUString > aRet(1);
-    aRet[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( AVMEDIA_QUICKTIME_WINDOW_SERVICENAME ) );
-
-    return aRet;
-}
-
-} // namespace quicktime
-} // namespace avmedia
diff --git a/main/avmedia/source/quicktime/qt_window.hxx b/main/avmedia/source/quicktime/qt_window.hxx
deleted file mode 100644
index 9babf0d..0000000
--- a/main/avmedia/source/quicktime/qt_window.hxx
+++ /dev/null
@@ -1,109 +0,0 @@
-/**************************************************************
- * 
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- * 
- *   http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- * 
- *************************************************************/
-
-
-#ifndef QT_WINDOW_HXX
-#define QT_WINDOW_HXX
-
-#include "qt_common.hxx"
-#include <cppuhelper/interfacecontainer.h>
-
-#include "com/sun/star/media/XPlayerWindow.hdl"
-
-namespace avmedia { namespace quicktime {
-
-// ---------------
-// - Window -
-// ---------------
-
-class Player;
-
-class Window : public ::cppu::WeakImplHelper2 < ::com::sun::star::media::XPlayerWindow,
-                                                ::com::sun::star::lang::XServiceInfo >
-{
-public:
-
-            Window( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& i_rxMgr,
-                    Player& i_rPlayer,
-                    NSView* i_pParentView
-                    );
-            ~Window();
-
-    bool    create( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aArguments );
-    void    processGraphEvent();
-    void    updatePointer();
-
-    // XPlayerWindow
-    virtual void SAL_CALL update(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual sal_Bool SAL_CALL setZoomLevel( ::com::sun::star::media::ZoomLevel ZoomLevel ) throw (::com::sun::star::uno::RuntimeException);
-    virtual ::com::sun::star::media::ZoomLevel SAL_CALL getZoomLevel(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL setPointerType( sal_Int32 nPointerType ) throw (::com::sun::star::uno::RuntimeException);
-
-    // XWindow
-    virtual void SAL_CALL setPosSize( sal_Int32 X, sal_Int32 Y, sal_Int32 Width, sal_Int32 Height, sal_Int16 Flags ) throw (::com::sun::star::uno::RuntimeException);
-    virtual ::com::sun::star::awt::Rectangle SAL_CALL getPosSize(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL setVisible( sal_Bool Visible ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL setEnable( sal_Bool Enable ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL setFocus(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL addWindowListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL removeWindowListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL addFocusListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XFocusListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL removeFocusListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XFocusListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL addKeyListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XKeyListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL removeKeyListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XKeyListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL addMouseListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XMouseListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL removeMouseListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XMouseListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL addMouseMotionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XMouseMotionListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL removeMouseMotionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XMouseMotionListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL addPaintListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XPaintListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL removePaintListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XPaintListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-
-    // XComponent
-    virtual void SAL_CALL dispose(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL addEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
-    virtual void SAL_CALL removeEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener >& aListener ) throw (::com::sun::star::uno::RuntimeException);
-
-    // XServiceInfo
-    virtual ::rtl::OUString SAL_CALL getImplementationName(  ) throw (::com::sun::star::uno::RuntimeException);
-    virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException);
-    virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames(  ) throw (::com::sun::star::uno::RuntimeException);
-
-private:
-
-    ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > mxMgr;
-
-    ::osl::Mutex                                maMutex;
-    ::cppu::OMultiTypeInterfaceContainerHelper  maListeners;
-    ::com::sun::star::media::ZoomLevel          meZoomLevel;
-    Player&                                     mrPlayer;
-    int                                         mnPointerType;
-
-    NSView*                                     mpParentView; // parent view for our own private movie view
-    QTMovieView*                                mpMovieView;  // the view containing the movie object, output target and controller
-
-    void                                        ImplLayoutVideoWindow();
-};
-
-} // namespace quicktime
-} // namespace avmedia
-
-#endif // QT_WINDOW_HXX
-
diff --git a/main/postprocess/packcomponents/makefile.mk b/main/postprocess/packcomponents/makefile.mk
index 75989ff..1b90cc7 100644
--- a/main/postprocess/packcomponents/makefile.mk
+++ b/main/postprocess/packcomponents/makefile.mk
@@ -313,7 +313,6 @@ my_components += \
 
 .IF "$(OS)" == "MACOSX"
 my_components += \
-    avmediaQuickTime \
     avmediaMacAVF \
     fps_aqua \
     macab1 \
diff --git a/main/scp2/source/ooo/file_library_ooo.scp b/main/scp2/source/ooo/file_library_ooo.scp
index df8c8b3..ef660f9 100644
--- a/main/scp2/source/ooo/file_library_ooo.scp
+++ b/main/scp2/source/ooo/file_library_ooo.scp
@@ -609,13 +609,6 @@ File gid_File_Lib_MacOSXSpell
 	Dir = SCP2_OOO_BIN_DIR;
 End
 
-File gid_File_Lib_avmediaQuickTime
-	TXT_FILE_BODY;
-	Styles = (PACKED);
-	Name = LIBNAME(avmediaQuickTime);
-	Dir = SCP2_OOO_BIN_DIR;
-End
-
 File gid_File_Lib_avmediaMacAVF
 	TXT_FILE_BODY;
 	Styles = (PACKED);
diff --git a/main/vcl/Library_vcl.mk b/main/vcl/Library_vcl.mk
index 835e6f6..d332860 100644
--- a/main/vcl/Library_vcl.mk
+++ b/main/vcl/Library_vcl.mk
@@ -522,9 +522,6 @@ $(eval $(call gb_Library_set_ldflags,vcl,\
     -framework Carbon \
     -framework CoreFoundation \
 ))
-ifneq ($(MACOSX_DEPLOYMENT_TARGET),10.7)
-$(eval $(call gb_Library_set_ldflags,vcl, $$(LDFLAGS) -framework QuickTime ))
-endif
 endif
 
 ifeq ($(OS),WNT)
diff --git a/main/vcl/aqua/source/dtrans/PictToBmpFlt.cxx b/main/vcl/aqua/source/dtrans/PictToBmpFlt.cxx
index aeeb182..76887f0 100644
--- a/main/vcl/aqua/source/dtrans/PictToBmpFlt.cxx
+++ b/main/vcl/aqua/source/dtrans/PictToBmpFlt.cxx
@@ -31,7 +31,6 @@
 #define DEPRECATED_ATTRIBUTE 
 
 #include <Carbon/Carbon.h>
-#include <QuickTime/QuickTime.h>
 #include <postmac.h>
 
 #include "PictToBmpFlt.hxx"
diff --git a/main/vcl/util/makefile.mk b/main/vcl/util/makefile.mk
index b6d6328..ae7dd6b 100644
--- a/main/vcl/util/makefile.mk
+++ b/main/vcl/util/makefile.mk
@@ -195,11 +195,6 @@ SHL1STDLIBS+= \
 	$(BASEBMPLIB) \
 	-lAppleRemote$(DLLPOSTFIX)
 
-# the QuickTime API has been removed in OSX SDK 10.7
-.IF "${MACOSX_DEPLOYMENT_TARGET:s/.//}"<"107"
-SHL1STDLIBS+= -framework QuickTime
-.ENDIF
-
 LIB1FILES+= \
             $(SLB)$/sala11y.lib
 .ENDIF


[openoffice] 08/08: Ensure correct casting

Posted by ar...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

arielch pushed a commit to branch AOO418
in repository https://gitbox.apache.org/repos/asf/openoffice.git

commit 300bfcc48c1aee2e5a1e1c3fd1072c366bf43f0f
Author: Jim Jagielski <ji...@apache.org>
AuthorDate: Fri Jan 25 15:10:14 2019 +0000

    Ensure correct casting
    
    git-svn-id: https://svn.apache.org/repos/asf/openoffice/trunk@1852140 13f79535-47bb-0310-9956-ffa450edef68
    (cherry picked from commit 308dd811e05d8f968d4ee83245eeba8c178b0637)
---
 main/vcl/aqua/source/dtrans/OSXTransferable.cxx | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/main/vcl/aqua/source/dtrans/OSXTransferable.cxx b/main/vcl/aqua/source/dtrans/OSXTransferable.cxx
index f02ce8b..7bfd04c 100644
--- a/main/vcl/aqua/source/dtrans/OSXTransferable.cxx
+++ b/main/vcl/aqua/source/dtrans/OSXTransferable.cxx
@@ -85,7 +85,7 @@ Any SAL_CALL OSXTransferable::getTransferData( const DataFlavor& aFlavor )
 	}
 
   bool bInternal(false);
-  NSString* sysFormat = 
+  const NSString* sysFormat = 
       (aFlavor.MimeType.compareToAscii( "image/png", 9 ) == 0)
       ? mDataFlavorMapper->openOfficeImageToSystemFlavor( mPasteboard )
       : mDataFlavorMapper->openOfficeToSystemFlavor(aFlavor, bInternal);
@@ -93,12 +93,12 @@ Any SAL_CALL OSXTransferable::getTransferData( const DataFlavor& aFlavor )
 
   if ([sysFormat caseInsensitiveCompare: NSFilenamesPboardType] == NSOrderedSame)
 	{
-	  NSArray* sysData = [mPasteboard propertyListForType: sysFormat];
+	  NSArray* sysData = [mPasteboard propertyListForType: (NSString*)sysFormat];
 	  dp = mDataFlavorMapper->getDataProvider(sysFormat, sysData);
 	}
   else
 	{
-	  NSData* sysData = [mPasteboard dataForType: sysFormat];
+	  NSData* sysData = [mPasteboard dataForType: (NSString*)sysFormat];
 	  dp = mDataFlavorMapper->getDataProvider(sysFormat, sysData);
 	}