summaryrefslogtreecommitdiff
path: root/sd/source/ui/slideshow
diff options
context:
space:
mode:
authorSiqi LIU <me@siqi.fr>2013-08-23 10:25:29 +0800
committerSiqi LIU <me@siqi.fr>2013-08-23 11:18:28 +0800
commite21ad69e8b0bc7b3c5b3a310c3891685d8e4b7a1 (patch)
tree54309ecabb1ba617aa89762606ba917a5d565b02 /sd/source/ui/slideshow
parent7ba076d7fd46cce99f6fc7a5b26f74d8f207ec3d (diff)
implementation for getTranslationOffset
Change-Id: Ibe1d7f6af4be8f1520c093cd0b23cb06f5346716
Diffstat (limited to 'sd/source/ui/slideshow')
-rw-r--r--sd/source/ui/slideshow/slideshowviewimpl.cxx12
-rw-r--r--sd/source/ui/slideshow/slideshowviewimpl.hxx2
2 files changed, 14 insertions, 0 deletions
diff --git a/sd/source/ui/slideshow/slideshowviewimpl.cxx b/sd/source/ui/slideshow/slideshowviewimpl.cxx
index e2678b848c69..45c9b2b1aa27 100644
--- a/sd/source/ui/slideshow/slideshowviewimpl.cxx
+++ b/sd/source/ui/slideshow/slideshowviewimpl.cxx
@@ -218,6 +218,9 @@ SlideShowView::SlideShowView( ShowWindow& rOutputWindow,
mbMousePressedEaten( false )
{
init();
+
+ mTranslationOffset.Width = 0;
+ mTranslationOffset.Height = 0;
}
/// Dispose all internal references
@@ -329,6 +332,11 @@ void SAL_CALL SlideShowView::clear() throw (::com::sun::star::uno::RuntimeExcept
}
}
+geometry::IntegerSize2D SAL_CALL SlideShowView::getTranslationOffset( ) throw (RuntimeException)
+{
+ return mTranslationOffset;
+}
+
geometry::AffineMatrix2D SAL_CALL SlideShowView::getTransformation( ) throw (RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
@@ -374,6 +382,10 @@ geometry::AffineMatrix2D SAL_CALL SlideShowView::getTransformation( ) throw (Ru
aOutputSize.Width() --;
aOutputSize.Height() --;
+ // Record mTranslationOffset
+ mTranslationOffset.Height = aOutputOffset.Y();
+ mTranslationOffset.Width = aOutputOffset.X();
+
maPresentationArea = Rectangle( aOutputOffset, aOutputSize );
mrOutputWindow.SetPresentationArea( maPresentationArea );
diff --git a/sd/source/ui/slideshow/slideshowviewimpl.hxx b/sd/source/ui/slideshow/slideshowviewimpl.hxx
index a0239f2a0e14..704d53c2dcf0 100644
--- a/sd/source/ui/slideshow/slideshowviewimpl.hxx
+++ b/sd/source/ui/slideshow/slideshowviewimpl.hxx
@@ -211,6 +211,7 @@ public:
virtual ::com::sun::star::uno::Reference< ::com::sun::star::rendering::XSpriteCanvas > SAL_CALL getCanvas( ) throw (::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL clear( ) throw (::com::sun::star::uno::RuntimeException);
virtual ::com::sun::star::geometry::AffineMatrix2D SAL_CALL getTransformation( ) throw (::com::sun::star::uno::RuntimeException);
+ virtual ::com::sun::star::geometry::IntegerSize2D SAL_CALL getTranslationOffset( ) throw (::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL addTransformationChangedListener( const ::com::sun::star::uno::Reference< ::com::sun::star::util::XModifyListener >& xListener ) throw (::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL removeTransformationChangedListener( const ::com::sun::star::uno::Reference< ::com::sun::star::util::XModifyListener >& 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);
@@ -265,6 +266,7 @@ private:
bool mbFirstPaint;
bool mbFullScreen;
bool mbMousePressedEaten;
+ ::com::sun::star::geometry::IntegerSize2D mTranslationOffset;
};