diff options
Diffstat (limited to 'sw/source/ui')
-rw-r--r-- | sw/source/ui/app/apphdl.cxx | 8 | ||||
-rw-r--r-- | sw/source/ui/app/appopt.cxx | 2 | ||||
-rw-r--r-- | sw/source/ui/app/docsh.cxx | 4 | ||||
-rw-r--r-- | sw/source/ui/app/docsh2.cxx | 8 | ||||
-rw-r--r-- | sw/source/ui/app/swmodul1.cxx | 6 | ||||
-rw-r--r-- | sw/source/ui/app/swmodule.cxx | 4 | ||||
-rw-r--r-- | sw/source/ui/dialog/docstdlg.cxx | 4 | ||||
-rw-r--r-- | sw/source/ui/docvw/edtwin3.cxx | 8 | ||||
-rw-r--r-- | sw/source/ui/inc/pview.hxx | 24 | ||||
-rw-r--r-- | sw/source/ui/inc/view.hxx | 4 | ||||
-rw-r--r-- | sw/source/ui/uiview/pview.cxx | 172 | ||||
-rw-r--r-- | sw/source/ui/uiview/view.cxx | 42 | ||||
-rw-r--r-- | sw/source/ui/uiview/viewport.cxx | 2 | ||||
-rw-r--r-- | sw/source/ui/uno/unotxdoc.cxx | 40 |
14 files changed, 164 insertions, 164 deletions
diff --git a/sw/source/ui/app/apphdl.cxx b/sw/source/ui/app/apphdl.cxx index 0f6c57c1d602..cf21d0f3fb06 100644 --- a/sw/source/ui/app/apphdl.cxx +++ b/sw/source/ui/app/apphdl.cxx @@ -761,7 +761,7 @@ void SwModule::ConfigurationChanged( utl::ConfigurationBroadcaster* pBrdCst, sal //invalidate all edit windows const TypeId aSwViewTypeId = TYPE(SwView); - const TypeId aSwPreViewTypeId = TYPE(SwPagePreView); + const TypeId aSwPreviewTypeId = TYPE(SwPagePreview); const TypeId aSwSrcViewTypeId = TYPE(SwSrcView); SfxViewShell* pViewShell = SfxViewShell::GetFirst(); while(pViewShell) @@ -769,15 +769,15 @@ void SwModule::ConfigurationChanged( utl::ConfigurationBroadcaster* pBrdCst, sal if(pViewShell->GetWindow()) { if((pViewShell->IsA(aSwViewTypeId) || - pViewShell->IsA(aSwPreViewTypeId) || + pViewShell->IsA(aSwPreviewTypeId) || pViewShell->IsA(aSwSrcViewTypeId))) { if(bAccessibility) { if(pViewShell->IsA(aSwViewTypeId)) ((SwView*)pViewShell)->ApplyAccessiblityOptions(*pAccessibilityOptions); - else if(pViewShell->IsA(aSwPreViewTypeId)) - ((SwPagePreView*)pViewShell)->ApplyAccessiblityOptions(*pAccessibilityOptions); + else if(pViewShell->IsA(aSwPreviewTypeId)) + ((SwPagePreview*)pViewShell)->ApplyAccessiblityOptions(*pAccessibilityOptions); } pViewShell->GetWindow()->Invalidate(); } diff --git a/sw/source/ui/app/appopt.cxx b/sw/source/ui/app/appopt.cxx index ea719eace8fb..238229ee05e5 100644 --- a/sw/source/ui/app/appopt.cxx +++ b/sw/source/ui/app/appopt.cxx @@ -169,7 +169,7 @@ SfxItemSet* SwModule::CreateItemSet( sal_uInt16 nId ) } if(bTextDialog) pRet->Put(SwPtrItem(FN_PARAM_STDFONTS, GetStdFontConfig())); - if( PTR_CAST( SwPagePreView, SfxViewShell::Current())!=0) + if( PTR_CAST( SwPagePreview, SfxViewShell::Current())!=0) { SfxBoolItem aBool(SfxBoolItem(SID_PRINTPREVIEW, sal_True)); pRet->Put(aBool); diff --git a/sw/source/ui/app/docsh.cxx b/sw/source/ui/app/docsh.cxx index da74ba9afdb0..617e2e9ad779 100644 --- a/sw/source/ui/app/docsh.cxx +++ b/sw/source/ui/app/docsh.cxx @@ -832,7 +832,7 @@ Rectangle SwDocShell::GetVisArea( sal_uInt16 nAspect ) const { if ( nAspect == ASPECT_THUMBNAIL ) { - // PreView: set VisArea to the first page. + // Preview: set VisArea to the first page. SwNodeIndex aIdx( pDoc->GetNodes().GetEndOfExtras(), 1 ); SwCntntNode* pNd = pDoc->GetNodes().GoNext( &aIdx ); @@ -933,7 +933,7 @@ void SwDocShell::GetState(SfxItemSet& rSet) else { SfxBoolItem aBool( SID_PRINTPREVIEW, sal_False ); - if( PTR_CAST( SwPagePreView, SfxViewShell::Current()) ) + if( PTR_CAST( SwPagePreview, SfxViewShell::Current()) ) aBool.SetValue( sal_True ); rSet.Put( aBool ); } diff --git a/sw/source/ui/app/docsh2.cxx b/sw/source/ui/app/docsh2.cxx index 82341c7f7472..25140295dbeb 100644 --- a/sw/source/ui/app/docsh2.cxx +++ b/sw/source/ui/app/docsh2.cxx @@ -403,13 +403,13 @@ void SwDocShell::Execute(SfxRequest& rReq) SfxViewFrame *pTmpFrm = SfxViewFrame::GetFirst(this); SfxViewShell* pViewShell = SfxViewShell::Current(); SwView* pCurrView = dynamic_cast< SwView *> ( pViewShell ); - sal_Bool bCurrent = IS_TYPE( SwPagePreView, pViewShell ); + sal_Bool bCurrent = IS_TYPE( SwPagePreview, pViewShell ); - while( pTmpFrm ) // search PreView + while( pTmpFrm ) // search Preview { if( IS_TYPE( SwView, pTmpFrm->GetViewShell()) ) bOnly = false; - else if( IS_TYPE( SwPagePreView, pTmpFrm->GetViewShell())) + else if( IS_TYPE( SwPagePreview, pTmpFrm->GetViewShell())) { pTmpFrm->GetFrame().Appear(); bFound = true; @@ -433,7 +433,7 @@ void SwDocShell::Execute(SfxRequest& rReq) if( nSlotId ) { - // PagePreView in the WebDocShell + // PagePreview in the WebDocShell // is found under Id ViewShell2. if( ISA(SwWebDocShell) && SID_VIEWSHELL1 == nSlotId ) nSlotId = SID_VIEWSHELL2; diff --git a/sw/source/ui/app/swmodul1.cxx b/sw/source/ui/app/swmodul1.cxx index 235410ecc81c..0bda79bb447c 100644 --- a/sw/source/ui/app/swmodul1.cxx +++ b/sw/source/ui/app/swmodul1.cxx @@ -152,9 +152,9 @@ void SwModule::ApplyUsrPref(const SwViewOption &rUsrPref, SwView* pActView, // with Uno, only sdbcx::View, but not the Module should be changed bool bViewOnly = VIEWOPT_DEST_VIEW_ONLY == nDest; - // fob PreView off - SwPagePreView* pPPView; - if( !pCurrView && 0 != (pPPView = PTR_CAST( SwPagePreView, SfxViewShell::Current())) ) + // fob Preview off + SwPagePreview* pPPView; + if( !pCurrView && 0 != (pPPView = PTR_CAST( SwPagePreview, SfxViewShell::Current())) ) { if(!bViewOnly) pPref->SetUIOptions( rUsrPref ); diff --git a/sw/source/ui/app/swmodule.cxx b/sw/source/ui/app/swmodule.cxx index 72f745f58a0c..cab58197017d 100644 --- a/sw/source/ui/app/swmodule.cxx +++ b/sw/source/ui/app/swmodule.cxx @@ -248,7 +248,7 @@ void SwDLL::RegisterFactories() if ( SvtModuleOptions().IsWriter() ) { SwSrcView::RegisterFactory ( 6 ); - SwPagePreView::RegisterFactory ( 7 ); + SwPagePreview::RegisterFactory ( 7 ); } } @@ -262,7 +262,7 @@ void SwDLL::RegisterInterfaces() SwWebGlosDocShell::RegisterInterface( pMod ); SwView::RegisterInterface( pMod ); SwWebView::RegisterInterface( pMod ); - SwPagePreView::RegisterInterface( pMod ); + SwPagePreview::RegisterInterface( pMod ); SwSrcView::RegisterInterface( pMod ); diff --git a/sw/source/ui/dialog/docstdlg.cxx b/sw/source/ui/dialog/docstdlg.cxx index 8e3f0acfc511..a109c8af1258 100644 --- a/sw/source/ui/dialog/docstdlg.cxx +++ b/sw/source/ui/dialog/docstdlg.cxx @@ -117,8 +117,8 @@ void SwDocStatPage::Update() ViewShell *pSh = 0; if ( pVSh->ISA(SwView) ) pSh = ((SwView*)pVSh)->GetWrtShellPtr(); - else if ( pVSh->ISA(SwPagePreView) ) - pSh = ((SwPagePreView*)pVSh)->GetViewShell(); + else if ( pVSh->ISA(SwPagePreview) ) + pSh = ((SwPagePreview*)pVSh)->GetViewShell(); OSL_ENSURE( pSh, "Shell not found" ); diff --git a/sw/source/ui/docvw/edtwin3.cxx b/sw/source/ui/docvw/edtwin3.cxx index 29fd6332a93b..edc3bd0cb45e 100644 --- a/sw/source/ui/docvw/edtwin3.cxx +++ b/sw/source/ui/docvw/edtwin3.cxx @@ -63,8 +63,8 @@ void SizeNotify(ViewShell* pVwSh, const Size &rSize) { if (pSfxVwSh->ISA(SwView)) ((SwView *)pSfxVwSh)->DocSzChgd(rSize); - else if (pSfxVwSh->ISA(SwPagePreView)) - ((SwPagePreView *)pSfxVwSh)->DocSzChgd( rSize ); + else if (pSfxVwSh->ISA(SwPagePreview)) + ((SwPagePreview *)pSfxVwSh)->DocSzChgd( rSize ); } } @@ -117,8 +117,8 @@ TblChgMode GetTblChgDefaultMode() void RepaintPagePreview( ViewShell* pVwSh, const SwRect& rRect ) { SfxViewShell *pSfxVwSh = pVwSh->GetSfxViewShell(); - if (pSfxVwSh && pSfxVwSh->ISA( SwPagePreView )) - ((SwPagePreView *)pSfxVwSh)->RepaintCoreRect( rRect ); + if (pSfxVwSh && pSfxVwSh->ISA( SwPagePreview )) + ((SwPagePreview *)pSfxVwSh)->RepaintCoreRect( rRect ); } bool JumpToSwMark( ViewShell* pVwSh, const OUString& rMark ) diff --git a/sw/source/ui/inc/pview.hxx b/sw/source/ui/inc/pview.hxx index 12bc22cc56e8..7cf9e832dfca 100644 --- a/sw/source/ui/inc/pview.hxx +++ b/sw/source/ui/inc/pview.hxx @@ -32,7 +32,7 @@ class SwViewOption; class SwDocShell; class SwScrollbar; class ViewShell; -class SwPagePreView; +class SwPagePreview; class ImageButton; class Button; class SwRect; @@ -42,14 +42,14 @@ class SvtAccessibilityOptions; class SwPagePreviewLayout; // Delete member <mnVirtPage> and its accessor -class SwPagePreViewWin : public Window +class SwPagePreviewWin : public Window { ViewShell* mpViewShell; sal_uInt16 mnSttPage; sal_uInt8 mnRow, mnCol; Size maPxWinSize; Fraction maScale; - SwPagePreView& mrView; + SwPagePreview& mrView; bool mbCalcScaleForPreviewLayout; Rectangle maPaintedPreviewDocRect; SwPagePreviewLayout* mpPgPreviewLayout; @@ -59,8 +59,8 @@ class SwPagePreViewWin : public Window using Window::Scroll; public: - SwPagePreViewWin( Window* pParent, SwPagePreView& rView ); - ~SwPagePreViewWin(); + SwPagePreviewWin( Window* pParent, SwPagePreview& rView ); + ~SwPagePreviewWin(); // calls ViewShell::Paint virtual void Paint( const Rectangle& rRect ); @@ -145,14 +145,14 @@ public: /** * View of a document */ -class SW_DLLPUBLIC SwPagePreView: public SfxViewShell +class SW_DLLPUBLIC SwPagePreview: public SfxViewShell { // ViewWindow and handle to core // current dispatcher shell - SwPagePreViewWin aViewWin; + SwPagePreviewWin aViewWin; //viewdata of the previous SwView and the new crsrposition OUString sSwViewData; - //and the new cursor position if the user double click in the PagePreView + //and the new cursor position if the user double click in the PagePreview OUString sNewCrsrPos; // to support keyboard the number of the page to go to can be set too sal_uInt16 nNewPage; @@ -216,7 +216,7 @@ protected: void SetZoom(SvxZoomType eSet, sal_uInt16 nFactor); public: - SFX_DECL_VIEWFACTORY(SwPagePreView); + SFX_DECL_VIEWFACTORY(SwPagePreview); SFX_DECL_INTERFACE(SW_PAGEPREVIEW) TYPEINFO(); @@ -286,12 +286,12 @@ public: */ void SetVScrollbarThumbPos( const sal_uInt16 _nNewThumbPos ); - SwPagePreView( SfxViewFrame* pFrame, SfxViewShell* ); - ~SwPagePreView(); + SwPagePreview( SfxViewFrame* pFrame, SfxViewShell* ); + ~SwPagePreview(); }; // ----------------- inline methods ---------------------- -inline void SwPagePreView::AdjustEditWin() +inline void SwPagePreview::AdjustEditWin() { OuterResizePixel( Point(), GetFrameWindow()->GetOutputSizePixel() ); } diff --git a/sw/source/ui/inc/view.hxx b/sw/source/ui/inc/view.hxx index d6f9d9a365b3..3bad33f9ae0f 100644 --- a/sw/source/ui/inc/view.hxx +++ b/sw/source/ui/inc/view.hxx @@ -178,7 +178,7 @@ class SW_DLLPUBLIC SwView: public SfxViewShell Timer m_aTimer; // for delayed ChgLnks during an action OUString m_aPageStr; // status view, current page OUString m_sSwViewData, - //and the new cursor position if the user double click in the PagePreView + //and the new cursor position if the user double click in the PagePreview m_sNewCrsrPos; // to support keyboard the number of the page to go to can be set too sal_uInt16 m_nNewPage; @@ -265,7 +265,7 @@ class SW_DLLPUBLIC SwView: public SfxViewShell m_bPasteSpecialState : 1, m_bInMailMerge : 1, m_bInDtor : 1, //detect destructor to prevent creating of sub shells while closing - m_bOldShellWasPagePreView : 1, + m_bOldShellWasPagePreview : 1, m_bIsPreviewDoubleClick : 1, // #i114045# m_bMakeSelectionVisible : 1, // transport the bookmark selection m_bAnnotationMode; ///< The real cursor position is inside an annotation. diff --git a/sw/source/ui/uiview/pview.cxx b/sw/source/ui/uiview/pview.cxx index 2d9c3cc11b3f..a594d09160bd 100644 --- a/sw/source/ui/uiview/pview.cxx +++ b/sw/source/ui/uiview/pview.cxx @@ -68,7 +68,7 @@ #include <popup.hrc> #include <view.hrc> -#define SwPagePreView +#define SwPagePreview #include <sfx2/msg.hxx> #include <swslots.hxx> #include <pagepreviewlayout.hxx> @@ -79,14 +79,14 @@ using namespace ::com::sun::star; -SFX_IMPL_NAMED_VIEWFACTORY(SwPagePreView, "PrintPreview") +SFX_IMPL_NAMED_VIEWFACTORY(SwPagePreview, "PrintPreview") { SFX_VIEW_REGISTRATION(SwDocShell); SFX_VIEW_REGISTRATION(SwWebDocShell); SFX_VIEW_REGISTRATION(SwGlobalDocShell); } -SFX_IMPL_INTERFACE(SwPagePreView, SfxViewShell, SW_RES(RID_PVIEW_TOOLBOX)) +SFX_IMPL_INTERFACE(SwPagePreview, SfxViewShell, SW_RES(RID_PVIEW_TOOLBOX)) { SFX_POPUPMENU_REGISTRATION(SW_RES(MN_PPREVIEW_POPUPMENU)); SFX_OBJECTBAR_REGISTRATION( SFX_OBJECTBAR_OBJECT|SFX_VISIBILITY_STANDARD| @@ -95,7 +95,7 @@ SFX_IMPL_INTERFACE(SwPagePreView, SfxViewShell, SW_RES(RID_PVIEW_TOOLBOX)) SW_RES(RID_PVIEW_TOOLBOX)); } -TYPEINIT1(SwPagePreView,SfxViewShell) +TYPEINIT1(SwPagePreview,SfxViewShell) #define SWVIEWFLAGS ( SFX_VIEW_CAN_PRINT|SFX_VIEW_HAS_PRINTOPTIONS ) @@ -135,7 +135,7 @@ static void lcl_InvalidateZoomSlots(SfxBindings& rBindings) } // At first the zoom dialog -class SwPreViewZoomDlg : public SvxStandardDialog +class SwPreviewZoomDlg : public SvxStandardDialog { NumericField* m_pRowEdit; NumericField* m_pColEdit; @@ -143,10 +143,10 @@ class SwPreViewZoomDlg : public SvxStandardDialog virtual void Apply(); public: - SwPreViewZoomDlg( SwPagePreViewWin& rParent ); + SwPreviewZoomDlg( SwPagePreviewWin& rParent ); }; -SwPreViewZoomDlg::SwPreViewZoomDlg( SwPagePreViewWin& rParent ) +SwPreviewZoomDlg::SwPreviewZoomDlg( SwPagePreviewWin& rParent ) : SvxStandardDialog(&rParent, "PreviewZoomDialog", "modules/swriter/ui/previewzoomdialog.ui") { get(m_pRowEdit, "rows"); @@ -156,15 +156,15 @@ SwPreViewZoomDlg::SwPreViewZoomDlg( SwPagePreViewWin& rParent ) m_pColEdit->SetValue( rParent.GetCol() ); } -void SwPreViewZoomDlg::Apply() +void SwPreviewZoomDlg::Apply() { - ((SwPagePreViewWin*)GetParent())->CalcWish( + ((SwPagePreviewWin*)GetParent())->CalcWish( sal_uInt8(m_pRowEdit->GetValue()), sal_uInt8(m_pColEdit->GetValue()) ); } -// all for SwPagePreViewWin -SwPagePreViewWin::SwPagePreViewWin( Window *pParent, SwPagePreView& rPView ) +// all for SwPagePreviewWin +SwPagePreviewWin::SwPagePreviewWin( Window *pParent, SwPagePreview& rPView ) : Window( pParent, WinBits( WB_CLIPCHILDREN) ), mpViewShell( 0 ), mrView( rPView ), @@ -183,12 +183,12 @@ SwPagePreViewWin::SwPagePreViewWin( Window *pParent, SwPagePreView& rPView ) mnSttPage = USHRT_MAX; } -SwPagePreViewWin::~SwPagePreViewWin() +SwPagePreviewWin::~SwPagePreviewWin() { delete mpViewShell; } -void SwPagePreViewWin::Paint( const Rectangle& rRect ) +void SwPagePreviewWin::Paint( const Rectangle& rRect ) { if( !mpViewShell || !mpViewShell->GetLayout() ) return; @@ -216,7 +216,7 @@ void SwPagePreViewWin::Paint( const Rectangle& rRect ) } } -void SwPagePreViewWin::CalcWish( sal_uInt8 nNewRow, sal_uInt8 nNewCol ) +void SwPagePreviewWin::CalcWish( sal_uInt8 nNewRow, sal_uInt8 nNewCol ) { if( !mpViewShell || !mpViewShell->GetLayout() ) return; @@ -262,7 +262,7 @@ void SwPagePreViewWin::CalcWish( sal_uInt8 nNewRow, sal_uInt8 nNewCol ) } // mnSttPage is Absolute -int SwPagePreViewWin::MovePage( int eMoveMode ) +int SwPagePreviewWin::MovePage( int eMoveMode ) { // number of pages up sal_uInt16 nPages = mnRow * mnCol; @@ -363,7 +363,7 @@ int SwPagePreViewWin::MovePage( int eMoveMode ) return sal_True; } -void SwPagePreViewWin::SetWinSize( const Size& rNewSize ) +void SwPagePreviewWin::SetWinSize( const Size& rNewSize ) { // We always want the size as pixel units. maPxWinSize = LogicToPixel( rNewSize ); @@ -390,7 +390,7 @@ void SwPagePreViewWin::SetWinSize( const Size& rNewSize ) maScale = GetMapMode().GetScaleX(); } -OUString SwPagePreViewWin::GetStatusStr( sal_uInt16 nPageCnt ) const +OUString SwPagePreviewWin::GetStatusStr( sal_uInt16 nPageCnt ) const { // show physical and virtual page number of // selected page, if it's visible. @@ -413,7 +413,7 @@ OUString SwPagePreViewWin::GetStatusStr( sal_uInt16 nPageCnt ) const return aStatusStr.makeStringAndClear(); } -void SwPagePreViewWin::KeyInput( const KeyEvent &rKEvt ) +void SwPagePreviewWin::KeyInput( const KeyEvent &rKEvt ) { const KeyCode& rKeyCode = rKEvt.GetKeyCode(); sal_uInt16 nKey = rKeyCode.GetCode(); @@ -438,7 +438,7 @@ void SwPagePreViewWin::KeyInput( const KeyEvent &rKEvt ) Window::KeyInput( rKEvt ); } -void SwPagePreViewWin::Command( const CommandEvent& rCEvt ) +void SwPagePreviewWin::Command( const CommandEvent& rCEvt ) { bool bCallBase = true; switch( rCEvt.GetCommand() ) @@ -472,7 +472,7 @@ void SwPagePreViewWin::Command( const CommandEvent& rCEvt ) Window::Command( rCEvt ); } -void SwPagePreViewWin::MouseButtonDown( const MouseEvent& rMEvt ) +void SwPagePreviewWin::MouseButtonDown( const MouseEvent& rMEvt ) { // consider single-click to set selected page if( MOUSE_LEFT == ( rMEvt.GetModifier() + rMEvt.GetButtons() ) ) @@ -500,7 +500,7 @@ void SwPagePreViewWin::MouseButtonDown( const MouseEvent& rMEvt ) { // show clicked page as the selected one mpPgPreviewLayout->MarkNewSelectedPage( nNewSelectedPage ); - GetViewShell()->ShowPreViewSelection( nNewSelectedPage ); + GetViewShell()->ShowPreviewSelection( nNewSelectedPage ); // adjust position at vertical scrollbar. if ( mpPgPreviewLayout->DoesPreviewLayoutRowsFitIntoWindow() ) { @@ -519,7 +519,7 @@ void SwPagePreViewWin::MouseButtonDown( const MouseEvent& rMEvt ) // Set user prefs or view options -void SwPagePreViewWin::SetPagePreview( sal_uInt8 nRow, sal_uInt8 nCol ) +void SwPagePreviewWin::SetPagePreview( sal_uInt8 nRow, sal_uInt8 nCol ) { SwMasterUsrPref *pOpt = (SwMasterUsrPref *)SW_MOD()->GetUsrPref(sal_False); @@ -538,7 +538,7 @@ void SwPagePreViewWin::SetPagePreview( sal_uInt8 nRow, sal_uInt8 nCol ) @author OD */ -sal_uInt16 SwPagePreViewWin::SelectedPage() const +sal_uInt16 SwPagePreviewWin::SelectedPage() const { return mpPgPreviewLayout->SelectedPage(); } @@ -547,7 +547,7 @@ sal_uInt16 SwPagePreViewWin::SelectedPage() const @author OD */ -void SwPagePreViewWin::SetSelectedPage( sal_uInt16 _nSelectedPageNum ) +void SwPagePreviewWin::SetSelectedPage( sal_uInt16 _nSelectedPageNum ) { mpPgPreviewLayout->SetSelectedPage( _nSelectedPageNum ); } @@ -556,14 +556,14 @@ void SwPagePreViewWin::SetSelectedPage( sal_uInt16 _nSelectedPageNum ) @author OD */ -bool SwPagePreViewWin::SetBookPreviewMode( const bool _bBookPreview ) +bool SwPagePreviewWin::SetBookPreviewMode( const bool _bBookPreview ) { return mpPgPreviewLayout->SetBookPreviewMode( _bBookPreview, mnSttPage, maPaintedPreviewDocRect ); } -void SwPagePreViewWin::DataChanged( const DataChangedEvent& rDCEvt ) +void SwPagePreviewWin::DataChanged( const DataChangedEvent& rDCEvt ) { Window::DataChanged( rDCEvt ); @@ -595,7 +595,7 @@ void SwPagePreViewWin::DataChanged( const DataChangedEvent& rDCEvt ) @author OD */ -void SwPagePreView::_ExecPgUpAndPgDown( const bool _bPgUp, +void SwPagePreview::_ExecPgUpAndPgDown( const bool _bPgUp, SfxRequest* _pReq ) { SwPagePreviewLayout* pPagePreviewLay = GetViewShell()->PagePreviewLayout(); @@ -606,8 +606,8 @@ void SwPagePreView::_ExecPgUpAndPgDown( const bool _bPgUp, pPagePreviewLay->DoesPreviewLayoutColsFitIntoWindow() ) { const int eMvMode = _bPgUp ? - SwPagePreViewWin::MV_PAGE_UP : - SwPagePreViewWin::MV_PAGE_DOWN; + SwPagePreviewWin::MV_PAGE_UP : + SwPagePreviewWin::MV_PAGE_DOWN; if ( ChgPage( eMvMode, sal_True ) ) aViewWin.Invalidate(); } @@ -667,8 +667,8 @@ void SwPagePreView::_ExecPgUpAndPgDown( const bool _bPgUp, _pReq->Done(); } -// Then all for the SwPagePreView -void SwPagePreView::Execute( SfxRequest &rReq ) +// Then all for the SwPagePreview +void SwPagePreview::Execute( SfxRequest &rReq ) { int eMvMode; sal_uInt8 nRow = 1; @@ -695,7 +695,7 @@ void SwPagePreView::Execute( SfxRequest &rReq ) } else - SwPreViewZoomDlg( aViewWin ).Execute(); + SwPreviewZoomDlg( aViewWin ).Execute(); } break; @@ -835,10 +835,10 @@ void SwPagePreView::Execute( SfxRequest &rReq ) { aViewWin.SetSelectedPage( nNewSelectedPage ); aViewWin.SetSttPage( nNewStartPage ); - int nRet = ChgPage( SwPagePreViewWin::MV_SELPAGE, sal_True ); + int nRet = ChgPage( SwPagePreviewWin::MV_SELPAGE, sal_True ); bRefresh = 0 != nRet; } - GetViewShell()->ShowPreViewSelection( nNewSelectedPage ); + GetViewShell()->ShowPreviewSelection( nNewSelectedPage ); // invalidate page status. static sal_uInt16 aInval[] = { @@ -863,11 +863,11 @@ void SwPagePreView::Execute( SfxRequest &rReq ) case FN_START_OF_LINE: case FN_START_OF_DOCUMENT: aViewWin.SetSelectedPage( 1 ); - eMvMode = SwPagePreViewWin::MV_DOC_STT; bRetVal = true; goto MOVEPAGE; + eMvMode = SwPagePreviewWin::MV_DOC_STT; bRetVal = true; goto MOVEPAGE; case FN_END_OF_LINE: case FN_END_OF_DOCUMENT: aViewWin.SetSelectedPage( mnPageCount ); - eMvMode = SwPagePreViewWin::MV_DOC_END; bRetVal = true; goto MOVEPAGE; + eMvMode = SwPagePreviewWin::MV_DOC_END; bRetVal = true; goto MOVEPAGE; MOVEPAGE: { int nRet = ChgPage( eMvMode, sal_True ); @@ -882,7 +882,7 @@ MOVEPAGE: case FN_PRINT_PAGEPREVIEW: { - const SwPagePreViewPrtData* pPPVPD = aViewWin.GetViewShell()->GetDoc()->GetPreViewPrtData(); + const SwPagePreviewPrtData* pPPVPD = aViewWin.GetViewShell()->GetDoc()->GetPreviewPrtData(); // The thing with the orientation if(pPPVPD) { @@ -934,7 +934,7 @@ MOVEPAGE: aViewWin.Invalidate(); } -void SwPagePreView::GetState( SfxItemSet& rSet ) +void SwPagePreview::GetState( SfxItemSet& rSet ) { SfxWhichIter aIter(rSet); sal_uInt8 nRow = 1; @@ -1069,7 +1069,7 @@ void SwPagePreView::GetState( SfxItemSet& rSet ) } } -void SwPagePreView::StateUndo(SfxItemSet& rSet) +void SwPagePreview::StateUndo(SfxItemSet& rSet) { SfxWhichIter aIter(rSet); sal_uInt16 nWhich = aIter.FirstWhich(); @@ -1081,7 +1081,7 @@ void SwPagePreView::StateUndo(SfxItemSet& rSet) } } -void SwPagePreView::Init(const SwViewOption * pPrefs) +void SwPagePreview::Init(const SwViewOption * pPrefs) { if ( GetViewShell()->HasDrawView() ) GetViewShell()->GetDrawView()->SetAnimationEnabled( sal_False ); @@ -1141,7 +1141,7 @@ void SwPagePreView::Init(const SwViewOption * pPrefs) pESh->ResetModified(); } -SwPagePreView::SwPagePreView(SfxViewFrame *pViewFrame, SfxViewShell* pOldSh): +SwPagePreview::SwPagePreview(SfxViewFrame *pViewFrame, SfxViewShell* pOldSh): SfxViewShell( pViewFrame, SWVIEWFLAGS ), aViewWin( &pViewFrame->GetWindow(), *this ), nNewPage(USHRT_MAX), @@ -1175,8 +1175,8 @@ SwPagePreView::SwPagePreView(SfxViewFrame *pViewFrame, SfxViewShell* pOldSh): ViewShell *pVS, *pNew; - if( pOldSh && pOldSh->IsA( TYPE( SwPagePreView ) ) ) - pVS = ((SwPagePreView*)pOldSh)->GetViewShell(); + if( pOldSh && pOldSh->IsA( TYPE( SwPagePreview ) ) ) + pVS = ((SwPagePreview*)pOldSh)->GetViewShell(); else { if( pOldSh && pOldSh->IsA( TYPE( SwView ) ) ) @@ -1218,7 +1218,7 @@ SwPagePreView::SwPagePreView(SfxViewFrame *pViewFrame, SfxViewShell* pOldSh): Init(); } -SwPagePreView::~SwPagePreView() +SwPagePreview::~SwPagePreview() { SetWindow( 0 ); @@ -1230,12 +1230,12 @@ SwPagePreView::~SwPagePreView() } -SwDocShell* SwPagePreView::GetDocShell() +SwDocShell* SwPagePreview::GetDocShell() { return PTR_CAST(SwDocShell, GetViewFrame()->GetObjectShell()); } -int SwPagePreView::_CreateScrollbar( sal_Bool bHori ) +int SwPagePreview::_CreateScrollbar( sal_Bool bHori ) { Window *pMDI = &GetViewFrame()->GetWindow(); SwScrollbar** ppScrollbar = bHori ? &pHScrollbar : &pVScrollbar; @@ -1249,7 +1249,7 @@ int SwPagePreView::_CreateScrollbar( sal_Bool bHori ) pPageUpBtn->SetHelpId(GetStaticInterface()->GetSlot(FN_PAGEUP)->GetCommand()); pPageDownBtn = new ImageButton(pMDI, SW_RES( BTN_PAGEDOWN ) ); pPageDownBtn->SetHelpId(GetStaticInterface()->GetSlot(FN_PAGEDOWN)->GetCommand()); - Link aLk( LINK( this, SwPagePreView, BtnPage ) ); + Link aLk( LINK( this, SwPagePreview, BtnPage ) ); pPageUpBtn->SetClickHdl( aLk ); pPageDownBtn->SetClickHdl( aLk ); pPageUpBtn->Show(); @@ -1260,10 +1260,10 @@ int SwPagePreView::_CreateScrollbar( sal_Bool bHori ) ScrollDocSzChg(); (*ppScrollbar)->EnableDrag( sal_True ); - (*ppScrollbar)->SetEndScrollHdl( LINK( this, SwPagePreView, EndScrollHdl )); + (*ppScrollbar)->SetEndScrollHdl( LINK( this, SwPagePreview, EndScrollHdl )); - (*ppScrollbar)->SetScrollHdl( LINK( this, SwPagePreView, ScrollHdl )); + (*ppScrollbar)->SetScrollHdl( LINK( this, SwPagePreview, ScrollHdl )); InvalidateBorder(); (*ppScrollbar)->ExtendedShow(); @@ -1272,21 +1272,21 @@ int SwPagePreView::_CreateScrollbar( sal_Bool bHori ) // Button-Handler -IMPL_LINK_INLINE_START( SwPagePreView, BtnPage, Button *, pButton ) +IMPL_LINK_INLINE_START( SwPagePreview, BtnPage, Button *, pButton ) { // use new helper method to perform page up // respectively page down. _ExecPgUpAndPgDown( pButton == pPageUpBtn ); return 0; } -IMPL_LINK_INLINE_END( SwPagePreView, BtnPage, Button *, pButton ) +IMPL_LINK_INLINE_END( SwPagePreview, BtnPage, Button *, pButton ) -int SwPagePreView::ChgPage( int eMvMode, int bUpdateScrollbar ) +int SwPagePreview::ChgPage( int eMvMode, int bUpdateScrollbar ) { Rectangle aPixVisArea( aViewWin.LogicToPixel( aVisArea ) ); int bChg = aViewWin.MovePage( eMvMode ) || - eMvMode == SwPagePreViewWin::MV_CALC || - eMvMode == SwPagePreViewWin::MV_NEWWINSIZE; + eMvMode == SwPagePreviewWin::MV_CALC || + eMvMode == SwPagePreviewWin::MV_NEWWINSIZE; aVisArea = aViewWin.PixelToLogic( aPixVisArea ); if( bChg ) @@ -1312,7 +1312,7 @@ int SwPagePreView::ChgPage( int eMvMode, int bUpdateScrollbar ) } // From here, everything was taken from the SwView. -void SwPagePreView::CalcAndSetBorderPixel( SvBorder &rToFill, sal_Bool /*bInner*/ ) +void SwPagePreview::CalcAndSetBorderPixel( SvBorder &rToFill, sal_Bool /*bInner*/ ) { const StyleSettings &rSet = aViewWin.GetSettings().GetStyleSettings(); const long nTmp = rSet.GetScrollBarSize(); @@ -1323,7 +1323,7 @@ void SwPagePreView::CalcAndSetBorderPixel( SvBorder &rToFill, sal_Bool /*bInner* SetBorderPixel( rToFill ); } -void SwPagePreView::InnerResizePixel( const Point &rOfst, const Size &rSize ) +void SwPagePreview::InnerResizePixel( const Point &rOfst, const Size &rSize ) { SvBorder aBorder; CalcAndSetBorderPixel( aBorder, sal_True ); @@ -1339,7 +1339,7 @@ void SwPagePreView::InnerResizePixel( const Point &rOfst, const Size &rSize ) // Never set VisArea ! } -void SwPagePreView::OuterResizePixel( const Point &rOfst, const Size &rSize ) +void SwPagePreview::OuterResizePixel( const Point &rOfst, const Size &rSize ) { SvBorder aBorder; CalcAndSetBorderPixel( aBorder, sal_False ); @@ -1365,7 +1365,7 @@ void SwPagePreView::OuterResizePixel( const Point &rOfst, const Size &rSize ) *pHScrollbar, pPageUpBtn, pPageDownBtn, 0, *pScrollFill ); } -void SwPagePreView::SetVisArea( const Rectangle &rRect, sal_Bool bUpdateScrollbar ) +void SwPagePreview::SetVisArea( const Rectangle &rRect, sal_Bool bUpdateScrollbar ) { const Point aTopLeft(AlignToPixel(rRect.TopLeft())); const Point aBottomRight(AlignToPixel(rRect.BottomRight())); @@ -1408,12 +1408,12 @@ void SwPagePreView::SetVisArea( const Rectangle &rRect, sal_Bool bUpdateScrollba // Set at View-Win the current size aVisArea = aLR; aViewWin.SetWinSize( aLR.GetSize() ); - ChgPage( SwPagePreViewWin::MV_NEWWINSIZE, bUpdateScrollbar ); + ChgPage( SwPagePreviewWin::MV_NEWWINSIZE, bUpdateScrollbar ); aViewWin.Invalidate(); } -IMPL_LINK( SwPagePreView, ScrollHdl, SwScrollbar *, pScrollbar ) +IMPL_LINK( SwPagePreview, ScrollHdl, SwScrollbar *, pScrollbar ) { if(!GetViewShell()) return 0; @@ -1446,7 +1446,7 @@ IMPL_LINK( SwPagePreView, ScrollHdl, SwScrollbar *, pScrollbar ) return 0; } -IMPL_LINK( SwPagePreView, EndScrollHdl, SwScrollbar *, pScrollbar ) +IMPL_LINK( SwPagePreview, EndScrollHdl, SwScrollbar *, pScrollbar ) { if(!GetViewShell()) return 0; @@ -1482,7 +1482,7 @@ IMPL_LINK( SwPagePreView, EndScrollHdl, SwScrollbar *, pScrollbar ) { aViewWin.SetSttPage( nThmbPos ); aViewWin.SetSelectedPage( nThmbPos ); - ChgPage( SwPagePreViewWin::MV_SCROLL, sal_False ); + ChgPage( SwPagePreviewWin::MV_SCROLL, sal_False ); // update scrollbars ScrollViewSzChg(); } @@ -1502,7 +1502,7 @@ IMPL_LINK( SwPagePreView, EndScrollHdl, SwScrollbar *, pScrollbar ) } } // update accessibility - GetViewShell()->ShowPreViewSelection( nThmbPos ); + GetViewShell()->ShowPreviewSelection( nThmbPos ); } else { @@ -1537,12 +1537,12 @@ IMPL_LINK( SwPagePreView, EndScrollHdl, SwScrollbar *, pScrollbar ) return 0; } -Point SwPagePreView::AlignToPixel(const Point &rPt) const +Point SwPagePreview::AlignToPixel(const Point &rPt) const { return aViewWin.PixelToLogic( aViewWin.LogicToPixel( rPt ) ); } -void SwPagePreView::DocSzChgd( const Size &rSz ) +void SwPagePreview::DocSzChgd( const Size &rSz ) { if( aDocSz == rSz ) return; @@ -1556,14 +1556,14 @@ void SwPagePreView::DocSzChgd( const Size &rSz ) if( aVisArea.GetWidth() ) { - ChgPage( SwPagePreViewWin::MV_CALC, sal_True ); + ChgPage( SwPagePreviewWin::MV_CALC, sal_True ); ScrollDocSzChg(); aViewWin.Invalidate(); } } -void SwPagePreView::ScrollViewSzChg() +void SwPagePreview::ScrollViewSzChg() { if(!GetViewShell()) return ; @@ -1656,18 +1656,18 @@ void SwPagePreView::ScrollViewSzChg() pScrollFill->Show(bShowVScrollbar && bShowHScrollbar); } -void SwPagePreView::ScrollDocSzChg() +void SwPagePreview::ScrollDocSzChg() { ScrollViewSzChg(); } // All about printing -SfxPrinter* SwPagePreView::GetPrinter( sal_Bool bCreate ) +SfxPrinter* SwPagePreview::GetPrinter( sal_Bool bCreate ) { return aViewWin.GetViewShell()->getIDocumentDeviceAccess()->getPrinter( bCreate ); } -sal_uInt16 SwPagePreView::SetPrinter( SfxPrinter *pNew, sal_uInt16 nDiffFlags, bool ) +sal_uInt16 SwPagePreview::SetPrinter( SfxPrinter *pNew, sal_uInt16 nDiffFlags, bool ) { ViewShell &rSh = *GetViewShell(); SfxPrinter* pOld = rSh.getIDocumentDeviceAccess()->getPrinter( false ); @@ -1721,27 +1721,27 @@ sal_uInt16 SwPagePreView::SetPrinter( SfxPrinter *pNew, sal_uInt16 nDiffFlags, return 0; } -bool SwPagePreView::HasPrintOptionsPage() const +bool SwPagePreview::HasPrintOptionsPage() const { return true; } -SfxTabPage* SwPagePreView::CreatePrintOptionsPage( Window *pParent, +SfxTabPage* SwPagePreview::CreatePrintOptionsPage( Window *pParent, const SfxItemSet &rOptions ) { return ::CreatePrintOptionsPage( pParent, rOptions, !bNormalPrint ); } -void SwPagePreViewWin::SetViewShell( ViewShell* pShell ) +void SwPagePreviewWin::SetViewShell( ViewShell* pShell ) { mpViewShell = pShell; - if ( mpViewShell && mpViewShell->IsPreView() ) + if ( mpViewShell && mpViewShell->IsPreview() ) { mpPgPreviewLayout = mpViewShell->PagePreviewLayout(); } } -void SwPagePreViewWin::RepaintCoreRect( const SwRect& rRect ) +void SwPagePreviewWin::RepaintCoreRect( const SwRect& rRect ) { // #i24183# if ( mpPgPreviewLayout->PreviewLayoutValid() ) @@ -1754,7 +1754,7 @@ void SwPagePreViewWin::RepaintCoreRect( const SwRect& rRect ) #i19975# also consider zoom type - adding parameter <_eZoomType> */ -void SwPagePreViewWin::AdjustPreviewToNewZoom( const sal_uInt16 _nZoomFactor, +void SwPagePreviewWin::AdjustPreviewToNewZoom( const sal_uInt16 _nZoomFactor, const SvxZoomType _eZoomType ) { // #i19975# consider zoom type @@ -1798,7 +1798,7 @@ void SwPagePreViewWin::AdjustPreviewToNewZoom( const sal_uInt16 _nZoomFactor, * when less than the desired number of rows fits into * the view */ -void SwPagePreViewWin::Scroll(long nXMove, long nYMove, sal_uInt16 /*nFlags*/) +void SwPagePreviewWin::Scroll(long nXMove, long nYMove, sal_uInt16 /*nFlags*/) { maPaintedPreviewDocRect.Move(nXMove, nYMove); mpPgPreviewLayout->Prepare( 0, maPaintedPreviewDocRect.TopLeft(), @@ -1807,7 +1807,7 @@ void SwPagePreViewWin::Scroll(long nXMove, long nYMove, sal_uInt16 /*nFlags*/) } -sal_Bool SwPagePreView::HandleWheelCommands( const CommandEvent& rCEvt ) +sal_Bool SwPagePreview::HandleWheelCommands( const CommandEvent& rCEvt ) { sal_Bool bOk = sal_False; const CommandWheelData* pWData = rCEvt.GetWheelData(); @@ -1839,7 +1839,7 @@ sal_Bool SwPagePreView::HandleWheelCommands( const CommandEvent& rCEvt ) } uno::Reference< ::com::sun::star::accessibility::XAccessible > - SwPagePreViewWin::CreateAccessible() + SwPagePreviewWin::CreateAccessible() { SolarMutexGuard aGuard; // this should have happened already!!! @@ -1847,24 +1847,24 @@ uno::Reference< ::com::sun::star::accessibility::XAccessible > return GetViewShell()->CreateAccessiblePreview(); } -void SwPagePreView::ApplyAccessiblityOptions(SvtAccessibilityOptions& rAccessibilityOptions) +void SwPagePreview::ApplyAccessiblityOptions(SvtAccessibilityOptions& rAccessibilityOptions) { GetViewShell()->ApplyAccessiblityOptions(rAccessibilityOptions); } -void SwPagePreView::ShowHScrollbar(sal_Bool bShow) +void SwPagePreview::ShowHScrollbar(sal_Bool bShow) { pHScrollbar->Show(bShow); InvalidateBorder(); } -void SwPagePreView::ShowVScrollbar(sal_Bool bShow) +void SwPagePreview::ShowVScrollbar(sal_Bool bShow) { pVScrollbar->Show(bShow); InvalidateBorder(); } -void SwPagePreView::EnableHScrollbar(bool bEnable) +void SwPagePreview::EnableHScrollbar(bool bEnable) { if (mbHScrollbarEnabled != bEnable) { @@ -1873,7 +1873,7 @@ void SwPagePreView::EnableHScrollbar(bool bEnable) } } -void SwPagePreView::EnableVScrollbar(bool bEnable) +void SwPagePreview::EnableVScrollbar(bool bEnable) { if (mbVScrollbarEnabled != bEnable) { @@ -1882,7 +1882,7 @@ void SwPagePreView::EnableVScrollbar(bool bEnable) } } -void SwPagePreView::SetZoom(SvxZoomType eType, sal_uInt16 nFactor) +void SwPagePreview::SetZoom(SvxZoomType eType, sal_uInt16 nFactor) { ViewShell& rSh = *GetViewShell(); SwViewOption aOpt(*rSh.GetViewOptions()); @@ -1904,7 +1904,7 @@ void SwPagePreView::SetZoom(SvxZoomType eType, sal_uInt16 nFactor) @author OD */ -void SwPagePreView::SetVScrollbarThumbPos( const sal_uInt16 _nNewThumbPos ) +void SwPagePreview::SetVScrollbarThumbPos( const sal_uInt16 _nNewThumbPos ) { if ( pVScrollbar ) { diff --git a/sw/source/ui/uiview/view.cxx b/sw/source/ui/uiview/view.cxx index 5737625dba9e..e775097cc320 100644 --- a/sw/source/ui/uiview/view.cxx +++ b/sw/source/ui/uiview/view.cxx @@ -727,7 +727,7 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) m_bWheelScrollInProgress(false), m_bInMailMerge(sal_False), m_bInDtor(sal_False), - m_bOldShellWasPagePreView(sal_False), + m_bOldShellWasPagePreview(sal_False), m_bIsPreviewDoubleClick(sal_False), m_bAnnotationMode(false) { @@ -784,12 +784,12 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) { pExistingSh = pOldSh; // determine type of existing view - if( pExistingSh->IsA( TYPE( SwPagePreView ) ) ) + if( pExistingSh->IsA( TYPE( SwPagePreview ) ) ) { - m_sSwViewData = ((SwPagePreView*)pExistingSh)->GetPrevSwViewData(); - m_sNewCrsrPos = ((SwPagePreView*)pExistingSh)->GetNewCrsrPos(); - m_nNewPage = ((SwPagePreView*)pExistingSh)->GetNewPage(); - m_bOldShellWasPagePreView = sal_True; + m_sSwViewData = ((SwPagePreview*)pExistingSh)->GetPrevSwViewData(); + m_sNewCrsrPos = ((SwPagePreview*)pExistingSh)->GetNewCrsrPos(); + m_nNewPage = ((SwPagePreview*)pExistingSh)->GetNewPage(); + m_bOldShellWasPagePreview = sal_True; m_bIsPreviewDoubleClick = !m_sNewCrsrPos.isEmpty() || m_nNewPage != USHRT_MAX; } else if( pExistingSh->IsA( TYPE( SwSrcView ) ) ) @@ -811,7 +811,7 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) { SwDoc& rDoc = *((SwDocShell*)pDocSh)->GetDoc(); - if( !bOldShellWasSrcView && pWebDShell && !m_bOldShellWasPagePreView ) + if( !bOldShellWasSrcView && pWebDShell && !m_bOldShellWasPagePreview ) aUsrPref.setBrowseMode( sal_True ); else aUsrPref.setBrowseMode( rDoc.get(IDocumentSettingAccess::BROWSE_MODE) ); @@ -829,26 +829,26 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) aUsrPref.SetViewLayoutColumns( 1 ); } m_pWrtShell = new SwWrtShell( rDoc, m_pEditWin, *this, &aUsrPref ); - // creating an SwView from a SwPagePreView needs to + // creating an SwView from a SwPagePreview needs to // add the ViewShell to the ring of the other ViewShell(s) - if(m_bOldShellWasPagePreView) + if(m_bOldShellWasPagePreview) { - ViewShell& rPreviewViewShell = *((SwPagePreView*)pExistingSh)->GetViewShell(); + ViewShell& rPreviewViewShell = *((SwPagePreview*)pExistingSh)->GetViewShell(); m_pWrtShell->MoveTo(&rPreviewViewShell); // to update the field command et.al. if necessary - const SwViewOption* pPreViewOpt = rPreviewViewShell.GetViewOptions(); - if( pPreViewOpt->IsFldName() != aUsrPref.IsFldName() || - pPreViewOpt->IsShowHiddenField() != aUsrPref.IsShowHiddenField() || - pPreViewOpt->IsShowHiddenPara() != aUsrPref.IsShowHiddenPara() || - pPreViewOpt->IsShowHiddenChar() != aUsrPref.IsShowHiddenChar() ) + const SwViewOption* pPreviewOpt = rPreviewViewShell.GetViewOptions(); + if( pPreviewOpt->IsFldName() != aUsrPref.IsFldName() || + pPreviewOpt->IsShowHiddenField() != aUsrPref.IsShowHiddenField() || + pPreviewOpt->IsShowHiddenPara() != aUsrPref.IsShowHiddenPara() || + pPreviewOpt->IsShowHiddenChar() != aUsrPref.IsShowHiddenChar() ) rPreviewViewShell.ApplyViewOptions(aUsrPref); // reset design mode at draw view for form // shell, if needed. - if ( ((SwPagePreView*)pExistingSh)->ResetFormDesignMode() && + if ( ((SwPagePreview*)pExistingSh)->ResetFormDesignMode() && m_pWrtShell->HasDrawView() ) { SdrView* pDrawView = m_pWrtShell->GetDrawView(); - pDrawView->SetDesignMode( ((SwPagePreView*)pExistingSh)->FormDesignModeToReset() ); + pDrawView->SetDesignMode( ((SwPagePreview*)pExistingSh)->FormDesignModeToReset() ); } } } @@ -1185,7 +1185,7 @@ void SwView::ReadUserData( const OUString &rUserData, bool bBrowse ) m_pWrtShell->SetMacroExecAllowed( false ); // os: changed: The user data has to be read if the view is switched back from page preview // go to the last editing position when opening own files - if(m_bOldShellWasPagePreView || bIsOwnDocument) + if(m_bOldShellWasPagePreview || bIsOwnDocument) { m_pWrtShell->SwCrsrShell::SetCrsr( aCrsrPos, !bSelectObj ); if( bSelectObj ) @@ -1203,7 +1203,7 @@ void SwView::ReadUserData( const OUString &rUserData, bool bBrowse ) // is lost. // os: changed: The user data has to be read if the view is switched back from page preview // go to the last editing position when opening own files - if(m_bOldShellWasPagePreView || bIsOwnDocument ) + if(m_bOldShellWasPagePreview || bIsOwnDocument ) { if ( bBrowse ) SetVisArea( aVis.TopLeft() ); @@ -1367,7 +1367,7 @@ void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue > // os: changed: The user data has to be read if the view is switched back from page preview // go to the last editing position when opening own files m_pViewImpl->SetRestorePosition(aCrsrPos, bSelectObj); - if(m_bOldShellWasPagePreView|| bIsOwnDocument) + if(m_bOldShellWasPagePreview|| bIsOwnDocument) { m_pWrtShell->SwCrsrShell::SetCrsr( aCrsrPos, !bSelectObj ); @@ -1434,7 +1434,7 @@ void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue > // os: changed: The user data has to be read if the view is switched back from page preview // go to the last editing position when opening own files - if(m_bOldShellWasPagePreView||bIsOwnDocument) + if(m_bOldShellWasPagePreview||bIsOwnDocument) { if ( bBrowse && bGotVisibleLeft && bGotVisibleTop ) { diff --git a/sw/source/ui/uiview/viewport.cxx b/sw/source/ui/uiview/viewport.cxx index a5fb8de8f962..cc1a90143d87 100644 --- a/sw/source/ui/uiview/viewport.cxx +++ b/sw/source/ui/uiview/viewport.cxx @@ -841,7 +841,7 @@ void ViewResizePixel( const Window &rRef, sal_Bool bWebView, sal_Bool bVRulerRight ) { -// ViewResizePixel is also used by PreView!!! +// ViewResizePixel is also used by Preview!!! const sal_Bool bHRuler = pHRuler && pHRuler->IsVisible(); const long nHLinSzHeight = bHRuler ? diff --git a/sw/source/ui/uno/unotxdoc.cxx b/sw/source/ui/uno/unotxdoc.cxx index 671a27d3678d..a051c7014f3a 100644 --- a/sw/source/ui/uno/unotxdoc.cxx +++ b/sw/source/ui/uno/unotxdoc.cxx @@ -180,10 +180,10 @@ static SwPrintUIOptions * lcl_GetPrintUIOptions( } else if (!bSwSrcView) { - const SwPagePreView* pPreView = dynamic_cast< const SwPagePreView* >(pView); - OSL_ENSURE(pPreView, "Unexpected type of the view shell"); - if (pPreView) - nCurrentPage = pPreView->GetSelectedPage(); + const SwPagePreview* pPreview = dynamic_cast< const SwPagePreview* >(pView); + OSL_ENSURE(pPreview, "Unexpected type of the view shell"); + if (pPreview) + nCurrentPage = pPreview->GetSelectedPage(); } return new SwPrintUIOptions( nCurrentPage, bWebDoc, bSwSrcView, bHasSelection, bHasPostIts, rPrintData ); } @@ -989,8 +989,8 @@ Sequence< beans::PropertyValue > SwXTextDocument::getPagePrintSettings(void) if(IsValid()) { beans::PropertyValue* pArray = aSeq.getArray(); - SwPagePreViewPrtData aData; - const SwPagePreViewPrtData* pData = pDocShell->GetDoc()->GetPreViewPrtData(); + SwPagePreviewPrtData aData; + const SwPagePreviewPrtData* pData = pDocShell->GetDoc()->GetPreviewPrtData(); if(pData) aData = *pData; Any aVal; @@ -1066,9 +1066,9 @@ void SwXTextDocument::setPagePrintSettings(const Sequence< beans::PropertyValue SolarMutexGuard aGuard; if(IsValid()) { - SwPagePreViewPrtData aData; + SwPagePreviewPrtData aData; //if only a few properties are coming, then use the current settings - const SwPagePreViewPrtData* pData = pDocShell->GetDoc()->GetPreViewPrtData(); + const SwPagePreviewPrtData* pData = pDocShell->GetDoc()->GetPreviewPrtData(); if(pData) aData = *pData; const beans::PropertyValue* pProperties = aSettings.getConstArray(); @@ -1125,7 +1125,7 @@ void SwXTextDocument::setPagePrintSettings(const Sequence< beans::PropertyValue if(bException) throw RuntimeException(); } - pDocShell->GetDoc()->SetPreViewPrtData(&aData); + pDocShell->GetDoc()->SetPreviewPrtData(&aData); } else throw RuntimeException(); @@ -2554,7 +2554,7 @@ sal_Int32 SAL_CALL SwXTextDocument::getRendererCount( pViewShell = ((SwView*)m_pHiddenViewFrame->GetViewShell())->GetWrtShellPtr(); } else - pViewShell = ((SwPagePreView*)pView)->GetViewShell(); + pViewShell = ((SwPagePreview*)pView)->GetViewShell(); } if (!pViewShell || !pViewShell->GetLayout()) @@ -2716,7 +2716,7 @@ uno::Sequence< beans::PropertyValue > SAL_CALL SwXTextDocument::getRenderer( if ( pSwView ) pVwSh = pSwView->GetWrtShellPtr(); else - pVwSh = ((SwPagePreView*)pView)->GetViewShell(); + pVwSh = ((SwPagePreview*)pView)->GetViewShell(); sal_Int32 nMaxRenderer = 0; if (!bIsSwSrcView && m_pRenderData) @@ -2837,8 +2837,8 @@ uno::Sequence< beans::PropertyValue > SAL_CALL SwXTextDocument::getRenderer( // #i117783# if ( bApplyPagePrintSettingsFromXPagePrintable ) { - const SwPagePreViewPrtData* pPagePrintSettings = - pDocShell->GetDoc()->GetPreViewPrtData(); + const SwPagePreviewPrtData* pPagePrintSettings = + pDocShell->GetDoc()->GetPreviewPrtData(); if ( pPagePrintSettings && ( pPagePrintSettings->GetRow() > 1 || pPagePrintSettings->GetCol() > 1 ) ) @@ -2904,20 +2904,20 @@ SfxViewShell * SwXTextDocument::GuessViewShell( // SfxViewShell *pView = 0; SwView *pSwView = 0; - SwPagePreView *pSwPagePreView = 0; + SwPagePreview *pSwPagePreview = 0; SwSrcView *pSwSrcView = 0; SfxViewFrame *pFrame = SfxViewFrame::GetFirst( pDocShell, sal_False ); // look for the view shell with the same controller in use, // otherwise look for a suitable view, preferably a SwView, - // if that one is not found use a SwPagePreView if found. + // if that one is not found use a SwPagePreview if found. while (pFrame) { pView = pFrame->GetViewShell(); pSwView = dynamic_cast< SwView * >(pView); pSwSrcView = dynamic_cast< SwSrcView * >(pView); - if (!pSwPagePreView) - pSwPagePreView = dynamic_cast< SwPagePreView * >(pView); + if (!pSwPagePreview) + pSwPagePreview = dynamic_cast< SwPagePreview * >(pView); if (xController.is()) { if (pView && pView->GetController() == xController) @@ -2928,7 +2928,7 @@ SfxViewShell * SwXTextDocument::GuessViewShell( pFrame = SfxViewFrame::GetNext( *pFrame, pDocShell, sal_False ); } - OSL_ENSURE( pSwView || pSwPagePreView || pSwSrcView, "failed to get view shell" ); + OSL_ENSURE( pSwView || pSwPagePreview || pSwSrcView, "failed to get view shell" ); if (pView) rbIsSwSrcView = pSwSrcView != 0; return pView; @@ -2992,7 +2992,7 @@ void SAL_CALL SwXTextDocument::render( else { // the view shell should be SwView for documents PDF export - // or SwPagePreView for PDF export of the page preview + // or SwPagePreview for PDF export of the page preview //!! (check for SwView first as in GuessViewShell) !! OSL_ENSURE( pView, "!! view missing !!" ); const TypeId aSwViewTypeId = TYPE(SwView); @@ -3004,7 +3004,7 @@ void SAL_CALL SwXTextDocument::render( if ( pSwView ) pVwSh = pSwView->GetWrtShellPtr(); else - pVwSh = ((SwPagePreView*)pView)->GetViewShell(); + pVwSh = ((SwPagePreview*)pView)->GetViewShell(); } // get output device to use |