diff options
Diffstat (limited to 'sfx2/inc/sfx2/viewfrm.hxx')
-rw-r--r-- | sfx2/inc/sfx2/viewfrm.hxx | 66 |
1 files changed, 5 insertions, 61 deletions
diff --git a/sfx2/inc/sfx2/viewfrm.hxx b/sfx2/inc/sfx2/viewfrm.hxx index 06e6b9dcae..81b296b267 100644 --- a/sfx2/inc/sfx2/viewfrm.hxx +++ b/sfx2/inc/sfx2/viewfrm.hxx @@ -40,6 +40,8 @@ #include <com/sun/star/frame/XModel.hpp> #include <com/sun/star/frame/XController2.hpp> +#include <tools/svborder.hxx> + class SfxMacro; class SvBorder; class SfxDispatcher; @@ -70,67 +72,6 @@ SV_DECL_REF(SfxObjectShell) #endif //======================================================================== -#include <tools/gen.hxx> -class SvBorder -{ - long nTop, nRight, nBottom, nLeft; -public: - SvBorder() - { nTop = nRight = nBottom = nLeft = 0; } - SvBorder( const Size & rSz ) - { nTop = nBottom = rSz.Height(); nRight = nLeft = rSz.Width(); } - SvBorder( const Rectangle & rOuter, const Rectangle & rInner ); - SvBorder( long nLeftP, long nTopP, long nRightP, long nBottomP ) - { nLeft = nLeftP; nTop = nTopP; nRight = nRightP; nBottom = nBottomP; } - BOOL operator == ( const SvBorder & rObj ) const - { - return nTop == rObj.nTop && nRight == rObj.nRight && - nBottom == rObj.nBottom && nLeft == rObj.nLeft; - } - BOOL operator != ( const SvBorder & rObj ) const - { return !(*this == rObj); } - SvBorder & operator = ( const SvBorder & rBorder ) - { - Left() = rBorder.Left(); - Top() = rBorder.Top(); - Right() = rBorder.Right(); - Bottom() = rBorder.Bottom(); - return *this; - } - SvBorder & operator += ( const SvBorder & rBorder ) - { - Left() += rBorder.Left(); - Top() += rBorder.Top(); - Right() += rBorder.Right(); - Bottom() += rBorder.Bottom(); - return *this; - } - SvBorder & operator -= ( const SvBorder & rBorder ) - { - Left() -= rBorder.Left(); - Top() -= rBorder.Top(); - Right() -= rBorder.Right(); - Bottom() -= rBorder.Bottom(); - return *this; - } - BOOL IsInside( const SvBorder & rInside ) - { - return nTop >= rInside.nTop && nRight >= rInside.nRight && - nBottom >= rInside.nBottom && nLeft >= rInside.nLeft; - } - long & Top() { return nTop; } - long & Right() { return nRight; } - long & Bottom() { return nBottom; } - long & Left() { return nLeft; } - long Top() const { return nTop; } - long Right() const { return nRight; } - long Bottom() const { return nBottom; } - long Left() const { return nLeft; } -}; -Rectangle & operator += ( Rectangle & rRect, const SvBorder & rBorder ); -Rectangle & operator -= ( Rectangle & rRect, const SvBorder & rBorder ); - - DBG_NAMEEX(SfxViewFrame) class SFX2_DLLPUBLIC SfxViewFrame: public SfxShell, public SfxListener { @@ -228,6 +169,8 @@ public: String UpdateTitle(); + static void ActivateToolPanel( const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& i_rFrame, const ::rtl::OUString& i_rPanelURL ); + // interne Handler SAL_DLLPRIVATE virtual BOOL SetBorderPixelImpl( const SfxViewShell *pSh, const SvBorder &rBorder ); SAL_DLLPRIVATE virtual const SvBorder& GetBorderPixelImpl( const SfxViewShell *pSh ) const; @@ -304,6 +247,7 @@ public: SAL_DLLPRIVATE void INetState_Impl(SfxItemSet &); SAL_DLLPRIVATE void SetCurViewId_Impl( const USHORT i_nID ); + SAL_DLLPRIVATE void ActivateToolPanel_Impl( const ::rtl::OUString& i_rPanelURL ); //#endif private: |