[Libreoffice-commits] core.git: Branch 'feature/opengl-canvas-rework' - slideshow/source

Michael Jaumann meta_dev at yahoo.com
Fri Feb 20 00:47:27 PST 2015


 slideshow/source/engine/shapes/viewshape.cxx |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

New commits:
commit 97353530ff457b005b6df54880efdba8751177cb
Author: Michael Jaumann <meta_dev at yahoo.com>
Date:   Fri Feb 20 08:40:35 2015 +0000

    polite query the canvas backend
    
    throw no more exception, check if xinterface is supportet
    
    Change-Id: I18bbb672ad60c5cb6b5a88ac5cc1d8d597a47947

diff --git a/slideshow/source/engine/shapes/viewshape.cxx b/slideshow/source/engine/shapes/viewshape.cxx
index 5e29d29..0c57efd 100644
--- a/slideshow/source/engine/shapes/viewshape.cxx
+++ b/slideshow/source/engine/shapes/viewshape.cxx
@@ -854,8 +854,10 @@ namespace slideshow
 
             // Shall we render to a sprite, or to a plain canvas?
             // Hack, force use of Sprites in case of ogl canvas
-            uno::Reference< lang::XServiceInfo >  xServiceInfo(mpViewLayer->getCanvas()->getUNOCanvas(),uno::UNO_QUERY_THROW);
-            if( xServiceInfo->getImplementationName() == "com.sun.star.comp.rendering.SpriteCanvas.OGL" ||  isBackgroundDetached() )
+            const uno::Reference< rendering::XCanvas > xCanvas( mpViewLayer->getCanvas()->getUNOCanvas() );
+            const uno::Reference< lang::XServiceInfo >  xServiceInfo(xCanvas ,uno::UNO_QUERY);
+            if(xServiceInfo.is()&&  xServiceInfo->getImplementationName() == "com.sun.star.comp.rendering.SpriteCanvas.OGL"
+               || isBackgroundDetached() )
             {
                 return renderSprite( mpViewLayer,
                                      rMtf,


More information about the Libreoffice-commits mailing list