Kaydet (Commit) 92a0181d authored tarafından Caolán McNamara's avatar Caolán McNamara Kaydeden (comit) Michael Stahl

tdf#116544 crash on unhandled IllegalArgument exception

Change-Id: I290ba6097d6d91bf4677e7e92c896bd6359cbc49
Reviewed-on: https://gerrit.libreoffice.org/51835Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarMichael Stahl <Michael.Stahl@cib.de>
üst 2446ae94
...@@ -180,10 +180,17 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void) ...@@ -180,10 +180,17 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void)
aPicPos.Y = (aPageSize.Height - aPicSize.Height)/2; aPicPos.Y = (aPageSize.Height - aPicSize.Height)/2;
xShape->setPosition(aPicPos); xShape->setPosition(aPicPos);
try
{
xSlide->add(xShape); xSlide->add(xShape);
if(bCreateCaptions) if (bCreateCaptions)
createCaption( aPageSize ); createCaption( aPageSize );
} }
catch (const css::uno::Exception& exc)
{
SAL_WARN( "sd", exc.Message );
}
}
} }
else if( nOpt == TWO_IMAGES ) else if( nOpt == TWO_IMAGES )
{ {
...@@ -249,8 +256,15 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void) ...@@ -249,8 +256,15 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void)
aPicPos.Y = aPageSize.Height/2 - aPicSize.Height/2; aPicPos.Y = aPageSize.Height/2 - aPicSize.Height/2;
xShape->setPosition(aPicPos); xShape->setPosition(aPicPos);
try
{
xSlide->add(xShape); xSlide->add(xShape);
} }
catch (const css::uno::Exception& exc)
{
SAL_WARN( "sd", exc.Message );
}
}
if( !sUrl2.isEmpty() ) if( !sUrl2.isEmpty() )
{ {
...@@ -287,10 +301,17 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void) ...@@ -287,10 +301,17 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void)
aPicPos.Y = aPageSize.Height/2 - aPicSize.Height/2; aPicPos.Y = aPageSize.Height/2 - aPicSize.Height/2;
xShape->setPosition(aPicPos); xShape->setPosition(aPicPos);
try
{
xSlide->add(xShape); xSlide->add(xShape);
if(bCreateCaptions) if(bCreateCaptions)
createCaption( aPageSize ); createCaption( aPageSize );
}
catch (const css::uno::Exception& exc)
{
SAL_WARN( "sd", exc.Message );
}
} }
} }
} }
...@@ -370,8 +391,15 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void) ...@@ -370,8 +391,15 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void)
aPicPos.Y = aPageSize.Height/4 - aPicSize.Height/2; aPicPos.Y = aPageSize.Height/4 - aPicSize.Height/2;
xShape->setPosition(aPicPos); xShape->setPosition(aPicPos);
try
{
xSlide->add(xShape); xSlide->add(xShape);
} }
catch (const css::uno::Exception& exc)
{
SAL_WARN( "sd", exc.Message );
}
}
if( !sUrl2.isEmpty() ) if( !sUrl2.isEmpty() )
{ {
Reference< graphic::XGraphic > xGraphic = createXGraphicFromUrl(sUrl2, xProvider); Reference< graphic::XGraphic > xGraphic = createXGraphicFromUrl(sUrl2, xProvider);
...@@ -407,8 +435,15 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void) ...@@ -407,8 +435,15 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void)
aPicPos.Y = aPageSize.Height/4 - aPicSize.Height/2; aPicPos.Y = aPageSize.Height/4 - aPicSize.Height/2;
xShape->setPosition(aPicPos); xShape->setPosition(aPicPos);
try
{
xSlide->add(xShape); xSlide->add(xShape);
} }
catch (const css::uno::Exception& exc)
{
SAL_WARN( "sd", exc.Message );
}
}
if( !sUrl3.isEmpty() ) if( !sUrl3.isEmpty() )
{ {
Reference< graphic::XGraphic > xGraphic = createXGraphicFromUrl(sUrl3, xProvider); Reference< graphic::XGraphic > xGraphic = createXGraphicFromUrl(sUrl3, xProvider);
...@@ -444,8 +479,15 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void) ...@@ -444,8 +479,15 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void)
aPicPos.Y = aPageSize.Height/4 - aPicSize.Height/2 + aPageSize.Height/2; aPicPos.Y = aPageSize.Height/4 - aPicSize.Height/2 + aPageSize.Height/2;
xShape->setPosition(aPicPos); xShape->setPosition(aPicPos);
try
{
xSlide->add(xShape); xSlide->add(xShape);
} }
catch (const css::uno::Exception& exc)
{
SAL_WARN( "sd", exc.Message );
}
}
if( !sUrl4.isEmpty() ) if( !sUrl4.isEmpty() )
{ {
Reference< graphic::XGraphic > xGraphic = createXGraphicFromUrl(sUrl4, xProvider); Reference< graphic::XGraphic > xGraphic = createXGraphicFromUrl(sUrl4, xProvider);
...@@ -481,10 +523,16 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void) ...@@ -481,10 +523,16 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, CreateHdl, Button*, void)
aPicPos.Y = aPageSize.Height/4 - aPicSize.Height/2 + aPageSize.Height/2; aPicPos.Y = aPageSize.Height/4 - aPicSize.Height/2 + aPageSize.Height/2;
xShape->setPosition(aPicPos); xShape->setPosition(aPicPos);
try
{
xSlide->add(xShape); xSlide->add(xShape);
if(bCreateCaptions) if(bCreateCaptions)
createCaption( aPageSize ); createCaption( aPageSize );
}
catch (const css::uno::Exception& exc)
{
SAL_WARN( "sd", exc.Message );
}
} }
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment