diff options
author | Oliver Bolte <obo@openoffice.org> | 2005-03-15 10:22:27 +0000 |
---|---|---|
committer | Oliver Bolte <obo@openoffice.org> | 2005-03-15 10:22:27 +0000 |
commit | faa9345ac2de57e6127171c7d6c8a04a690586a0 (patch) | |
tree | 1d364b6f963852e3e33299e1fb72315e2215d2a8 /sd/source/ui/view/sdview4.cxx | |
parent | 000bde69a2df0cf41e9831f96402f6c070d19c3e (diff) |
INTEGRATION: CWS mav17 (1.21.40); FILE MERGED
2005/02/28 11:01:49 mav 1.21.40.1: #i42398# handle impossibility to get visual area
Diffstat (limited to 'sd/source/ui/view/sdview4.cxx')
-rw-r--r-- | sd/source/ui/view/sdview4.cxx | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/sd/source/ui/view/sdview4.cxx b/sd/source/ui/view/sdview4.cxx index 5e2da53e9094..dfc26a7f6d16 100644 --- a/sd/source/ui/view/sdview4.cxx +++ b/sd/source/ui/view/sdview4.cxx @@ -2,9 +2,9 @@ * * $RCSfile: sdview4.cxx,v $ * - * $Revision: 1.21 $ + * $Revision: 1.22 $ * - * last change: $Author: rt $ $Date: 2005-01-31 09:05:17 $ + * last change: $Author: obo $ $Date: 2005-03-15 11:22:27 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -149,6 +149,9 @@ #ifndef _COM_SUN_STAR_EMBED_ASPECTS_HPP_ #include <com/sun/star/embed/Aspects.hpp> #endif +#ifndef _COM_SUN_STAR_EMBED_NOVISUALAREASIZEEXCEPTION_HPP_ +#include <com/sun/star/embed/NoVisualAreaSizeException.hpp> +#endif #include <sfx2/ipclient.hxx> @@ -495,7 +498,16 @@ IMPL_LINK( View, DropInsertFileHdl, Timer*, pTimer ) sal_Int64 nAspect = embed::Aspects::MSOLE_CONTENT; xPersist->storeOwn(); - awt::Size aSz( xObj->getVisualAreaSize( nAspect ) ); + awt::Size aSz; + try + { + aSz = xObj->getVisualAreaSize( nAspect ); + } + catch( embed::NoVisualAreaSizeException& ) + { + // the default size will be set later + } + Size aSize( aSz.Width, aSz.Height ); Rectangle aRect; |