diff options
author | Miklos Vajna <vmiklos@suse.cz> | 2013-03-23 16:14:56 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@suse.cz> | 2013-03-23 16:15:55 +0100 |
commit | d4ebfc7e3fc8996dc0f52fcf228ba37a6af0f499 (patch) | |
tree | 77acc22bd6b6fe6dceda0dea6ee9f78fcd3d1cde /sw | |
parent | 015131c87e14f84040cfa579bc81419714cbe964 (diff) |
SwView: rename member variables missing their prefix
Change-Id: Ib382d3e3bab87b2e1dd32060da977289e4dc601e
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/ui/docvw/edtwin.cxx | 20 | ||||
-rw-r--r-- | sw/source/ui/inc/view.hxx | 256 | ||||
-rw-r--r-- | sw/source/ui/uiview/uivwimp.cxx | 6 | ||||
-rw-r--r-- | sw/source/ui/uiview/view.cxx | 714 | ||||
-rw-r--r-- | sw/source/ui/uiview/view0.cxx | 16 | ||||
-rw-r--r-- | sw/source/ui/uiview/view1.cxx | 54 | ||||
-rw-r--r-- | sw/source/ui/uiview/view2.cxx | 304 | ||||
-rw-r--r-- | sw/source/ui/uiview/viewdlg.cxx | 10 | ||||
-rw-r--r-- | sw/source/ui/uiview/viewdlg2.cxx | 2 | ||||
-rw-r--r-- | sw/source/ui/uiview/viewdraw.cxx | 140 | ||||
-rw-r--r-- | sw/source/ui/uiview/viewling.cxx | 184 | ||||
-rw-r--r-- | sw/source/ui/uiview/viewmdi.cxx | 218 | ||||
-rw-r--r-- | sw/source/ui/uiview/viewport.cxx | 436 | ||||
-rw-r--r-- | sw/source/ui/uiview/viewsrch.cxx | 392 | ||||
-rw-r--r-- | sw/source/ui/uiview/viewstat.cxx | 104 | ||||
-rw-r--r-- | sw/source/ui/uiview/viewtab.cxx | 96 |
16 files changed, 1476 insertions, 1476 deletions
diff --git a/sw/source/ui/docvw/edtwin.cxx b/sw/source/ui/docvw/edtwin.cxx index 226fd98613b4..fca328133816 100644 --- a/sw/source/ui/docvw/edtwin.cxx +++ b/sw/source/ui/docvw/edtwin.cxx @@ -339,8 +339,8 @@ void SwEditWin::UpdatePointer(const Point &rLPt, sal_uInt16 nModifier ) const SwFrmFmt* pFmt = 0; bool bFrameIsValidTarget = false; - if( m_pApplyTempl->pFormatClipboard ) - bFrameIsValidTarget = m_pApplyTempl->pFormatClipboard->HasContentForThisType( nsSelectionType::SEL_FRM ); + if( m_pApplyTempl->m_pFormatClipboard ) + bFrameIsValidTarget = m_pApplyTempl->m_pFormatClipboard->HasContentForThisType( nsSelectionType::SEL_FRM ); else if( !m_pApplyTempl->nColor ) bFrameIsValidTarget = ( m_pApplyTempl->eType == SFX_STYLE_FAMILY_FRAME ); @@ -1285,9 +1285,9 @@ void SwEditWin::KeyInput(const KeyEvent &rKEvt) SwWrtShell &rSh = m_rView.GetWrtShell(); if( rKEvt.GetKeyCode().GetCode() == KEY_ESCAPE && - m_pApplyTempl && m_pApplyTempl->pFormatClipboard ) + m_pApplyTempl && m_pApplyTempl->m_pFormatClipboard ) { - m_pApplyTempl->pFormatClipboard->Erase(); + m_pApplyTempl->m_pFormatClipboard->Erase(); SetApplyTemplate(SwApplyTemplate()); m_rView.GetViewFrame()->GetBindings().Invalidate(SID_FORMATPAINTBRUSH); } @@ -2747,8 +2747,8 @@ void SwEditWin::MouseButtonDown(const MouseEvent& _rMEvt) //ignore key modifiers for format paintbrush { - bool bExecFormatPaintbrush = m_pApplyTempl && m_pApplyTempl->pFormatClipboard - && m_pApplyTempl->pFormatClipboard->HasContent(); + bool bExecFormatPaintbrush = m_pApplyTempl && m_pApplyTempl->m_pFormatClipboard + && m_pApplyTempl->m_pFormatClipboard->HasContent(); if( bExecFormatPaintbrush ) rMEvt = MouseEvent( _rMEvt.GetPosPixel(), _rMEvt.GetClicks(), _rMEvt.GetMode(), _rMEvt.GetButtons() ); @@ -3646,8 +3646,8 @@ void SwEditWin::MouseMove(const MouseEvent& _rMEvt) //ignore key modifiers for format paintbrush { - bool bExecFormatPaintbrush = m_pApplyTempl && m_pApplyTempl->pFormatClipboard - && m_pApplyTempl->pFormatClipboard->HasContent(); + bool bExecFormatPaintbrush = m_pApplyTempl && m_pApplyTempl->m_pFormatClipboard + && m_pApplyTempl->m_pFormatClipboard->HasContent(); if( bExecFormatPaintbrush ) rMEvt = MouseEvent( _rMEvt.GetPosPixel(), _rMEvt.GetClicks(), _rMEvt.GetMode(), _rMEvt.GetButtons() ); @@ -4550,7 +4550,7 @@ void SwEditWin::MouseButtonUp(const MouseEvent& rMEvt) if( m_pApplyTempl ) { int eSelection = rSh.GetSelectionType(); - SwFormatClipboard* pFormatClipboard = m_pApplyTempl->pFormatClipboard; + SwFormatClipboard* pFormatClipboard = m_pApplyTempl->m_pFormatClipboard; if( pFormatClipboard )//apply format paintbrush { //get some parameters @@ -4722,7 +4722,7 @@ void SwEditWin::SetApplyTemplate(const SwApplyTemplate &rTempl) DELETEZ(m_pApplyTempl); SwWrtShell &rSh = m_rView.GetWrtShell(); - if(rTempl.pFormatClipboard) + if(rTempl.m_pFormatClipboard) { m_pApplyTempl = new SwApplyTemplate( rTempl ); SetPointer( POINTER_FILL );//@todo #i20119# maybe better a new brush pointer here in future diff --git a/sw/source/ui/inc/view.hxx b/sw/source/ui/inc/view.hxx index 1b5a8b9b615d..2268c631ded8 100644 --- a/sw/source/ui/inc/view.hxx +++ b/sw/source/ui/inc/view.hxx @@ -132,13 +132,13 @@ struct SwApplyTemplate int eType; sal_uInt16 nColor; - SwFormatClipboard* pFormatClipboard; + SwFormatClipboard* m_pFormatClipboard; bool bUndo; SwApplyTemplate() : eType(0), nColor(0), - pFormatClipboard(0), + m_pFormatClipboard(0), bUndo(false) { aColl.pTxtColl = 0; @@ -156,118 +156,118 @@ class SW_DLLPUBLIC SwView: public SfxViewShell friend class SwClipboardChangeListener; // search & replace - static SvxSearchDialog *pSrchDlg; - static SvxSearchItem *pSrchItem; + static SvxSearchDialog *m_pSrchDlg; + static SvxSearchItem *m_pSrchItem; - static sal_uInt16 nInsertCtrlState; - static sal_uInt16 nWebInsertCtrlState; - static sal_uInt16 nInsertObjectCtrlState; - static sal_uInt16 nInsertFieldCtrlState; - static sal_uInt16 nMoveType; // for buttons below the scrollbar (viewmdi) - static sal_Int32 nActMark; // current jump mark for unknown mark + static sal_uInt16 m_nInsertCtrlState; + static sal_uInt16 m_nWebInsertCtrlState; + static sal_uInt16 m_nInsertObjectCtrlState; + static sal_uInt16 m_nInsertFieldCtrlState; + static sal_uInt16 m_nMoveType; // for buttons below the scrollbar (viewmdi) + static sal_Int32 m_nActMark; // current jump mark for unknown mark - static bool bExtra; - static sal_Bool bFound; - static bool bJustOpened; + static bool m_bExtra; + static sal_Bool m_bFound; + static bool m_bJustOpened; - static SearchAttrItemList* pSrchList; - static SearchAttrItemList* pReplList; + static SearchAttrItemList* m_pSrchList; + static SearchAttrItemList* m_pReplList; - SvxHtmlOptions aHTMLOpt; - Timer aTimer; // for delayed ChgLnks during an action - String aPageStr; // status view, current page - String sSwViewData, + SvxHtmlOptions m_aHTMLOpt; + Timer m_aTimer; // for delayed ChgLnks during an action + String m_aPageStr; // status view, current page + String m_sSwViewData, //and the new cursor position if the user double click in the PagePreView - sNewCrsrPos; + m_sNewCrsrPos; // to support keyboard the number of the page to go to can be set too - sal_uInt16 nNewPage; + sal_uInt16 m_nNewPage; - Point aTabColFromDocPos; // moving table colmns out of the document - SwTxtNode * pNumRuleNodeFromDoc; // Moving indent of numrule #i23726# + Point m_aTabColFromDocPos; // moving table colmns out of the document + SwTxtNode * m_pNumRuleNodeFromDoc; // Moving indent of numrule #i23726# - Size aDocSz; // current document size - Rectangle aVisArea; // visible region + Size m_aDocSz; // current document size + Rectangle m_aVisArea; // visible region - SwEditWin *pEditWin; - SwWrtShell *pWrtShell; + SwEditWin *m_pEditWin; + SwWrtShell *m_pWrtShell; - SfxShell *pShell; // current SubShell at the dispatcher - FmFormShell *pFormShell; // DB-FormShell + SfxShell *m_pShell; // current SubShell at the dispatcher + FmFormShell *m_pFormShell; // DB-FormShell - SwView_Impl *pViewImpl; // Impl-data for UNO + Basic + SwView_Impl *m_pViewImpl; // Impl-data for UNO + Basic - SwScrollbar *pHScrollbar, // MDI control elements - *pVScrollbar; + SwScrollbar *m_pHScrollbar, // MDI control elements + *m_pVScrollbar; - bool mbHScrollbarEnabled; - bool mbVScrollbarEnabled; + bool m_bHScrollbarEnabled; + bool m_bVScrollbarEnabled; - Window *pScrollFill; // dummy window for filling the lower right edge + Window *m_pScrollFill; // dummy window for filling the lower right edge // when both scrollbars are active - SvxRuler *pHRuler, - *pVRuler; - ImageButton *pTogglePageBtn; + SvxRuler *m_pHRuler, + *m_pVRuler; + ImageButton *m_pTogglePageBtn; - SwHlpImageButton *pPageUpBtn, - *pPageDownBtn; + SwHlpImageButton *m_pPageUpBtn, + *m_pPageDownBtn; - SwNaviImageButton *pNaviBtn; - SwGlossaryHdl *pGlosHdl; // handle text block - SwDrawBase *pDrawActual; + SwNaviImageButton *m_pNaviBtn; + SwGlossaryHdl *m_pGlosHdl; // handle text block + SwDrawBase *m_pDrawActual; - const SwFrmFmt *pLastTableFormat; + const SwFrmFmt *m_pLastTableFormat; - SwFormatClipboard *pFormatClipboard; //holds data for format paintbrush + SwFormatClipboard *m_pFormatClipboard; //holds data for format paintbrush - SwPostItMgr *mpPostItMgr; + SwPostItMgr *m_pPostItMgr; - int nSelectionType; - FloatingWindow *mpFieldPopup; + int m_nSelectionType; + FloatingWindow *m_pFieldPopup; - static const int MASTERENUMCOMMANDS = 6; + static const int m_nMASTERENUMCOMMANDS = 6; - String aCurrShapeEnumCommand[ MASTERENUMCOMMANDS ]; + String m_aCurrShapeEnumCommand[ m_nMASTERENUMCOMMANDS ]; - sal_uInt16 nPageCnt; + sal_uInt16 m_nPageCnt; // current draw mode - sal_uInt16 nDrawSfxId; - String sDrawCustom; //some drawing types are marked with strings! - sal_uInt16 nFormSfxId; - sal_uInt16 nLastPasteDestination; + sal_uInt16 m_nDrawSfxId; + String m_sDrawCustom; //some drawing types are marked with strings! + sal_uInt16 m_nFormSfxId; + sal_uInt16 m_nLastPasteDestination; // save the border distance status from SwView::StateTabWin to re-use it in SwView::ExecTabWin() - sal_uInt16 nLeftBorderDistance; - sal_uInt16 nRightBorderDistance; - - bool mbWheelScrollInProgress; - - sal_Bool bCenterCrsr : 1, - bTopCrsr : 1, - bAlwaysShowSel : 1, - bTabColFromDoc : 1, - bNumIndentFromDoc : 1, // #i23726# - bTabRowFromDoc : 1, - bSetTabColFromDoc : 1 , - bSetTabRowFromDoc : 1, - bAttrChgNotified : 1, - bAttrChgNotifiedWithRegistrations : 1, - bVerbsActive : 1, - bDrawRotate : 1, - bDrawSelMode : 1, - bShowAtResize : 1, - bInOuterResizePixel : 1, - bInInnerResizePixel : 1, - bPasteState : 1, - bPasteSpecialState : 1, - bInMailMerge : 1, - bInDtor : 1, //detect destructor to prevent creating of sub shells while closing - bOldShellWasPagePreView : 1, - bIsPreviewDoubleClick : 1, // #i114045# - bMakeSelectionVisible : 1, // transport the bookmark selection + sal_uInt16 m_nLeftBorderDistance; + sal_uInt16 m_nRightBorderDistance; + + bool m_bWheelScrollInProgress; + + sal_Bool m_bCenterCrsr : 1, + m_bTopCrsr : 1, + m_bAlwaysShowSel : 1, + m_bTabColFromDoc : 1, + m_bNumIndentFromDoc : 1, // #i23726# + m_bTabRowFromDoc : 1, + m_bSetTabColFromDoc : 1 , + m_bSetTabRowFromDoc : 1, + m_bAttrChgNotified : 1, + m_bAttrChgNotifiedWithRegistrations : 1, + m_bVerbsActive : 1, + m_bDrawRotate : 1, + m_bDrawSelMode : 1, + m_bShowAtResize : 1, + m_bInOuterResizePixel : 1, + m_bInInnerResizePixel : 1, + m_bPasteState : 1, + m_bPasteSpecialState : 1, + m_bInMailMerge : 1, + m_bInDtor : 1, //detect destructor to prevent creating of sub shells while closing + m_bOldShellWasPagePreView : 1, + m_bIsPreviewDoubleClick : 1, // #i114045# + m_bMakeSelectionVisible : 1, // transport the bookmark selection m_bAnnotationMode; ///< The real cursor position is inside an annotation. // methods for searching @@ -334,7 +334,7 @@ class SW_DLLPUBLIC SwView: public SfxViewShell SW_DLLPRIVATE void HyphStart( SvxSpellArea eSpell ); SW_DLLPRIVATE sal_Bool CheckSpecialCntnt(); SW_DLLPRIVATE void SpellKontext(sal_Bool bOn = sal_True) - { bCenterCrsr = bOn; bAlwaysShowSel = bOn; } + { m_bCenterCrsr = bOn; m_bAlwaysShowSel = bOn; } // methods for printing SW_DLLPRIVATE virtual SfxPrinter* GetPrinter( sal_Bool bCreate = sal_False ); @@ -365,16 +365,16 @@ class SW_DLLPUBLIC SwView: public SfxViewShell protected: - SwView_Impl* GetViewImpl() {return pViewImpl;} + SwView_Impl* GetViewImpl() {return m_pViewImpl;} void ImpSetVerb( int nSelType ); - int GetSelectionType() const { return nSelectionType; } - void SetSelectionType(int nSet) { nSelectionType = nSet;} + int GetSelectionType() const { return m_nSelectionType; } + void SetSelectionType(int nSet) { m_nSelectionType = nSet;} // for SwWebView - void SetShell( SfxShell* pS ) { pShell = pS; } - void SetFormShell( FmFormShell* pSh ) { pFormShell = pSh; } + void SetShell( SfxShell* pS ) { m_pShell = pS; } + void SetFormShell( FmFormShell* pSh ) { m_pFormShell = pSh; } virtual void SelectShell(); @@ -385,8 +385,8 @@ protected: void SetImageButtonColor(Color& rColor); - const SwFrmFmt* GetLastTblFrmFmt() const {return pLastTableFormat;} - void SetLastTblFrmFmt(const SwFrmFmt* pSet) {pLastTableFormat = pSet;} + const SwFrmFmt* GetLastTblFrmFmt() const {return m_pLastTableFormat;} + void SetLastTblFrmFmt(const SwFrmFmt* pSet) {m_pLastTableFormat = pSet;} // form letter execution void GenerateFormLetter(sal_Bool bUseCurrentDocument); @@ -429,11 +429,11 @@ public: // immediately switch shell -> for GetSelectionObject void StopShellTimer(); - inline SwWrtShell& GetWrtShell () const { return *pWrtShell; } - inline SwWrtShell* GetWrtShellPtr() const { return pWrtShell; } + inline SwWrtShell& GetWrtShell () const { return *m_pWrtShell; } + inline SwWrtShell* GetWrtShellPtr() const { return m_pWrtShell; } - inline SwEditWin &GetEditWin() { return *pEditWin; } - inline const SwEditWin &GetEditWin () const { return *pEditWin; } + inline SwEditWin &GetEditWin() { return *m_pEditWin; } + inline const SwEditWin &GetEditWin () const { return *m_pEditWin; } #if defined WNT || defined UNX void ScannerEventHdl( const ::com::sun::star::lang::EventObject& rEventObject ); @@ -442,7 +442,7 @@ public: // hand the handler for text blocks to the shell; create if applicable SwGlossaryHdl* GetGlosHdl(); - inline const Rectangle& GetVisArea() const { return aVisArea; } + inline const Rectangle& GetVisArea() const { return m_aVisArea; } sal_Bool IsScroll(const Rectangle& rRect) const; void Scroll( const Rectangle& rRect, @@ -462,21 +462,21 @@ public: DECL_LINK( OnlineSpellCallback, SpellCallbackInfo*); sal_Bool ExecDrwTxtSpellPopup(const Point& rPt); - void SetTabColFromDocPos( const Point &rPt ) { aTabColFromDocPos = rPt; } - void SetTabColFromDoc( sal_Bool b ) { bTabColFromDoc = b; } - sal_Bool IsTabColFromDoc() const { return bTabColFromDoc; } - void SetTabRowFromDoc( sal_Bool b ) { bTabRowFromDoc = b; } - sal_Bool IsTabRowFromDoc() const { return bTabRowFromDoc; } + void SetTabColFromDocPos( const Point &rPt ) { m_aTabColFromDocPos = rPt; } + void SetTabColFromDoc( sal_Bool b ) { m_bTabColFromDoc = b; } + sal_Bool IsTabColFromDoc() const { return m_bTabColFromDoc; } + void SetTabRowFromDoc( sal_Bool b ) { m_bTabRowFromDoc = b; } + sal_Bool IsTabRowFromDoc() const { return m_bTabRowFromDoc; } // -> #i23726# void SetNumRuleNodeFromDoc( SwTxtNode * pNumRuleNode ) - { pNumRuleNodeFromDoc = pNumRuleNode; } - void SetNumIndentFromDoc(sal_Bool b) { bNumIndentFromDoc = b; } - sal_Bool IsNumIndentFromDoc() const { return NULL != pNumRuleNodeFromDoc; } + { m_pNumRuleNodeFromDoc = pNumRuleNode; } + void SetNumIndentFromDoc(sal_Bool b) { m_bNumIndentFromDoc = b; } + sal_Bool IsNumIndentFromDoc() const { return NULL != m_pNumRuleNodeFromDoc; } // <- #i23726# void DocSzChgd( const Size& rNewSize ); - const Size& GetDocSz() const { return aDocSz; } + const Size& GetDocSz() const { return m_aDocSz; } virtual void SetVisArea( const Rectangle&, sal_Bool bUpdateScrollbar = sal_True); void SetVisArea( const Point&, sal_Bool bUpdateScrollbar = sal_True); void CheckVisArea(); @@ -513,13 +513,13 @@ public: int CreateTab(); int KillTab(); - int StatVLineal() const { return ((Window*)pVRuler)->IsVisible(); } + int StatVLineal() const { return ((Window*)m_pVRuler)->IsVisible(); } void ChangeVLinealMetric(FieldUnit eUnit); void GetVLinealMetric(FieldUnit& rToFill) const; - int StatTab() const { return ((Window*)pHRuler)->IsVisible(); } - SvxRuler& GetHLineal() { return *pHRuler; } - SvxRuler& GetVLineal() { return *pVRuler; } + int StatTab() const { return ((Window*)m_pHRuler)->IsVisible(); } + SvxRuler& GetHLineal() { return *m_pHRuler; } + SvxRuler& GetVLineal() { return *m_pVRuler; } void InvalidateRulerPos(); void ChangeTabMetric(FieldUnit eUnit); void GetHLinealMetric(FieldUnit& rToFill) const; @@ -550,18 +550,18 @@ public: // functions for drawing void SetDrawFuncPtr(SwDrawBase* pFuncPtr); - inline SwDrawBase* GetDrawFuncPtr(/*sal_Bool bBuf = sal_False*/) const { return pDrawActual; } + inline SwDrawBase* GetDrawFuncPtr(/*sal_Bool bBuf = sal_False*/) const { return m_pDrawActual; } void GetDrawState(SfxItemSet &rSet); void ExitDraw(); - inline sal_Bool IsDrawRotate() { return bDrawRotate; } - inline void FlipDrawRotate() { bDrawRotate = !bDrawRotate; } - inline sal_Bool IsDrawSelMode() { return bDrawSelMode; } + inline sal_Bool IsDrawRotate() { return m_bDrawRotate; } + inline void FlipDrawRotate() { m_bDrawRotate = !m_bDrawRotate; } + inline sal_Bool IsDrawSelMode() { return m_bDrawSelMode; } void SetSelDrawSlot(); - inline void FlipDrawSelMode() { bDrawSelMode = !bDrawSelMode; } + inline void FlipDrawSelMode() { m_bDrawSelMode = !m_bDrawSelMode; } void NoRotate(); // turn off rotate mode sal_Bool EnterDrawTextMode(const Point& aDocPos); - void LeaveDrawCreate() { nDrawSfxId = nFormSfxId = USHRT_MAX; sDrawCustom.Erase();} - sal_Bool IsDrawMode() { return (nDrawSfxId != USHRT_MAX || nFormSfxId != USHRT_MAX); } + void LeaveDrawCreate() { m_nDrawSfxId = m_nFormSfxId = USHRT_MAX; m_sDrawCustom.Erase();} + sal_Bool IsDrawMode() { return (m_nDrawSfxId != USHRT_MAX || m_nFormSfxId != USHRT_MAX); } bool IsFormMode() const; sal_Bool IsBezierEditMode(); bool AreOnlyFormsSelected() const; @@ -589,14 +589,14 @@ public: String GetPageStr(sal_uInt16 nPhyNum, sal_uInt16 nVirtNum, const String& rPgStr); // hand over Shell - SfxShell *GetCurShell() { return pShell; } + SfxShell *GetCurShell() { return m_pShell; } SwDocShell *GetDocShell(); inline const SwDocShell *GetDocShell() const; - inline FmFormShell *GetFormShell() { return pFormShell; } - inline const FmFormShell *GetFormShell() const { return pFormShell; } + inline FmFormShell *GetFormShell() { return m_pFormShell; } + inline const FmFormShell *GetFormShell() const { return m_pFormShell; } - // so that in the SubShells' DTors pShell can be reset if applicable - void ResetSubShell() { pShell = 0; } + // so that in the SubShells' DTors m_pShell can be reset if applicable + void ResetSubShell() { m_pShell = 0; } virtual void WriteUserData(String &, sal_Bool bBrowse = sal_False ); virtual void ReadUserData(const String &, sal_Bool bBrowse = sal_False ); @@ -604,9 +604,9 @@ public: virtual void WriteUserDataSequence ( com::sun::star::uno::Sequence < com::sun::star::beans::PropertyValue >&, sal_Bool bBrowse ); void SetCrsrAtTop( sal_Bool bFlag, sal_Bool bCenter = sal_False ) - { bTopCrsr = bFlag, bCenterCrsr = bCenter; } - sal_Bool IsCrsrAtTop() const { return bTopCrsr; } - sal_Bool IsCrsrAtCenter() const { return bCenterCrsr; } + { m_bTopCrsr = bFlag, m_bCenterCrsr = bCenter; } + sal_Bool IsCrsrAtTop() const { return m_bTopCrsr; } + sal_Bool IsCrsrAtCenter() const { return m_bCenterCrsr; } bool JumpToSwMark( const String& rMark ); @@ -654,8 +654,8 @@ public: void ExecuteScan( SfxRequest& rReq ); - SwPostItMgr* GetPostItMgr() { return mpPostItMgr;} - const SwPostItMgr* GetPostItMgr() const { return mpPostItMgr;} + SwPostItMgr* GetPostItMgr() { return m_pPostItMgr;} + const SwPostItMgr* GetPostItMgr() const { return m_pPostItMgr;} // exhibition hack (MA,MBA) void SelectShellForDrop(); @@ -668,12 +668,12 @@ public: // ----------------- inline Methoden ---------------------- inline long SwView::GetXScroll() const { - return aVisArea.GetWidth() * nScrollX / 100L; + return m_aVisArea.GetWidth() * nScrollX / 100L; } inline long SwView::GetYScroll() const { - return aVisArea.GetHeight() * nScrollY / 100L; + return m_aVisArea.GetHeight() * nScrollY / 100L; } inline const SwDocShell *SwView::GetDocShell() const diff --git a/sw/source/ui/uiview/uivwimp.cxx b/sw/source/ui/uiview/uivwimp.cxx index cfc208cc3221..4332fcbbfd10 100644 --- a/sw/source/ui/uiview/uivwimp.cxx +++ b/sw/source/ui/uiview/uivwimp.cxx @@ -283,11 +283,11 @@ void SAL_CALL SwClipboardChangeListener::changedContents( const ::com::sun::star TransferableDataHelper aDataHelper( rEventObject.Contents ); SwWrtShell& rSh = pView->GetWrtShell(); - pView->nLastPasteDestination = SwTransferable::GetSotDestination( rSh ); - pView->bPasteState = aDataHelper.GetXTransferable().is() && + pView->m_nLastPasteDestination = SwTransferable::GetSotDestination( rSh ); + pView->m_bPasteState = aDataHelper.GetXTransferable().is() && SwTransferable::IsPaste( rSh, aDataHelper ); - pView->bPasteSpecialState = aDataHelper.GetXTransferable().is() && + pView->m_bPasteSpecialState = aDataHelper.GetXTransferable().is() && SwTransferable::IsPasteSpecial( rSh, aDataHelper ); } diff --git a/sw/source/ui/uiview/view.cxx b/sw/source/ui/uiview/view.cxx index 89faacbc6f75..d02089e9677f 100644 --- a/sw/source/ui/uiview/view.cxx +++ b/sw/source/ui/uiview/view.cxx @@ -125,19 +125,19 @@ extern bool bNoInterrupt; // in mainwn.cxx int bDocSzUpdated = 1; -SvxSearchItem* SwView::pSrchItem = 0; +SvxSearchItem* SwView::m_pSrchItem = 0; -sal_uInt16 SwView::nInsertCtrlState = FN_INSERT_TABLE; -sal_uInt16 SwView::nWebInsertCtrlState = FN_INSERT_TABLE; -sal_uInt16 SwView::nInsertObjectCtrlState = SID_INSERT_DIAGRAM; +sal_uInt16 SwView::m_nInsertCtrlState = FN_INSERT_TABLE; +sal_uInt16 SwView::m_nWebInsertCtrlState = FN_INSERT_TABLE; +sal_uInt16 SwView::m_nInsertObjectCtrlState = SID_INSERT_DIAGRAM; -bool SwView::bExtra = false; -sal_Bool SwView::bFound = sal_False; -bool SwView::bJustOpened = false; +bool SwView::m_bExtra = false; +sal_Bool SwView::m_bFound = sal_False; +bool SwView::m_bJustOpened = false; -SvxSearchDialog* SwView::pSrchDlg = 0; -SearchAttrItemList* SwView::pSrchList = 0; -SearchAttrItemList* SwView::pReplList = 0; +SvxSearchDialog* SwView::m_pSrchDlg = 0; +SearchAttrItemList* SwView::m_pSrchList = 0; +SearchAttrItemList* SwView::m_pReplList = 0; DBG_NAME(viewhdl) @@ -148,16 +148,16 @@ inline SfxDispatcher &SwView::GetDispatcher() void SwView::ImpSetVerb( int nSelType ) { - sal_Bool bResetVerbs = bVerbsActive; + sal_Bool bResetVerbs = m_bVerbsActive; if ( !GetViewFrame()->GetFrame().IsInPlace() && (nsSelectionType::SEL_OLE|nsSelectionType::SEL_GRF) & nSelType ) { - if ( !pWrtShell->IsSelObjProtected(FLYPROTECT_CONTENT) ) + if ( !m_pWrtShell->IsSelObjProtected(FLYPROTECT_CONTENT) ) { if ( nSelType & nsSelectionType::SEL_OLE ) { SetVerbs( GetWrtShell().GetOLEObject()->getSupportedVerbs() ); - bVerbsActive = sal_True; + m_bVerbsActive = sal_True; bResetVerbs = sal_False; } } @@ -165,7 +165,7 @@ void SwView::ImpSetVerb( int nSelType ) if ( bResetVerbs ) { SetVerbs( Sequence< embed::VerbDescriptor >() ); - bVerbsActive = sal_False; + m_bVerbsActive = sal_False; } } @@ -184,15 +184,15 @@ void SwView::GotFocus() const if ( pAsFormShell ) { pAsFormShell->ForgetActiveControl(); - const_cast< SwView* >( this )->AttrChangedNotify( pWrtShell ); + const_cast< SwView* >( this )->AttrChangedNotify( m_pWrtShell ); } - else if ( mpPostItMgr ) + else if ( m_pPostItMgr ) { SwAnnotationShell* pAsAnnotationShell = PTR_CAST( SwAnnotationShell, pTopShell ); if ( pAsAnnotationShell ) { - mpPostItMgr->SetActiveSidebarWin(0); - const_cast< SwView* >( this )->AttrChangedNotify( pWrtShell ); + m_pPostItMgr->SetActiveSidebarWin(0); + const_cast< SwView* >( this )->AttrChangedNotify( m_pWrtShell ); } } if( GetWrtShellPtr() ) @@ -220,11 +220,11 @@ IMPL_LINK_NOARG(SwView, FormControlActivated) if ( !pAsFormShell ) { // if we're editing text currently, cancel this - SdrView *pSdrView = pWrtShell ? pWrtShell->GetDrawView() : NULL; + SdrView *pSdrView = m_pWrtShell ? m_pWrtShell->GetDrawView() : NULL; if ( pSdrView && pSdrView->IsTextEdit() ) pSdrView->SdrEndTextEdit( sal_True ); - const_cast< SwView* >( this )->AttrChangedNotify( pWrtShell ); + const_cast< SwView* >( this )->AttrChangedNotify( m_pWrtShell ); } return 0L; @@ -238,29 +238,29 @@ void SwView::SelectShell() // //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - if(bInDtor) + if(m_bInDtor) return; // Entscheidung, ob UpdateTable gerufen werden muss sal_Bool bUpdateTable = sal_False; - const SwFrmFmt* pCurTableFmt = pWrtShell->GetTableFmt(); - if(pCurTableFmt && pCurTableFmt != pLastTableFormat) + const SwFrmFmt* pCurTableFmt = m_pWrtShell->GetTableFmt(); + if(pCurTableFmt && pCurTableFmt != m_pLastTableFormat) { bUpdateTable = sal_True; // kann erst spaeter ausgefuehrt werden } - pLastTableFormat = pCurTableFmt; + m_pLastTableFormat = pCurTableFmt; //SEL_TBL and SEL_TBL_CELLS can be changed! - int nNewSelectionType = (pWrtShell->GetSelectionType() + int nNewSelectionType = (m_pWrtShell->GetSelectionType() & ~nsSelectionType::SEL_TBL_CELLS); - if ( pFormShell && pFormShell->IsActiveControl() ) + if ( m_pFormShell && m_pFormShell->IsActiveControl() ) nNewSelectionType |= nsSelectionType::SEL_FOC_FRM_CTRL; - if ( nNewSelectionType == nSelectionType ) + if ( nNewSelectionType == m_nSelectionType ) { GetViewFrame()->GetBindings().InvalidateAll( sal_False ); - if ( nSelectionType & nsSelectionType::SEL_OLE || - nSelectionType & nsSelectionType::SEL_GRF ) + if ( m_nSelectionType & nsSelectionType::SEL_OLE || + m_nSelectionType & nsSelectionType::SEL_GRF ) //Fuer Grafiken und OLE kann sich natuerlich das Verb aendern! ImpSetVerb( nNewSelectionType ); } @@ -270,14 +270,14 @@ void SwView::SelectShell() SfxDispatcher &rDispatcher = GetDispatcher(); SwToolbarConfigItem *pBarCfg = SW_MOD()->GetToolbarConfig(); - if ( pShell ) + if ( m_pShell ) { rDispatcher.Flush(); // alle gecachten Shells wirklich loeschen //Zur alten Selektion merken welche Toolbar sichtbar war sal_uInt16 nId = static_cast< sal_uInt16 >( rDispatcher.GetObjectBarId( SFX_OBJECTBAR_OBJECT )); if ( nId ) - pBarCfg->SetTopToolbar( nSelectionType, nId ); + pBarCfg->SetTopToolbar( m_nSelectionType, nId ); SfxShell *pSfxShell; for ( sal_uInt16 i = 0; sal_True; ++i ) @@ -302,127 +302,127 @@ void SwView::SelectShell() } sal_Bool bInitFormShell = sal_False; - if (!pFormShell) + if (!m_pFormShell) { bInitFormShell = sal_True; - pFormShell = new FmFormShell( this ); - pFormShell->SetControlActivationHandler( LINK( this, SwView, FormControlActivated ) ); - StartListening(*pFormShell); + m_pFormShell = new FmFormShell( this ); + m_pFormShell->SetControlActivationHandler( LINK( this, SwView, FormControlActivated ) ); + StartListening(*m_pFormShell); } sal_Bool bSetExtInpCntxt = sal_False; - nSelectionType = nNewSelectionType; + m_nSelectionType = nNewSelectionType; ShellModes eShellMode; - if ( !( nSelectionType & nsSelectionType::SEL_FOC_FRM_CTRL ) ) - rDispatcher.Push( *pFormShell ); + if ( !( m_nSelectionType & nsSelectionType::SEL_FOC_FRM_CTRL ) ) + rDispatcher.Push( *m_pFormShell ); eShellMode = SHELL_MODE_NAVIGATION; - pShell = new SwNavigationShell( *this ); - rDispatcher.Push( *pShell ); + m_pShell = new SwNavigationShell( *this ); + rDispatcher.Push( *m_pShell ); - if ( nSelectionType & nsSelectionType::SEL_OLE ) + if ( m_nSelectionType & nsSelectionType::SEL_OLE ) { eShellMode = SHELL_MODE_OBJECT; - pShell = new SwOleShell( *this ); - rDispatcher.Push( *pShell ); + m_pShell = new SwOleShell( *this ); + rDispatcher.Push( *m_pShell ); } - else if ( nSelectionType & nsSelectionType::SEL_FRM - || nSelectionType & nsSelectionType::SEL_GRF) + else if ( m_nSelectionType & nsSelectionType::SEL_FRM + || m_nSelectionType & nsSelectionType::SEL_GRF) { eShellMode = SHELL_MODE_FRAME; - pShell = new SwFrameShell( *this ); - rDispatcher.Push( *pShell ); - if(nSelectionType & nsSelectionType::SEL_GRF ) + m_pShell = new SwFrameShell( *this ); + rDispatcher.Push( *m_pShell ); + if(m_nSelectionType & nsSelectionType::SEL_GRF ) { eShellMode = SHELL_MODE_GRAPHIC; - pShell = new SwGrfShell( *this ); - rDispatcher.Push( *pShell ); + m_pShell = new SwGrfShell( *this ); + rDispatcher.Push( *m_pShell ); } } - else if ( nSelectionType & nsSelectionType::SEL_DRW ) + else if ( m_nSelectionType & nsSelectionType::SEL_DRW ) { eShellMode = SHELL_MODE_DRAW; - pShell = new SwDrawShell( *this ); - rDispatcher.Push( *pShell ); + m_pShell = new SwDrawShell( *this ); + rDispatcher.Push( *m_pShell ); - if ( nSelectionType & nsSelectionType::SEL_BEZ ) + if ( m_nSelectionType & nsSelectionType::SEL_BEZ ) { eShellMode = SHELL_MODE_BEZIER; - pShell = new SwBezierShell( *this ); - rDispatcher.Push( *pShell ); + m_pShell = new SwBezierShell( *this ); + rDispatcher.Push( *m_pShell ); } - else if( nSelectionType & nsSelectionType::SEL_MEDIA ) + else if( m_nSelectionType & nsSelectionType::SEL_MEDIA ) { eShellMode = SHELL_MODE_MEDIA; - pShell = new SwMediaShell( *this ); - rDispatcher.Push( *pShell ); + m_pShell = new SwMediaShell( *this ); + rDispatcher.Push( *m_pShell ); } - if (nSelectionType & nsSelectionType::SEL_EXTRUDED_CUSTOMSHAPE) + if (m_nSelectionType & nsSelectionType::SEL_EXTRUDED_CUSTOMSHAPE) { eShellMode = SHELL_MODE_EXTRUDED_CUSTOMSHAPE; - pShell = new svx::ExtrusionBar(this); - rDispatcher.Push( *pShell ); + m_pShell = new svx::ExtrusionBar(this); + rDispatcher.Push( *m_pShell ); } - if (nSelectionType & nsSelectionType::SEL_FONTWORK) + if (m_nSelectionType & nsSelectionType::SEL_FONTWORK) { eShellMode = SHELL_MODE_FONTWORK; - pShell = new svx::FontworkBar(this); - rDispatcher.Push( *pShell ); + m_pShell = new svx::FontworkBar(this); + rDispatcher.Push( *m_pShell ); } } - else if ( nSelectionType & nsSelectionType::SEL_DRW_FORM ) + else if ( m_nSelectionType & nsSelectionType::SEL_DRW_FORM ) { eShellMode = SHELL_MODE_DRAW_FORM; - pShell = new SwDrawFormShell( *this ); + m_pShell = new SwDrawFormShell( *this ); - rDispatcher.Push( *pShell ); + rDispatcher.Push( *m_pShell ); } - else if ( nSelectionType & nsSelectionType::SEL_DRW_TXT ) + else if ( m_nSelectionType & nsSelectionType::SEL_DRW_TXT ) { bSetExtInpCntxt = sal_True; eShellMode = SHELL_MODE_DRAWTEXT; rDispatcher.Push( *(new SwBaseShell( *this )) ); - pShell = new SwDrawTextShell( *this ); - rDispatcher.Push( *pShell ); + m_pShell = new SwDrawTextShell( *this ); + rDispatcher.Push( *m_pShell ); } - else if ( nSelectionType & nsSelectionType::SEL_POSTIT ) + else if ( m_nSelectionType & nsSelectionType::SEL_POSTIT ) { eShellMode = SHELL_MODE_POSTIT; - pShell = new SwAnnotationShell( *this ); - rDispatcher.Push( *pShell ); + m_pShell = new SwAnnotationShell( *this ); + rDispatcher.Push( *m_pShell ); } else { bSetExtInpCntxt = sal_True; eShellMode = SHELL_MODE_TEXT; sal_uInt32 nHelpId = 0; - if ( nSelectionType & nsSelectionType::SEL_NUM ) + if ( m_nSelectionType & nsSelectionType::SEL_NUM ) { eShellMode = SHELL_MODE_LIST_TEXT; - pShell = new SwListShell( *this ); - nHelpId = pShell->GetHelpId(); - rDispatcher.Push( *pShell ); + m_pShell = new SwListShell( *this ); + nHelpId = m_pShell->GetHelpId(); + rDispatcher.Push( *m_pShell ); } - pShell = new SwTextShell(*this); + m_pShell = new SwTextShell(*this); if(nHelpId) - pShell->SetHelpId(nHelpId); - rDispatcher.Push( *pShell ); - if ( nSelectionType & nsSelectionType::SEL_TBL ) + m_pShell->SetHelpId(nHelpId); + rDispatcher.Push( *m_pShell ); + if ( m_nSelectionType & nsSelectionType::SEL_TBL ) { eShellMode = eShellMode == SHELL_MODE_LIST_TEXT ? SHELL_MODE_TABLE_LIST_TEXT : SHELL_MODE_TABLE_TEXT; - pShell = new SwTableShell( *this ); - rDispatcher.Push( *pShell ); + m_pShell = new SwTableShell( *this ); + rDispatcher.Push( *m_pShell ); } } - if ( nSelectionType & nsSelectionType::SEL_FOC_FRM_CTRL ) - rDispatcher.Push( *pFormShell ); + if ( m_nSelectionType & nsSelectionType::SEL_FOC_FRM_CTRL ) + rDispatcher.Push( *m_pFormShell ); - pViewImpl->SetShellMode(eShellMode); - ImpSetVerb( nSelectionType ); + m_pViewImpl->SetShellMode(eShellMode); + ImpSetVerb( m_nSelectionType ); if( !GetDocShell()->IsReadOnly() ) { @@ -453,7 +453,7 @@ void SwView::SelectShell() SdrView* pDView = GetWrtShell().GetDrawView(); if ( bInitFormShell && pDView ) - pFormShell->SetView(PTR_CAST(FmFormView, pDView)); + m_pFormShell->SetView(PTR_CAST(FmFormView, pDView)); } //Guenstiger Zeitpunkt fuer die Kommunikation mit OLE-Objekten? @@ -462,7 +462,7 @@ void SwView::SelectShell() // now the table-update if(bUpdateTable) - pWrtShell->UpdateTable(); + m_pWrtShell->UpdateTable(); GetViewImpl()->GetUNOObject_Impl()->NotifySelChanged(); } @@ -488,21 +488,21 @@ IMPL_LINK_NOARG(SwView, AttrChangedNotify) //Opt: Nicht wenn PaintLocked. Beim Unlock wird dafuer nocheinmal ein //Notify ausgeloest. - if( !pWrtShell->IsPaintLocked() && !bNoInterrupt && + if( !m_pWrtShell->IsPaintLocked() && !bNoInterrupt && GetDocShell()->IsReadOnly() ) _CheckReadonlyState(); - if( !pWrtShell->IsPaintLocked() && !bNoInterrupt ) + if( !m_pWrtShell->IsPaintLocked() && !bNoInterrupt ) _CheckReadonlySelection(); - if( !bAttrChgNotified ) + if( !m_bAttrChgNotified ) { - if ( pWrtShell->BasicActionPend() || bNoInterrupt || + if ( m_pWrtShell->BasicActionPend() || bNoInterrupt || GetDispatcher().IsLocked() || //do not confuse the SFX GetViewFrame()->GetBindings().IsInUpdate() )//do not confuse the SFX { - bAttrChgNotified = sal_True; - aTimer.Start(); + m_bAttrChgNotified = sal_True; + m_aTimer.Start(); const SfxPoolItem *pItem; if ( SFX_ITEM_SET != GetObjectShell()->GetMedium()->GetItemSet()-> @@ -510,7 +510,7 @@ IMPL_LINK_NOARG(SwView, AttrChangedNotify) !((SfxBoolItem*)pItem)->GetValue() ) { GetViewFrame()->GetBindings().ENTERREGISTRATIONS(); - bAttrChgNotifiedWithRegistrations = sal_True; + m_bAttrChgNotifiedWithRegistrations = sal_True; } } @@ -520,11 +520,11 @@ IMPL_LINK_NOARG(SwView, AttrChangedNotify) } // change ui if cursor is at a SwPostItField - if (mpPostItMgr) + if (m_pPostItMgr) { // only perform the code that is needed to determine, if at the // actual cursor position is a post-it field - mpPostItMgr->SetShadowState( pWrtShell->GetPostItFieldAtCursor() ); + m_pPostItMgr->SetShadowState( m_pWrtShell->GetPostItFieldAtCursor() ); } return 0; @@ -534,27 +534,27 @@ IMPL_LINK_NOARG(SwView, TimeoutHdl) { DBG_PROFSTART(viewhdl); - if( pWrtShell->BasicActionPend() || bNoInterrupt ) + if( m_pWrtShell->BasicActionPend() || bNoInterrupt ) { - aTimer.Start(); + m_aTimer.Start(); DBG_PROFSTOP(viewhdl); return 0; } - if ( bAttrChgNotifiedWithRegistrations ) + if ( m_bAttrChgNotifiedWithRegistrations ) { GetViewFrame()->GetBindings().LEAVEREGISTRATIONS(); - bAttrChgNotifiedWithRegistrations = sal_False; + m_bAttrChgNotifiedWithRegistrations = sal_False; } _CheckReadonlyState(); _CheckReadonlySelection(); - sal_Bool bOldUndo = pWrtShell->DoesUndo(); - pWrtShell->DoUndo( sal_False ); + sal_Bool bOldUndo = m_pWrtShell->DoesUndo(); + m_pWrtShell->DoUndo( sal_False ); SelectShell(); - pWrtShell->DoUndo( bOldUndo ); - bAttrChgNotified = sal_False; + m_pWrtShell->DoUndo( bOldUndo ); + m_bAttrChgNotified = sal_False; GetViewImpl()->GetUNOObject_Impl()->NotifySelChanged(); DBG_PROFSTOP(viewhdl); @@ -573,7 +573,7 @@ void SwView::_CheckReadonlyState() eStateProtAll = rDis.QueryState( FN_EDIT_REGION, pItem ); sal_Bool bChgd = sal_False; - if ( !pWrtShell->IsCrsrReadonly() ) + if ( !m_pWrtShell->IsCrsrReadonly() ) { static sal_uInt16 aROIds[] = { @@ -622,7 +622,7 @@ void SwView::_CheckReadonlyState() bChgd = sal_True; } } - else if( pWrtShell->IsAllProtect() ) + else if( m_pWrtShell->IsAllProtect() ) { if ( SFX_ITEM_DISABLED == eStateProtAll ) { @@ -654,9 +654,9 @@ void SwView::_CheckReadonlySelection() sal_uInt32 nDisableFlags = 0; SfxDispatcher &rDis = GetDispatcher(); - if( pWrtShell->HasReadonlySel(m_bAnnotationMode) && - ( !pWrtShell->GetDrawView() || - !pWrtShell->GetDrawView()->GetMarkedObjectList().GetMarkCount() )) + if( m_pWrtShell->HasReadonlySel(m_bAnnotationMode) && + ( !m_pWrtShell->GetDrawView() || + !m_pWrtShell->GetDrawView()->GetMarkedObjectList().GetMarkCount() )) nDisableFlags |= SW_DISABLE_ON_PROTECTED_CURSOR; if( (SW_DISABLE_ON_PROTECTED_CURSOR & nDisableFlags ) != @@ -666,7 +666,7 @@ void SwView::_CheckReadonlySelection() // japanischen / chinesischen Versionen die externe Eingabe // ab-/angeschaltet wird. Das aber nur wenn auch die richtige // Shell auf dem Stack steht. - switch( pViewImpl->GetShellMode() ) + switch( m_pViewImpl->GetShellMode() ) { case SHELL_MODE_TEXT: case SHELL_MODE_LIST_TEXT: @@ -706,42 +706,42 @@ void SwView::_CheckReadonlySelection() SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) : SfxViewShell( _pFrame, SWVIEWFLAGS ), - aPageStr( SW_RES( STR_PAGE )), - nNewPage(USHRT_MAX), - pNumRuleNodeFromDoc(0), - pEditWin( new SwEditWin( &_pFrame->GetWindow(), *this ) ), - pWrtShell(0), - pShell(0), - pFormShell(0), - pHScrollbar(0), - pVScrollbar(0), - pScrollFill(new ScrollBarBox( &_pFrame->GetWindow(), _pFrame->GetFrame().GetParentFrame() ? 0 : WB_SIZEABLE )), - pVRuler(new SvxRuler(&GetViewFrame()->GetWindow(), pEditWin, + m_aPageStr( SW_RES( STR_PAGE )), + m_nNewPage(USHRT_MAX), + m_pNumRuleNodeFromDoc(0), + m_pEditWin( new SwEditWin( &_pFrame->GetWindow(), *this ) ), + m_pWrtShell(0), + m_pShell(0), + m_pFormShell(0), + m_pHScrollbar(0), + m_pVScrollbar(0), + m_pScrollFill(new ScrollBarBox( &_pFrame->GetWindow(), _pFrame->GetFrame().GetParentFrame() ? 0 : WB_SIZEABLE )), + m_pVRuler(new SvxRuler(&GetViewFrame()->GetWindow(), m_pEditWin, SVXRULER_SUPPORT_TABS | SVXRULER_SUPPORT_PARAGRAPH_MARGINS_VERTICAL| SVXRULER_SUPPORT_BORDERS | SVXRULER_SUPPORT_REDUCED_METRIC, GetViewFrame()->GetBindings(), WB_VSCROLL | WB_EXTRAFIELD | WB_BORDER )), - pTogglePageBtn(0), - pPageUpBtn(0), - pPageDownBtn(0), - pNaviBtn(0), - pGlosHdl(0), - pDrawActual(0), - pLastTableFormat(0), - pFormatClipboard(new SwFormatClipboard()), - mpPostItMgr(0), - nSelectionType( INT_MAX ), - nPageCnt(0), - nDrawSfxId( USHRT_MAX ), - nFormSfxId( USHRT_MAX ), - nLastPasteDestination( 0xFFFF ), - nLeftBorderDistance( 0 ), - nRightBorderDistance( 0 ), - mbWheelScrollInProgress(false), - bInMailMerge(sal_False), - bInDtor(sal_False), - bOldShellWasPagePreView(sal_False), - bIsPreviewDoubleClick(sal_False), + m_pTogglePageBtn(0), + m_pPageUpBtn(0), + m_pPageDownBtn(0), + m_pNaviBtn(0), + m_pGlosHdl(0), + m_pDrawActual(0), + m_pLastTableFormat(0), + m_pFormatClipboard(new SwFormatClipboard()), + m_pPostItMgr(0), + m_nSelectionType( INT_MAX ), + m_nPageCnt(0), + m_nDrawSfxId( USHRT_MAX ), + m_nFormSfxId( USHRT_MAX ), + m_nLastPasteDestination( 0xFFFF ), + m_nLeftBorderDistance( 0 ), + m_nRightBorderDistance( 0 ), + m_bWheelScrollInProgress(false), + m_bInMailMerge(sal_False), + m_bInDtor(sal_False), + m_bOldShellWasPagePreView(sal_False), + m_bIsPreviewDoubleClick(sal_False), m_bAnnotationMode(false) { // According to discussion with MBA and further @@ -753,21 +753,21 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) RTL_LOGFILE_CONTEXT_AUTHOR( aLog, "SW", "JP93722", "SwView::SwView" ); - bCenterCrsr = bTopCrsr = bAlwaysShowSel = bTabColFromDoc = bTabRowFromDoc = - bSetTabColFromDoc = bSetTabRowFromDoc = bAttrChgNotified = bAttrChgNotifiedWithRegistrations = - bVerbsActive = bDrawRotate = bInOuterResizePixel = bInInnerResizePixel = - bPasteState = bPasteSpecialState = bMakeSelectionVisible = sal_False; + m_bCenterCrsr = m_bTopCrsr = m_bAlwaysShowSel = m_bTabColFromDoc = m_bTabRowFromDoc = + m_bSetTabColFromDoc = m_bSetTabRowFromDoc = m_bAttrChgNotified = m_bAttrChgNotifiedWithRegistrations = + m_bVerbsActive = m_bDrawRotate = m_bInOuterResizePixel = m_bInInnerResizePixel = + m_bPasteState = m_bPasteSpecialState = m_bMakeSelectionVisible = sal_False; - bShowAtResize = bDrawSelMode = bDocSzUpdated = sal_True; + m_bShowAtResize = m_bDrawSelMode = bDocSzUpdated = sal_True; _CreateScrollbar( sal_True ); _CreateScrollbar( sal_False ); - pViewImpl = new SwView_Impl(this); + m_pViewImpl = new SwView_Impl(this); SetName(rtl::OUString("View")); - SetWindow( pEditWin ); + SetWindow( m_pEditWin ); - aTimer.SetTimeout( 120 ); + m_aTimer.SetTimeout( 120 ); SwDocShell* pDocSh = PTR_CAST( SwDocShell, _pFrame->GetObjectShell() ); sal_Bool bOldModifyFlag = pDocSh->IsEnableSetModified(); @@ -801,11 +801,11 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) // determine type of existing view if( pExistingSh->IsA( TYPE( SwPagePreView ) ) ) { - sSwViewData = ((SwPagePreView*)pExistingSh)->GetPrevSwViewData(); - sNewCrsrPos = ((SwPagePreView*)pExistingSh)->GetNewCrsrPos(); - nNewPage = ((SwPagePreView*)pExistingSh)->GetNewPage(); - bOldShellWasPagePreView = sal_True; - bIsPreviewDoubleClick = sNewCrsrPos.Len() > 0 || nNewPage != USHRT_MAX; + m_sSwViewData = ((SwPagePreView*)pExistingSh)->GetPrevSwViewData(); + m_sNewCrsrPos = ((SwPagePreView*)pExistingSh)->GetNewCrsrPos(); + m_nNewPage = ((SwPagePreView*)pExistingSh)->GetNewPage(); + m_bOldShellWasPagePreView = sal_True; + m_bIsPreviewDoubleClick = m_sNewCrsrPos.Len() > 0 || m_nNewPage != USHRT_MAX; } else if( pExistingSh->IsA( TYPE( SwSrcView ) ) ) bOldShellWasSrcView = sal_True; @@ -814,19 +814,19 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) RTL_LOGFILE_CONTEXT_TRACE( aLog, "before create WrtShell" ); if(PTR_CAST( SwView, pExistingSh)) { - pWrtShell = new SwWrtShell( *((SwView*)pExistingSh)->pWrtShell, - pEditWin, *this); + m_pWrtShell = new SwWrtShell( *((SwView*)pExistingSh)->m_pWrtShell, + m_pEditWin, *this); } else if( dynamic_cast<SwWrtShell*>( pDocSh->GetDoc()->GetCurrentViewShell() ) ) { - pWrtShell = new SwWrtShell( *(SwWrtShell*)pDocSh->GetDoc()->GetCurrentViewShell(), - pEditWin, *this); + m_pWrtShell = new SwWrtShell( *(SwWrtShell*)pDocSh->GetDoc()->GetCurrentViewShell(), + m_pEditWin, *this); } else { SwDoc& rDoc = *((SwDocShell*)pDocSh)->GetDoc(); - if( !bOldShellWasSrcView && pWebDShell && !bOldShellWasPagePreView ) + if( !bOldShellWasSrcView && pWebDShell && !m_bOldShellWasPagePreView ) aUsrPref.setBrowseMode( sal_True ); else aUsrPref.setBrowseMode( rDoc.get(IDocumentSettingAccess::BROWSE_MODE) ); @@ -843,13 +843,13 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) aUsrPref.SetViewLayoutBookMode( false ); aUsrPref.SetViewLayoutColumns( 1 ); } - pWrtShell = new SwWrtShell( rDoc, pEditWin, *this, &aUsrPref ); + m_pWrtShell = new SwWrtShell( rDoc, m_pEditWin, *this, &aUsrPref ); // creating an SwView from a SwPagePreView needs to // add the ViewShell to the ring of the other ViewShell(s) - if(bOldShellWasPagePreView) + if(m_bOldShellWasPagePreView) { ViewShell& rPreviewViewShell = *((SwPagePreView*)pExistingSh)->GetViewShell(); - pWrtShell->MoveTo(&rPreviewViewShell); + m_pWrtShell->MoveTo(&rPreviewViewShell); // to update the field command et.al. if necessary const SwViewOption* pPreViewOpt = rPreviewViewShell.GetViewOptions(); if( pPreViewOpt->IsFldName() != aUsrPref.IsFldName() || @@ -860,16 +860,16 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) // reset design mode at draw view for form // shell, if needed. if ( ((SwPagePreView*)pExistingSh)->ResetFormDesignMode() && - pWrtShell->HasDrawView() ) + m_pWrtShell->HasDrawView() ) { - SdrView* pDrawView = pWrtShell->GetDrawView(); + SdrView* pDrawView = m_pWrtShell->GetDrawView(); pDrawView->SetDesignMode( ((SwPagePreView*)pExistingSh)->FormDesignModeToReset() ); } } } RTL_LOGFILE_CONTEXT_TRACE( aLog, "after create WrtShell" ); - pHRuler = new SwCommentRuler(pWrtShell, &GetViewFrame()->GetWindow(), pEditWin, + m_pHRuler = new SwCommentRuler(m_pWrtShell, &GetViewFrame()->GetWindow(), m_pEditWin, SVXRULER_SUPPORT_TABS | SVXRULER_SUPPORT_PARAGRAPH_MARGINS | SVXRULER_SUPPORT_BORDERS | @@ -880,18 +880,18 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) // assure that modified state of document // isn't reset, if document is already modified. - const bool bIsDocModified = pWrtShell->GetDoc()->IsModified(); + const bool bIsDocModified = m_pWrtShell->GetDoc()->IsModified(); // damit unter anderem das HLineal im // ReadonlyFall nicht angezeigt wird - aUsrPref.SetReadonly( pWrtShell->GetViewOptions()->IsReadonly() ); + aUsrPref.SetReadonly( m_pWrtShell->GetViewOptions()->IsReadonly() ); // no margin for OLE! Size aBrwsBorder; if( SFX_CREATE_MODE_EMBEDDED != pDocSh->GetCreateMode() ) aBrwsBorder = GetMargin(); - pWrtShell->SetBrowseBorder( aBrwsBorder ); + m_pWrtShell->SetBrowseBorder( aBrwsBorder ); // Im CTOR duerfen keine Shell wechsel erfolgen, die muessen ueber // den Timer "zwischen gespeichert" werden. Sonst raeumt der SFX @@ -899,8 +899,8 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) bool bOld = bNoInterrupt; bNoInterrupt = true; - pHRuler->SetActive( sal_True ); - pVRuler->SetActive( sal_True ); + m_pHRuler->SetActive( sal_True ); + m_pVRuler->SetActive( sal_True ); SfxViewFrame* pViewFrame = GetViewFrame(); if( pViewFrame->GetFrame().GetParentFrame()) @@ -914,31 +914,31 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) // Set Zoom-factor from HLineal Fraction aZoomFract( aUsrPref.GetZoom(), 100 ); - pHRuler->SetZoom( aZoomFract ); - pVRuler->SetZoom( aZoomFract ); - pHRuler->SetDoubleClickHdl(LINK( this, SwView, ExecRulerClick )); + m_pHRuler->SetZoom( aZoomFract ); + m_pVRuler->SetZoom( aZoomFract ); + m_pHRuler->SetDoubleClickHdl(LINK( this, SwView, ExecRulerClick )); FieldUnit eMetric = pUsrPref->GetHScrollMetric(); - pHRuler->SetUnit( eMetric ); + m_pHRuler->SetUnit( eMetric ); eMetric = pUsrPref->GetVScrollMetric(); - pVRuler->SetUnit( eMetric ); + m_pVRuler->SetUnit( eMetric ); - pHRuler->SetCharWidth( 371 ); // default character width - pVRuler->SetLineHeight( 551 ); // default line height + m_pHRuler->SetCharWidth( 371 ); // default character width + m_pVRuler->SetLineHeight( 551 ); // default line height // DocShell setzen pDocSh->SetView( this ); SW_MOD()->SetView( this ); - mpPostItMgr = new SwPostItMgr(this); + m_pPostItMgr = new SwPostItMgr(this); // Die DocSize erfragen und verarbeiten. Ueber die Handler konnte // die Shell nicht gefunden werden, weil die Shell innerhalb CTOR-Phase // nicht in der SFX-Verwaltung bekannt ist. - DocSzChgd( pWrtShell->GetDocSize() ); + DocSzChgd( m_pWrtShell->GetDocSize() ); // AttrChangedNotify Link setzen - pWrtShell->SetChgLnk(LINK(this, SwView, AttrChangedNotify)); + m_pWrtShell->SetChgLnk(LINK(this, SwView, AttrChangedNotify)); if( pDocSh->GetCreateMode() == SFX_CREATE_MODE_EMBEDDED && //TODO/LATER: why a cast here? @@ -950,45 +950,45 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) SAL_WARN_IF( officecfg::Office::Common::Undo::Steps::get() <= 0, "sw", "/org.openoffice.Office.Common/Undo/Steps <= 0"); - pWrtShell->DoUndo( true ); + m_pWrtShell->DoUndo( true ); - const sal_Bool bBrowse = pWrtShell->GetViewOptions()->getBrowseMode(); + const sal_Bool bBrowse = m_pWrtShell->GetViewOptions()->getBrowseMode(); // Disable "multiple window" SetNewWindowAllowed(!bBrowse); // End of disabled multiple window - mbVScrollbarEnabled = aUsrPref.IsViewVScrollBar(); - mbHScrollbarEnabled = aUsrPref.IsViewHScrollBar(); - pHScrollbar->SetAuto(bBrowse); + m_bVScrollbarEnabled = aUsrPref.IsViewVScrollBar(); + m_bHScrollbarEnabled = aUsrPref.IsViewHScrollBar(); + m_pHScrollbar->SetAuto(bBrowse); if( aUsrPref.IsViewHRuler() ) CreateTab(); if( aUsrPref.IsViewVRuler() ) CreateVLineal(); - pWrtShell->SetUIOptions( aUsrPref ); - pWrtShell->SetReadOnlyAvailable( aUsrPref.IsCursorInProtectedArea() ); - pWrtShell->ApplyAccessiblityOptions(SW_MOD()->GetAccessibilityOptions()); + m_pWrtShell->SetUIOptions( aUsrPref ); + m_pWrtShell->SetReadOnlyAvailable( aUsrPref.IsCursorInProtectedArea() ); + m_pWrtShell->ApplyAccessiblityOptions(SW_MOD()->GetAccessibilityOptions()); - if( pWrtShell->GetDoc()->IsUpdateExpFld() ) + if( m_pWrtShell->GetDoc()->IsUpdateExpFld() ) { - if (pWrtShell->GetDoc()->containsUpdatableFields()) + if (m_pWrtShell->GetDoc()->containsUpdatableFields()) { - SET_CURR_SHELL( pWrtShell ); - pWrtShell->StartAction(); - pWrtShell->CalcLayout(); - pWrtShell->GetDoc()->UpdateFlds(NULL, false); - pWrtShell->EndAction(); + SET_CURR_SHELL( m_pWrtShell ); + m_pWrtShell->StartAction(); + m_pWrtShell->CalcLayout(); + m_pWrtShell->GetDoc()->UpdateFlds(NULL, false); + m_pWrtShell->EndAction(); } - pWrtShell->GetDoc()->SetUpdateExpFldStat( sal_False ); + m_pWrtShell->GetDoc()->SetUpdateExpFldStat( sal_False ); } // ggfs. alle Verzeichnisse updaten: - if( pWrtShell->GetDoc()->IsUpdateTOX() ) + if( m_pWrtShell->GetDoc()->IsUpdateTOX() ) { SfxRequest aSfxRequest( FN_UPDATE_TOX, SFX_CALLMODE_SLOT, GetPool() ); Execute( aSfxRequest ); - pWrtShell->GetDoc()->SetUpdateTOX( sal_False ); // wieder zurueck setzen - pWrtShell->SttEndDoc(sal_True); + m_pWrtShell->GetDoc()->SetUpdateTOX( sal_False ); // wieder zurueck setzen + m_pWrtShell->SttEndDoc(sal_True); } // kein ResetModified, wenn es schone eine View auf dieses Doc gibt @@ -1000,11 +1000,11 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) // so setze das Modified NICHT zurueck. // no reset of modified state, if document // was already modified. - if (!pWrtShell->GetDoc()->GetIDocumentUndoRedo().IsUndoNoResetModified() && + if (!m_pWrtShell->GetDoc()->GetIDocumentUndoRedo().IsUndoNoResetModified() && ( !pFirst || pFirst == pVFrame ) && !bIsDocModified ) { - pWrtShell->ResetModified(); + m_pWrtShell->ResetModified(); } bNoInterrupt = bOld; @@ -1023,27 +1023,27 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) OUString("_beamer"), frame::FrameSearchFlag::CHILDREN); if(xBeamerFrame.is()) { - SwDBData aData = pWrtShell->GetDBData(); + SwDBData aData = m_pWrtShell->GetDBData(); SW_MOD()->ShowDBObj( *this, aData ); } // has anybody calls the attrchanged handler in the constructor? - if( bAttrChgNotifiedWithRegistrations ) + if( m_bAttrChgNotifiedWithRegistrations ) { GetViewFrame()->GetBindings().LEAVEREGISTRATIONS(); - if( aTimer.IsActive() ) - aTimer.Stop(); + if( m_aTimer.IsActive() ) + m_aTimer.Stop(); } - aTimer.SetTimeoutHdl(LINK(this, SwView, TimeoutHdl)); - bAttrChgNotified = bAttrChgNotifiedWithRegistrations = sal_False; + m_aTimer.SetTimeoutHdl(LINK(this, SwView, TimeoutHdl)); + m_bAttrChgNotified = m_bAttrChgNotifiedWithRegistrations = sal_False; if(bOldModifyFlag) pDocSh->EnableSetModified( sal_True ); InvalidateBorder(); - if( !pHScrollbar->IsVisible( sal_True ) ) + if( !m_pHScrollbar->IsVisible( sal_True ) ) ShowHScrollbar( sal_False ); - if( !pVScrollbar->IsVisible( sal_True ) ) + if( !m_pVScrollbar->IsVisible( sal_True ) ) ShowVScrollbar( sal_False ); GetViewFrame()->GetWindow().AddChildEventListener( LINK( this, SwView, WindowChildEventListener ) ); @@ -1052,11 +1052,11 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh ) SwView::~SwView() { GetViewFrame()->GetWindow().RemoveChildEventListener( LINK( this, SwView, WindowChildEventListener ) ); - delete mpPostItMgr; - mpPostItMgr = 0; + delete m_pPostItMgr; + m_pPostItMgr = 0; - bInDtor = sal_True; - pEditWin->Hide(); // damit kein Paint Aerger machen kann! + m_bInDtor = sal_True; + m_pEditWin->Hide(); // damit kein Paint Aerger machen kann! // An der SwDocShell den Pointer auf die View ruecksetzen SwDocShell* pDocSh = GetDocShell(); @@ -1065,35 +1065,35 @@ SwView::~SwView() if ( SW_MOD()->GetView() == this ) SW_MOD()->SetView( 0 ); - if( aTimer.IsActive() && bAttrChgNotifiedWithRegistrations ) + if( m_aTimer.IsActive() && m_bAttrChgNotifiedWithRegistrations ) GetViewFrame()->GetBindings().LEAVEREGISTRATIONS(); // the last view must end the text edit - SdrView *pSdrView = pWrtShell ? pWrtShell->GetDrawView() : 0; + SdrView *pSdrView = m_pWrtShell ? m_pWrtShell->GetDrawView() : 0; if( pSdrView && pSdrView->IsTextEdit() ) pSdrView->SdrEndTextEdit( sal_True ); SetWindow( 0 ); - pViewImpl->Invalidate(); + m_pViewImpl->Invalidate(); EndListening(*GetViewFrame()); EndListening(*GetDocShell()); - delete pScrollFill; - delete pWrtShell; - pWrtShell = 0; // Auf 0 setzen, damit folgende DToren nicht drauf zugreifen - pShell = 0; - delete pHScrollbar; - delete pVScrollbar; - delete pHRuler; - delete pVRuler; - delete pTogglePageBtn; - delete pPageUpBtn; - delete pNaviBtn; - delete pPageDownBtn; - delete pGlosHdl; - delete pViewImpl; - delete pEditWin; - delete pFormatClipboard; + delete m_pScrollFill; + delete m_pWrtShell; + m_pWrtShell = 0; // Auf 0 setzen, damit folgende DToren nicht drauf zugreifen + m_pShell = 0; + delete m_pHScrollbar; + delete m_pVScrollbar; + delete m_pHRuler; + delete m_pVRuler; + delete m_pTogglePageBtn; + delete m_pPageUpBtn; + delete m_pNaviBtn; + delete m_pPageDownBtn; + delete m_pGlosHdl; + delete m_pViewImpl; + delete m_pEditWin; + delete m_pFormatClipboard; } SwDocShell* SwView::GetDocShell() @@ -1111,14 +1111,14 @@ void SwView::WriteUserData( String &rUserData, sal_Bool bBrowse ) //werden (nicht zu verwechseln mit dem BrowseMode). //Die dann gespeicherten Daten sind nicht persistent!! - const SwRect& rRect = pWrtShell->GetCharRect(); + const SwRect& rRect = m_pWrtShell->GetCharRect(); const Rectangle& rVis = GetVisArea(); rUserData = OUString::number( rRect.Left() ); rUserData += ';'; rUserData += OUString::number( rRect.Top() ); rUserData += ';'; - rUserData += OUString::number( pWrtShell->GetViewOptions()->GetZoom() ); + rUserData += OUString::number( m_pWrtShell->GetViewOptions()->GetZoom() ); rUserData += ';'; rUserData += OUString::number( rVis.Left() ); rUserData += ';'; @@ -1129,9 +1129,9 @@ void SwView::WriteUserData( String &rUserData, sal_Bool bBrowse ) rUserData += OUString::number( bBrowse ? SAL_MIN_INT32 : rVis.Bottom()); rUserData += ';'; rUserData += OUString::number( - (sal_uInt16)pWrtShell->GetViewOptions()->GetZoomType());//eZoom; + (sal_uInt16)m_pWrtShell->GetViewOptions()->GetZoomType());//eZoom; rUserData += ';'; - rUserData += FRMTYPE_NONE == pWrtShell->GetSelFrmType() ? '0' : '1'; + rUserData += FRMTYPE_NONE == m_pWrtShell->GetSelFrmType() ? '0' : '1'; } /*-------------------------------------------------------------------- @@ -1156,11 +1156,11 @@ void SwView::ReadUserData( const String &rUserData, sal_Bool bBrowse ) if ( comphelper::string::getTokenCount(rUserData, ';') > 1 && //Fuer Dokumente ohne Layout nur im OnlineLayout oder beim //Forward/Backward - (!pWrtShell->IsNewLayout() || pWrtShell->GetViewOptions()->getBrowseMode() || bBrowse) ) + (!m_pWrtShell->IsNewLayout() || m_pWrtShell->GetViewOptions()->getBrowseMode() || bBrowse) ) { bool bIsOwnDocument = lcl_IsOwnDocument( *this ); - SET_CURR_SHELL(pWrtShell); + SET_CURR_SHELL(m_pWrtShell); sal_Int32 nPos = 0; @@ -1178,16 +1178,16 @@ void SwView::ReadUserData( const String &rUserData, sal_Bool bBrowse ) nRight = rUserData.GetToken(0, ';', nPos ).ToInt32(), nBottom= rUserData.GetToken(0, ';', nPos ).ToInt32(); - const long nAdd = pWrtShell->GetViewOptions()->getBrowseMode() ? DOCUMENTBORDER : DOCUMENTBORDER*2; - if ( nBottom <= (pWrtShell->GetDocSize().Height()+nAdd) ) + const long nAdd = m_pWrtShell->GetViewOptions()->getBrowseMode() ? DOCUMENTBORDER : DOCUMENTBORDER*2; + if ( nBottom <= (m_pWrtShell->GetDocSize().Height()+nAdd) ) { - pWrtShell->EnableSmooth( sal_False ); + m_pWrtShell->EnableSmooth( sal_False ); const Rectangle aVis( nLeft, nTop, nRight, nBottom ); sal_uInt16 nOff = 0; SvxZoomType eZoom; - if( !pWrtShell->GetViewOptions()->getBrowseMode() ) + if( !m_pWrtShell->GetViewOptions()->getBrowseMode() ) eZoom = (SvxZoomType) (sal_uInt16)rUserData.GetToken(nOff, ';', nPos ).ToInt32(); else { @@ -1196,34 +1196,34 @@ void SwView::ReadUserData( const String &rUserData, sal_Bool bBrowse ) } sal_Bool bSelectObj = (0 != rUserData.GetToken( nOff, ';', nPos ).ToInt32()) - && pWrtShell->IsObjSelectable( aCrsrPos ); + && m_pWrtShell->IsObjSelectable( aCrsrPos ); // restore editing position - pViewImpl->SetRestorePosition(aCrsrPos, bSelectObj); + m_pViewImpl->SetRestorePosition(aCrsrPos, bSelectObj); // set flag value to avoid macro execution. - bool bSavedFlagValue = pWrtShell->IsMacroExecAllowed(); - pWrtShell->SetMacroExecAllowed( false ); + bool bSavedFlagValue = m_pWrtShell->IsMacroExecAllowed(); + 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(bOldShellWasPagePreView || bIsOwnDocument) + if(m_bOldShellWasPagePreView || bIsOwnDocument) { - pWrtShell->SwCrsrShell::SetCrsr( aCrsrPos, !bSelectObj ); + m_pWrtShell->SwCrsrShell::SetCrsr( aCrsrPos, !bSelectObj ); if( bSelectObj ) { - pWrtShell->SelectObj( aCrsrPos ); - pWrtShell->EnterSelFrmMode( &aCrsrPos ); + m_pWrtShell->SelectObj( aCrsrPos ); + m_pWrtShell->EnterSelFrmMode( &aCrsrPos ); } } // reset flag value - pWrtShell->SetMacroExecAllowed( bSavedFlagValue ); + m_pWrtShell->SetMacroExecAllowed( bSavedFlagValue ); // set visible area before applying // information from print preview. Otherwise, the applied information // 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(bOldShellWasPagePreView || bIsOwnDocument ) + if(m_bOldShellWasPagePreView || bIsOwnDocument ) { if ( bBrowse ) SetVisArea( aVis.TopLeft() ); @@ -1232,56 +1232,56 @@ void SwView::ReadUserData( const String &rUserData, sal_Bool bBrowse ) } //apply information from print preview - if available - if( sNewCrsrPos.Len() ) + if( m_sNewCrsrPos.Len() ) { - long nXTmp = sNewCrsrPos.GetToken( 0, ';' ).ToInt32(), - nYTmp = sNewCrsrPos.GetToken( 1, ';' ).ToInt32(); + long nXTmp = m_sNewCrsrPos.GetToken( 0, ';' ).ToInt32(), + nYTmp = m_sNewCrsrPos.GetToken( 1, ';' ).ToInt32(); Point aCrsrPos2( nXTmp, nYTmp ); - bSelectObj = pWrtShell->IsObjSelectable( aCrsrPos2 ); + bSelectObj = m_pWrtShell->IsObjSelectable( aCrsrPos2 ); - pWrtShell->SwCrsrShell::SetCrsr( aCrsrPos2, sal_False ); + m_pWrtShell->SwCrsrShell::SetCrsr( aCrsrPos2, sal_False ); if( bSelectObj ) { - pWrtShell->SelectObj( aCrsrPos2 ); - pWrtShell->EnterSelFrmMode( &aCrsrPos2 ); + m_pWrtShell->SelectObj( aCrsrPos2 ); + m_pWrtShell->EnterSelFrmMode( &aCrsrPos2 ); } - pWrtShell->MakeSelVisible(); - sNewCrsrPos.Erase(); + m_pWrtShell->MakeSelVisible(); + m_sNewCrsrPos.Erase(); } - else if(USHRT_MAX != nNewPage) + else if(USHRT_MAX != m_nNewPage) { - pWrtShell->GotoPage(nNewPage, sal_True); - nNewPage = USHRT_MAX; + m_pWrtShell->GotoPage(m_nNewPage, sal_True); + m_nNewPage = USHRT_MAX; } SelectShell(); - pWrtShell->StartAction(); - const SwViewOption* pVOpt = pWrtShell->GetViewOptions(); + m_pWrtShell->StartAction(); + const SwViewOption* pVOpt = m_pWrtShell->GetViewOptions(); if( pVOpt->GetZoom() != nZoomFactor || pVOpt->GetZoomType() != eZoom ) SetZoom( eZoom, nZoomFactor); - pWrtShell->LockView( sal_True ); - pWrtShell->EndAction(); - pWrtShell->LockView( sal_False ); - pWrtShell->EnableSmooth( sal_True ); + m_pWrtShell->LockView( sal_True ); + m_pWrtShell->EndAction(); + m_pWrtShell->LockView( sal_False ); + m_pWrtShell->EnableSmooth( sal_True ); } } } void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue >& rSequence, sal_Bool bBrowse ) { - if(GetDocShell()->IsPreview()||bIsPreviewDoubleClick) + if(GetDocShell()->IsPreview()||m_bIsPreviewDoubleClick) return; bool bIsOwnDocument = lcl_IsOwnDocument( *this ); sal_Int32 nLength = rSequence.getLength(); - if (nLength && (!pWrtShell->IsNewLayout() || pWrtShell->GetViewOptions()->getBrowseMode() || bBrowse) ) + if (nLength && (!m_pWrtShell->IsNewLayout() || m_pWrtShell->GetViewOptions()->getBrowseMode() || bBrowse) ) { - SET_CURR_SHELL(pWrtShell); + SET_CURR_SHELL(m_pWrtShell); const beans::PropertyValue *pValue = rSequence.getConstArray(); - const SwRect& rRect = pWrtShell->GetCharRect(); + const SwRect& rRect = m_pWrtShell->GetCharRect(); const Rectangle &rVis = GetVisArea(); - const SwViewOption* pVOpt = pWrtShell->GetViewOptions(); + const SwViewOption* pVOpt = m_pWrtShell->GetViewOptions(); long nX = rRect.Left(), nY = rRect.Top(), nLeft = rVis.Left(), nTop = rVis.Top(); long nRight = bBrowse ? LONG_MIN : rVis.Right(), nBottom = bBrowse ? LONG_MIN : rVis.Bottom(); @@ -1290,7 +1290,7 @@ void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue > bool bViewLayoutBookMode = pVOpt->IsViewLayoutBookMode(); sal_Int16 nViewLayoutColumns = pVOpt->GetViewLayoutColumns(); - sal_Bool bSelectedFrame = ( pWrtShell->GetSelFrmType() != FRMTYPE_NONE ), + sal_Bool bSelectedFrame = ( m_pWrtShell->GetSelFrmType() != FRMTYPE_NONE ), bGotVisibleLeft = sal_False, bGotVisibleTop = sal_False, bGotVisibleRight = sal_False, bGotVisibleBottom = sal_False, bGotZoomType = sal_False, @@ -1363,14 +1363,14 @@ void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue > if (bGotVisibleBottom) { Point aCrsrPos( nX, nY ); - const long nAdd = pWrtShell->GetViewOptions()->getBrowseMode() ? DOCUMENTBORDER : DOCUMENTBORDER*2; - if (nBottom <= (pWrtShell->GetDocSize().Height()+nAdd) ) + const long nAdd = m_pWrtShell->GetViewOptions()->getBrowseMode() ? DOCUMENTBORDER : DOCUMENTBORDER*2; + if (nBottom <= (m_pWrtShell->GetDocSize().Height()+nAdd) ) { - pWrtShell->EnableSmooth( sal_False ); + m_pWrtShell->EnableSmooth( sal_False ); const Rectangle aVis( nLeft, nTop, nRight, nBottom ); SvxZoomType eZoom; - if ( !pWrtShell->GetViewOptions()->getBrowseMode() ) + if ( !m_pWrtShell->GetViewOptions()->getBrowseMode() ) eZoom = static_cast < SvxZoomType > ( nZoomType ); else { @@ -1379,48 +1379,48 @@ void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue > if (bGotIsSelectedFrame) { sal_Bool bSelectObj = (sal_False != bSelectedFrame ) - && pWrtShell->IsObjSelectable( aCrsrPos ); + && m_pWrtShell->IsObjSelectable( aCrsrPos ); // set flag value to avoid macro execution. - bool bSavedFlagValue = pWrtShell->IsMacroExecAllowed(); - pWrtShell->SetMacroExecAllowed( false ); + bool bSavedFlagValue = m_pWrtShell->IsMacroExecAllowed(); + 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 - pViewImpl->SetRestorePosition(aCrsrPos, bSelectObj); - if(bOldShellWasPagePreView|| bIsOwnDocument) + m_pViewImpl->SetRestorePosition(aCrsrPos, bSelectObj); + if(m_bOldShellWasPagePreView|| bIsOwnDocument) { - pWrtShell->SwCrsrShell::SetCrsr( aCrsrPos, !bSelectObj ); + m_pWrtShell->SwCrsrShell::SetCrsr( aCrsrPos, !bSelectObj ); // Update the shell to toggle Header/Footer edit if needed sal_Bool bInHeader = sal_True; - if ( pWrtShell->IsInHeaderFooter( &bInHeader ) ) + if ( m_pWrtShell->IsInHeaderFooter( &bInHeader ) ) { if ( !bInHeader ) { - pWrtShell->SetShowHeaderFooterSeparator( Footer, true ); - pWrtShell->SetShowHeaderFooterSeparator( Header, false ); + m_pWrtShell->SetShowHeaderFooterSeparator( Footer, true ); + m_pWrtShell->SetShowHeaderFooterSeparator( Header, false ); } else { - pWrtShell->SetShowHeaderFooterSeparator( Header, true ); - pWrtShell->SetShowHeaderFooterSeparator( Footer, false ); + m_pWrtShell->SetShowHeaderFooterSeparator( Header, true ); + m_pWrtShell->SetShowHeaderFooterSeparator( Footer, false ); } // Force repaint - pWrtShell->GetWin()->Invalidate(); + m_pWrtShell->GetWin()->Invalidate(); } - if ( pWrtShell->IsInHeaderFooter() != pWrtShell->IsHeaderFooterEdit() ) - pWrtShell->ToggleHeaderFooterEdit(); + if ( m_pWrtShell->IsInHeaderFooter() != m_pWrtShell->IsHeaderFooterEdit() ) + m_pWrtShell->ToggleHeaderFooterEdit(); if( bSelectObj ) { - pWrtShell->SelectObj( aCrsrPos ); - pWrtShell->EnterSelFrmMode( &aCrsrPos ); + m_pWrtShell->SelectObj( aCrsrPos ); + m_pWrtShell->EnterSelFrmMode( &aCrsrPos ); } } // reset flag value - pWrtShell->SetMacroExecAllowed( bSavedFlagValue ); + m_pWrtShell->SetMacroExecAllowed( bSavedFlagValue ); } SelectShell(); @@ -1441,20 +1441,20 @@ void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue > eZoom != SVX_ZOOM_PERCENT; if ( !bZoomNeedsViewLayout ) - pWrtShell->StartAction(); + m_pWrtShell->StartAction(); if ( bSetViewLayoutSettings ) SetViewLayout( nViewLayoutColumns, bViewLayoutBookMode, sal_True ); if ( bZoomNeedsViewLayout ) - pWrtShell->StartAction(); + m_pWrtShell->StartAction(); if ( bSetViewSettings ) SetZoom( eZoom, nZoomFactor, sal_True ); // 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(bOldShellWasPagePreView||bIsOwnDocument) + if(m_bOldShellWasPagePreView||bIsOwnDocument) { if ( bBrowse && bGotVisibleLeft && bGotVisibleTop ) { @@ -1462,12 +1462,12 @@ void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue > // make sure the document is still centered const SwTwips lBorder = IsDocumentBorder() ? DOCUMENTBORDER : 2 * DOCUMENTBORDER; SwTwips nEditWidth = GetEditWin().GetOutputSize().Width(); - if(nEditWidth > (aDocSz.Width() + lBorder )) - aTopLeft.X() = ( aDocSz.Width() + lBorder - nEditWidth ) / 2; + if(nEditWidth > (m_aDocSz.Width() + lBorder )) + aTopLeft.X() = ( m_aDocSz.Width() + lBorder - nEditWidth ) / 2; else { //check if the values are possible - long nXMax = pHScrollbar->GetRangeMax() - pHScrollbar->GetVisibleSize(); + long nXMax = m_pHScrollbar->GetRangeMax() - m_pHScrollbar->GetVisibleSize(); if( aTopLeft.X() > nXMax ) aTopLeft.X() = nXMax < 0 ? 0 : nXMax; } @@ -1477,10 +1477,10 @@ void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue > SetVisArea( aVis ); } - pWrtShell->LockView( sal_True ); - pWrtShell->EndAction(); - pWrtShell->LockView( sal_False ); - pWrtShell->EnableSmooth( sal_True ); + m_pWrtShell->LockView( sal_True ); + m_pWrtShell->EndAction(); + m_pWrtShell->LockView( sal_False ); + m_pWrtShell->EnableSmooth( sal_True ); } } } @@ -1489,7 +1489,7 @@ void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue > #define NUM_VIEW_SETTINGS 12 void SwView::WriteUserDataSequence ( uno::Sequence < beans::PropertyValue >& rSequence, sal_Bool bBrowse ) { - const SwRect& rRect = pWrtShell->GetCharRect(); + const SwRect& rRect = m_pWrtShell->GetCharRect(); const Rectangle& rVis = GetVisArea(); Any aAny; @@ -1529,26 +1529,26 @@ void SwView::WriteUserDataSequence ( uno::Sequence < beans::PropertyValue >& rSe pValue++;nIndex++; pValue->Name = OUString( "ZoomType" ); - const sal_Int16 nZoomType = static_cast< sal_Int16 >(pWrtShell->GetViewOptions()->GetZoomType()); + const sal_Int16 nZoomType = static_cast< sal_Int16 >(m_pWrtShell->GetViewOptions()->GetZoomType()); pValue->Value <<= nZoomType; pValue++;nIndex++; pValue->Name = OUString( "ViewLayoutColumns" ); - const sal_Int16 nViewLayoutColumns = static_cast< sal_Int16 >(pWrtShell->GetViewOptions()->GetViewLayoutColumns()); + const sal_Int16 nViewLayoutColumns = static_cast< sal_Int16 >(m_pWrtShell->GetViewOptions()->GetViewLayoutColumns()); pValue->Value <<= nViewLayoutColumns; pValue++;nIndex++; pValue->Name = OUString( "ViewLayoutBookMode" ); - const sal_Bool bIsViewLayoutBookMode = pWrtShell->GetViewOptions()->IsViewLayoutBookMode(); + const sal_Bool bIsViewLayoutBookMode = m_pWrtShell->GetViewOptions()->IsViewLayoutBookMode(); pValue->Value.setValue( &bIsViewLayoutBookMode, ::getBooleanCppuType() ); pValue++;nIndex++; pValue->Name = OUString( "ZoomFactor" ); - pValue->Value <<= static_cast < sal_Int16 > (pWrtShell->GetViewOptions()->GetZoom()); + pValue->Value <<= static_cast < sal_Int16 > (m_pWrtShell->GetViewOptions()->GetZoom()); pValue++;nIndex++; pValue->Name = OUString( "IsSelectedFrame" ); - const sal_Bool bIsSelected = FRMTYPE_NONE == pWrtShell->GetSelFrmType() ? sal_False : sal_True; + const sal_Bool bIsSelected = FRMTYPE_NONE == m_pWrtShell->GetSelFrmType() ? sal_False : sal_True; pValue->Value.setValue ( &bIsSelected, ::getBooleanCppuType() ); nIndex++; @@ -1560,16 +1560,16 @@ void SwView::WriteUserDataSequence ( uno::Sequence < beans::PropertyValue >& rSe void SwView::ShowCursor( bool bOn ) { //don't scroll the cursor into the visible area - sal_Bool bUnlockView = !pWrtShell->IsViewLocked(); - pWrtShell->LockView( sal_True ); //lock visible section + sal_Bool bUnlockView = !m_pWrtShell->IsViewLocked(); + m_pWrtShell->LockView( sal_True ); //lock visible section if( !bOn ) - pWrtShell->HideCrsr(); - else if( !pWrtShell->IsFrmSelected() && !pWrtShell->IsObjSelected() ) - pWrtShell->ShowCrsr(); + m_pWrtShell->HideCrsr(); + else if( !m_pWrtShell->IsFrmSelected() && !m_pWrtShell->IsObjSelected() ) + m_pWrtShell->ShowCrsr(); if( bUnlockView ) - pWrtShell->LockView( sal_False ); + m_pWrtShell->LockView( sal_False ); } ErrCode SwView::DoVerb( long nVerb ) @@ -1612,9 +1612,9 @@ String SwView::GetSelectionTextParam( sal_Bool bCompleteWrds, SwGlossaryHdl* SwView::GetGlosHdl() { - if(!pGlosHdl) - pGlosHdl = new SwGlossaryHdl(GetViewFrame(), pWrtShell); - return pGlosHdl; + if(!m_pGlosHdl) + m_pGlosHdl = new SwGlossaryHdl(GetViewFrame(), m_pWrtShell); + return m_pGlosHdl; } void SwView::Notify( SfxBroadcaster& rBC, const SfxHint& rHint ) @@ -1639,8 +1639,8 @@ void SwView::Notify( SfxBroadcaster& rBC, const SfxHint& rHint ) { // Modalmodus-Umschaltung? sal_Bool bModal = GetDocShell()->IsInModalMode(); - pHRuler->SetActive( !bModal ); - pVRuler->SetActive( !bModal ); + m_pHRuler->SetActive( !bModal ); + m_pVRuler->SetActive( !bModal ); } /* no break here */ @@ -1699,7 +1699,7 @@ void SwView::Notify( SfxBroadcaster& rBC, const SfxHint& rHint ) GetDrawFuncPtr()->Deactivate(); SetDrawFuncPtr(NULL); LeaveDrawCreate(); - AttrChangedNotify(pWrtShell); + AttrChangedNotify(m_pWrtShell); } } @@ -1728,7 +1728,7 @@ void SwView::ScannerEventHdl( const EventObject& /*rEventObject*/ ) if( !!aScanBmp ) { Graphic aGrf(aScanBmp); - pWrtShell->Insert( aEmptyStr, aEmptyStr, aGrf ); + m_pWrtShell->Insert( aEmptyStr, aEmptyStr, aGrf ); } } } @@ -1741,16 +1741,16 @@ void SwView::ScannerEventHdl( const EventObject& /*rEventObject*/ ) void SwView::StopShellTimer() { - if(aTimer.IsActive()) + if(m_aTimer.IsActive()) { - aTimer.Stop(); - if ( bAttrChgNotifiedWithRegistrations ) + m_aTimer.Stop(); + if ( m_bAttrChgNotifiedWithRegistrations ) { GetViewFrame()->GetBindings().LEAVEREGISTRATIONS(); - bAttrChgNotifiedWithRegistrations = sal_False; + m_bAttrChgNotifiedWithRegistrations = sal_False; } SelectShell(); - bAttrChgNotified = sal_False; + m_bAttrChgNotified = sal_False; } } @@ -1762,8 +1762,8 @@ sal_uInt16 SwView::PrepareClose( sal_Bool bUI, sal_Bool bForBrowsing ) pVFrame->GetDispatcher()->Lock(sal_False); sal_uInt16 nRet; - if ( pFormShell && - sal_True != (nRet = pFormShell->PrepareClose( bUI, bForBrowsing )) ) + if ( m_pFormShell && + sal_True != (nRet = m_pFormShell->PrepareClose( bUI, bForBrowsing )) ) { return nRet; @@ -1775,52 +1775,52 @@ sal_uInt16 SwView::PrepareClose( sal_Bool bUI, sal_Bool bForBrowsing ) // Status changes now notified from the clipboard. sal_Bool SwView::IsPasteAllowed() { - sal_uInt16 nPasteDestination = SwTransferable::GetSotDestination( *pWrtShell ); - if( nLastPasteDestination != nPasteDestination ) + sal_uInt16 nPasteDestination = SwTransferable::GetSotDestination( *m_pWrtShell ); + if( m_nLastPasteDestination != nPasteDestination ) { TransferableDataHelper aDataHelper( TransferableDataHelper::CreateFromSystemClipboard( &GetEditWin()) ); if( aDataHelper.GetXTransferable().is() ) { - bPasteState = SwTransferable::IsPaste( *pWrtShell, aDataHelper ); - bPasteSpecialState = SwTransferable::IsPasteSpecial( - *pWrtShell, aDataHelper ); + m_bPasteState = SwTransferable::IsPaste( *m_pWrtShell, aDataHelper ); + m_bPasteSpecialState = SwTransferable::IsPasteSpecial( + *m_pWrtShell, aDataHelper ); } else - bPasteState = bPasteSpecialState = sal_False; + m_bPasteState = m_bPasteSpecialState = sal_False; - if( 0xFFFF == nLastPasteDestination ) // the init value - pViewImpl->AddClipboardListener(); - nLastPasteDestination = nPasteDestination; + if( 0xFFFF == m_nLastPasteDestination ) // the init value + m_pViewImpl->AddClipboardListener(); + m_nLastPasteDestination = nPasteDestination; } - return bPasteState; + return m_bPasteState; } sal_Bool SwView::IsPasteSpecialAllowed() { - if ( pFormShell && pFormShell->IsActiveControl() ) + if ( m_pFormShell && m_pFormShell->IsActiveControl() ) return sal_False; - sal_uInt16 nPasteDestination = SwTransferable::GetSotDestination( *pWrtShell ); - if( nLastPasteDestination != nPasteDestination ) + sal_uInt16 nPasteDestination = SwTransferable::GetSotDestination( *m_pWrtShell ); + if( m_nLastPasteDestination != nPasteDestination ) { TransferableDataHelper aDataHelper( TransferableDataHelper::CreateFromSystemClipboard( &GetEditWin()) ); if( aDataHelper.GetXTransferable().is() ) { - bPasteState = SwTransferable::IsPaste( *pWrtShell, aDataHelper ); - bPasteSpecialState = SwTransferable::IsPasteSpecial( - *pWrtShell, aDataHelper ); + m_bPasteState = SwTransferable::IsPaste( *m_pWrtShell, aDataHelper ); + m_bPasteSpecialState = SwTransferable::IsPasteSpecial( + *m_pWrtShell, aDataHelper ); } else - bPasteState = bPasteSpecialState = sal_False; + m_bPasteState = m_bPasteSpecialState = sal_False; - if( 0xFFFF == nLastPasteDestination ) // the init value - pViewImpl->AddClipboardListener(); + if( 0xFFFF == m_nLastPasteDestination ) // the init value + m_pViewImpl->AddClipboardListener(); } - return bPasteSpecialState; + return m_bPasteSpecialState; } void SwView::NotifyDBChanged() diff --git a/sw/source/ui/uiview/view0.cxx b/sw/source/ui/uiview/view0.cxx index fd2e384f09e6..596ef1f033ca 100644 --- a/sw/source/ui/uiview/view0.cxx +++ b/sw/source/ui/uiview/view0.cxx @@ -121,43 +121,43 @@ TYPEINIT1(SwView,SfxViewShell) ShellModes SwView::GetShellMode() { - return pViewImpl->GetShellMode(); + return m_pViewImpl->GetShellMode(); } view::XSelectionSupplier* SwView::GetUNOObject() { - return pViewImpl->GetUNOObject(); + return m_pViewImpl->GetUNOObject(); } void SwView::ApplyAccessiblityOptions(SvtAccessibilityOptions& rAccessibilityOptions) { - pWrtShell->ApplyAccessiblityOptions(rAccessibilityOptions); + m_pWrtShell->ApplyAccessiblityOptions(rAccessibilityOptions); //to enable the right state of the selection cursor in readonly documents if(GetDocShell()->IsReadOnly()) - pWrtShell->ShowCrsr(); + m_pWrtShell->ShowCrsr(); } void SwView::SetMailMergeConfigItem(SwMailMergeConfigItem* pConfigItem, sal_uInt16 nRestart, sal_Bool bIsSource) { - pViewImpl->SetMailMergeConfigItem(pConfigItem, nRestart, bIsSource); + m_pViewImpl->SetMailMergeConfigItem(pConfigItem, nRestart, bIsSource); UIFeatureChanged(); } SwMailMergeConfigItem* SwView::GetMailMergeConfigItem() { - return pViewImpl->GetMailMergeConfigItem(); + return m_pViewImpl->GetMailMergeConfigItem(); } sal_uInt16 SwView::GetMailMergeRestartPage() const { - return pViewImpl->GetMailMergeRestartPage(); + return m_pViewImpl->GetMailMergeRestartPage(); } sal_Bool SwView::IsMailMergeSourceView() const { - return pViewImpl->IsMailMergeSourceView(); + return m_pViewImpl->IsMailMergeSourceView(); } static sal_Bool lcl_IsViewMarks( const SwViewOption& rVOpt ) diff --git a/sw/source/ui/uiview/view1.cxx b/sw/source/ui/uiview/view1.cxx index d978922d28aa..67d5bcc36485 100644 --- a/sw/source/ui/uiview/view1.cxx +++ b/sw/source/ui/uiview/view1.cxx @@ -45,8 +45,8 @@ extern int bDocSzUpdated; void SwView::Activate(sal_Bool bMDIActivate) { // fdo#40438 Update the layout to make sure everything is correct before showing the content - pWrtShell->StartAction(); - pWrtShell->EndAction( sal_True ); + m_pWrtShell->StartAction(); + m_pWrtShell->EndAction( sal_True ); // aktuelle View anmelden an der DocShell // die View bleibt solange an der DocShell @@ -60,28 +60,28 @@ void SwView::Activate(sal_Bool bMDIActivate) // Dokumentgroesse hat sich geaendert if(!bDocSzUpdated) - DocSzChgd(aDocSz); + DocSzChgd(m_aDocSz); // make selection visible - if(bMakeSelectionVisible) + if(m_bMakeSelectionVisible) { - pWrtShell->MakeSelVisible(); - bMakeSelectionVisible = sal_False; + m_pWrtShell->MakeSelVisible(); + m_bMakeSelectionVisible = sal_False; } - pHRuler->SetActive( sal_True ); - pVRuler->SetActive( sal_True ); + m_pHRuler->SetActive( sal_True ); + m_pVRuler->SetActive( sal_True ); if ( bMDIActivate ) { - pWrtShell->ShGetFcs(sal_False); // Selektionen sichtbar + m_pWrtShell->ShGetFcs(sal_False); // Selektionen sichtbar - if( sSwViewData.Len() ) + if( m_sSwViewData.Len() ) { - ReadUserData( sSwViewData, sal_False ); - sSwViewData.Erase(); + ReadUserData( m_sSwViewData, sal_False ); + m_sSwViewData.Erase(); } - AttrChangedNotify(pWrtShell); + AttrChangedNotify(m_pWrtShell); // Flddlg ggf neu initialisieren (z.B. fuer TYP_SETVAR) sal_uInt16 nId = SwFldDlgWrapper::GetChildWindowId(); @@ -100,18 +100,18 @@ void SwView::Activate(sal_Bool bMDIActivate) nId = SwInsertIdxMarkWrapper::GetChildWindowId(); SwInsertIdxMarkWrapper *pIdxMrk = (SwInsertIdxMarkWrapper*)pVFrame->GetChildWindow(nId); if (pIdxMrk) - pIdxMrk->ReInitDlg(*pWrtShell); + pIdxMrk->ReInitDlg(*m_pWrtShell); // reinit AuthMarkDlg nId = SwInsertAuthMarkWrapper::GetChildWindowId(); SwInsertAuthMarkWrapper *pAuthMrk = (SwInsertAuthMarkWrapper*)pVFrame-> GetChildWindow(nId); if (pAuthMrk) - pAuthMrk->ReInitDlg(*pWrtShell); + pAuthMrk->ReInitDlg(*m_pWrtShell); } else //Wenigstens das Notify rufen (vorsichtshalber wegen der SlotFilter - AttrChangedNotify(pWrtShell); + AttrChangedNotify(m_pWrtShell); SfxViewShell::Activate(bMDIActivate); } @@ -125,10 +125,10 @@ void SwView::Deactivate(sal_Bool bMDIActivate) if( bMDIActivate ) { - pWrtShell->ShLooseFcs(); // Selektionen unsichtbar + m_pWrtShell->ShLooseFcs(); // Selektionen unsichtbar - pHRuler->SetActive( sal_False ); - pVRuler->SetActive( sal_False ); + m_pHRuler->SetActive( sal_False ); + m_pVRuler->SetActive( sal_False ); } SfxViewShell::Deactivate(bMDIActivate); } @@ -140,12 +140,12 @@ void SwView::MarginChanged() void SwView::ExecFormatPaintbrush(SfxRequest& rReq) { - if(!pFormatClipboard) + if(!m_pFormatClipboard) return; - if( pFormatClipboard->HasContent() ) + if( m_pFormatClipboard->HasContent() ) { - pFormatClipboard->Erase(); + m_pFormatClipboard->Erase(); SwApplyTemplate aTemplate; GetEditWin().SetApplyTemplate(aTemplate); @@ -160,10 +160,10 @@ void SwView::ExecFormatPaintbrush(SfxRequest& rReq) SID_FORMATPAINTBRUSH)).GetValue()); } - pFormatClipboard->Copy( GetWrtShell(), GetPool(), bPersistentCopy ); + m_pFormatClipboard->Copy( GetWrtShell(), GetPool(), bPersistentCopy ); SwApplyTemplate aTemplate; - aTemplate.pFormatClipboard = pFormatClipboard; + aTemplate.m_pFormatClipboard = m_pFormatClipboard; GetEditWin().SetApplyTemplate(aTemplate); } GetViewFrame()->GetBindings().Invalidate(SID_FORMATPAINTBRUSH); @@ -171,14 +171,14 @@ void SwView::ExecFormatPaintbrush(SfxRequest& rReq) void SwView::StateFormatPaintbrush(SfxItemSet &rSet) { - if(!pFormatClipboard) + if(!m_pFormatClipboard) return; - bool bHasContent = pFormatClipboard && pFormatClipboard->HasContent(); + bool bHasContent = m_pFormatClipboard && m_pFormatClipboard->HasContent(); rSet.Put(SfxBoolItem(SID_FORMATPAINTBRUSH, bHasContent)); if(!bHasContent) { - if( !pFormatClipboard->CanCopyThisType( GetWrtShell().GetSelectionType() ) ) + if( !m_pFormatClipboard->CanCopyThisType( GetWrtShell().GetSelectionType() ) ) rSet.DisableItem( SID_FORMATPAINTBRUSH ); } } diff --git a/sw/source/ui/uiview/view2.cxx b/sw/source/ui/uiview/view2.cxx index d3165f89e9bc..e65b1427d191 100644 --- a/sw/source/ui/uiview/view2.cxx +++ b/sw/source/ui/uiview/view2.cxx @@ -181,7 +181,7 @@ static void lcl_SetAllTextToDefaultLanguage( SwWrtShell &rWrtSh, sal_uInt16 nWhi String SwView::GetPageStr( sal_uInt16 nPg, sal_uInt16 nLogPg, const String& rDisplay ) { - String aStr( aPageStr ); + String aStr( m_aPageStr ); if( rDisplay.Len() ) aStr += rDisplay; else @@ -481,7 +481,7 @@ void SwView::Execute(SfxRequest &rReq) switch( nSlot ) { case SID_CREATE_SW_DRAWVIEW: - pWrtShell->getIDocumentDrawModelAccess()->GetOrCreateDrawModel(); + m_pWrtShell->getIDocumentDrawModelAccess()->GetOrCreateDrawModel(); break; case FN_LINE_NUMBERING_DLG: @@ -523,7 +523,7 @@ void SwView::Execute(SfxRequest &rReq) if( pArgs && SFX_ITEM_SET == pArgs->GetItemState(nSlot, sal_False, &pItem )) { - IDocumentRedlineAccess* pIDRA = pWrtShell->getIDocumentRedlineAccess(); + IDocumentRedlineAccess* pIDRA = m_pWrtShell->getIDocumentRedlineAccess(); Sequence <sal_Int8> aPasswd = pIDRA->GetRedlinePassword(); if( aPasswd.getLength() ) { @@ -551,14 +551,14 @@ void SwView::Execute(SfxRequest &rReq) } sal_uInt16 nOn = ((const SfxBoolItem*)pItem)->GetValue() ? nsRedlineMode_t::REDLINE_ON : 0; - sal_uInt16 nMode = pWrtShell->GetRedlineMode(); - pWrtShell->SetRedlineModeAndCheckInsMode( (nMode & ~nsRedlineMode_t::REDLINE_ON) | nOn); + sal_uInt16 nMode = m_pWrtShell->GetRedlineMode(); + m_pWrtShell->SetRedlineModeAndCheckInsMode( (nMode & ~nsRedlineMode_t::REDLINE_ON) | nOn); } } break; case FN_REDLINE_PROTECT : { - IDocumentRedlineAccess* pIDRA = pWrtShell->getIDocumentRedlineAccess(); + IDocumentRedlineAccess* pIDRA = m_pWrtShell->getIDocumentRedlineAccess(); Sequence <sal_Int8> aPasswd = pIDRA->GetRedlinePassword(); if( pArgs && SFX_ITEM_SET == pArgs->GetItemState(nSlot, sal_False, &pItem ) && ((SfxBoolItem*)pItem)->GetValue() == ( aPasswd.getLength() != 0 ) ) @@ -593,7 +593,7 @@ void SwView::Execute(SfxRequest &rReq) nOn = 0; } sal_uInt16 nMode = pIDRA->GetRedlineMode(); - pWrtShell->SetRedlineModeAndCheckInsMode( (nMode & ~nsRedlineMode_t::REDLINE_ON) | nOn); + m_pWrtShell->SetRedlineModeAndCheckInsMode( (nMode & ~nsRedlineMode_t::REDLINE_ON) | nOn); rReq.AppendItem( SfxBoolItem( FN_REDLINE_PROTECT, ((nMode&nsRedlineMode_t::REDLINE_ON)==0) ) ); } else @@ -606,11 +606,11 @@ void SwView::Execute(SfxRequest &rReq) SFX_ITEM_SET == pArgs->GetItemState(nSlot, sal_False, &pItem)) { sal_uInt16 nMode = ( ~(nsRedlineMode_t::REDLINE_SHOW_INSERT | nsRedlineMode_t::REDLINE_SHOW_DELETE) - & pWrtShell->GetRedlineMode() ) | nsRedlineMode_t::REDLINE_SHOW_INSERT; + & m_pWrtShell->GetRedlineMode() ) | nsRedlineMode_t::REDLINE_SHOW_INSERT; if( ((const SfxBoolItem*)pItem)->GetValue() ) nMode |= nsRedlineMode_t::REDLINE_SHOW_DELETE; - pWrtShell->SetRedlineModeAndCheckInsMode( nMode ); + m_pWrtShell->SetRedlineModeAndCheckInsMode( nMode ); } break; case FN_MAILMERGE_SENDMAIL_CHILDWINDOW: @@ -624,8 +624,8 @@ void SwView::Execute(SfxRequest &rReq) // This ensures we work properly with FN_REDLINE_NEXT_CHANGE, which leaves the // point at the *end* of the redline and the mark at the start (so GetRedline // would return NULL if called on the point) - SwDoc *pDoc = pWrtShell->GetDoc(); - SwPaM *pCursor = pWrtShell->GetCrsr(); + SwDoc *pDoc = m_pWrtShell->GetDoc(); + SwPaM *pCursor = m_pWrtShell->GetCrsr(); sal_uInt16 nRedline = 0; const SwRedline *pRedline = pDoc->GetRedline(*pCursor->Start(), &nRedline); @@ -633,17 +633,17 @@ void SwView::Execute(SfxRequest &rReq) if (pRedline) { if (FN_REDLINE_ACCEPT_DIRECT == nSlot) - pWrtShell->AcceptRedline(nRedline); + m_pWrtShell->AcceptRedline(nRedline); else - pWrtShell->RejectRedline(nRedline); + m_pWrtShell->RejectRedline(nRedline); } } break; case FN_REDLINE_NEXT_CHANGE: { - const SwRedline *pCurrent = pWrtShell->GetCurrRedline(); - const SwRedline *pNext = pWrtShell->SelNextRedline(); + const SwRedline *pCurrent = m_pWrtShell->GetCurrRedline(); + const SwRedline *pNext = m_pWrtShell->SelNextRedline(); // FN_REDLINE_PREV_CHANGE leaves the selection point at the start of the redline. // In such cases, SelNextRedline (which starts searching from the selection point) @@ -652,18 +652,18 @@ void SwView::Execute(SfxRequest &rReq) // This behavior means that PREV_CHANGE followed by NEXT_CHANGE would not change // the current redline, so we detect it and select the next redline again. if (pCurrent && pCurrent == pNext) - pNext = pWrtShell->SelNextRedline(); + pNext = m_pWrtShell->SelNextRedline(); if (pNext) - pWrtShell->SetInSelect(); + m_pWrtShell->SetInSelect(); } break; case FN_REDLINE_PREV_CHANGE: { - const SwPaM *pCursor = pWrtShell->GetCrsr(); + const SwPaM *pCursor = m_pWrtShell->GetCrsr(); const SwPosition initialCursorStart = *pCursor->Start(); - const SwRedline *pPrev = pWrtShell->SelPrevRedline(); + const SwRedline *pPrev = m_pWrtShell->SelPrevRedline(); if (pPrev) { @@ -675,11 +675,11 @@ void SwView::Execute(SfxRequest &rReq) // This behavior means that NEXT_CHANGE followed by PREV_CHANGE would not change // the current redline, so we detect it and move to the previous redline again. if (initialCursorStart == *pPrev->Start()) - pPrev = pWrtShell->SelPrevRedline(); + pPrev = m_pWrtShell->SelPrevRedline(); } if (pPrev) - pWrtShell->SetInSelect(); + m_pWrtShell->SetInSelect(); } break; @@ -689,7 +689,7 @@ void SwView::Execute(SfxRequest &rReq) String sFileName, sFilterName; sal_Int16 nVersion = 0; bool bHasFileName = false; - pViewImpl->SetParam( 0 ); + m_pViewImpl->SetParam( 0 ); if( pArgs ) { @@ -703,11 +703,11 @@ void SwView::Execute(SfxRequest &rReq) if( SFX_ITEM_SET == pArgs->GetItemState( SID_VERSION, sal_False, &pItem )) { nVersion = ((const SfxInt16Item *)pItem)->GetValue(); - pViewImpl->SetParam( nVersion ); + m_pViewImpl->SetParam( nVersion ); } } - pViewImpl->InitRequest( rReq ); + m_pViewImpl->InitRequest( rReq ); long nFound = InsertDoc( nSlot, sFileName, sFilterName, nVersion ); if ( bHasFileName ) @@ -737,19 +737,19 @@ void SwView::Execute(SfxRequest &rReq) break; case FN_ESCAPE: { - if ( pWrtShell->HasDrawView() && pWrtShell->GetDrawView()->IsDragObj() ) + if ( m_pWrtShell->HasDrawView() && m_pWrtShell->GetDrawView()->IsDragObj() ) { - pWrtShell->BreakDrag(); - pWrtShell->EnterSelFrmMode(); + m_pWrtShell->BreakDrag(); + m_pWrtShell->EnterSelFrmMode(); } - else if ( pWrtShell->IsDrawCreate() ) + else if ( m_pWrtShell->IsDrawCreate() ) { GetDrawFuncPtr()->BreakCreate(); - AttrChangedNotify(pWrtShell); // ggf Shellwechsel... + AttrChangedNotify(m_pWrtShell); // ggf Shellwechsel... } - else if ( pWrtShell->HasSelection() || IsDrawMode() ) + else if ( m_pWrtShell->HasSelection() || IsDrawMode() ) { - SdrView *pSdrView = pWrtShell->HasDrawView() ? pWrtShell->GetDrawView() : 0; + SdrView *pSdrView = m_pWrtShell->HasDrawView() ? m_pWrtShell->GetDrawView() : 0; if(pSdrView && pSdrView->AreObjectsMarked() && pSdrView->GetHdlList().GetFocusHdl()) { @@ -762,12 +762,12 @@ void SwView::Execute(SfxRequest &rReq) LeaveDrawCreate(); Point aPt(LONG_MIN, LONG_MIN); //go out of the frame - pWrtShell->SelectObj(aPt, SW_LEAVE_FRAME); + m_pWrtShell->SelectObj(aPt, SW_LEAVE_FRAME); SfxBindings& rBind = GetViewFrame()->GetBindings(); rBind.Invalidate( SID_ATTR_SIZE ); } - pWrtShell->EnterStdMode(); - AttrChangedNotify(pWrtShell); // ggf Shellwechsel... + m_pWrtShell->EnterStdMode(); + AttrChangedNotify(m_pWrtShell); // ggf Shellwechsel... } } else if ( GetEditWin().GetApplyTemplate() ) @@ -782,13 +782,13 @@ void SwView::Execute(SfxRequest &rReq) { GetEditWin().SetChainMode( sal_False ); } - else if( pWrtShell->GetFlyFrmFmt() ) + else if( m_pWrtShell->GetFlyFrmFmt() ) { - const SwFrmFmt* pFmt = pWrtShell->GetFlyFrmFmt(); - if(pWrtShell->GotoFly( pFmt->GetName(), FLYCNTTYPE_FRM )) + const SwFrmFmt* pFmt = m_pWrtShell->GetFlyFrmFmt(); + if(m_pWrtShell->GotoFly( pFmt->GetName(), FLYCNTTYPE_FRM )) { - pWrtShell->HideCrsr(); - pWrtShell->EnterSelFrmMode(); + m_pWrtShell->HideCrsr(); + m_pWrtShell->EnterSelFrmMode(); } } else @@ -803,7 +803,7 @@ void SwView::Execute(SfxRequest &rReq) case SID_ATTR_BORDER_OUTER: case SID_ATTR_BORDER_SHADOW: if(pArgs) - pWrtShell->SetAttr(*pArgs); + m_pWrtShell->SetAttr(*pArgs); break; case SID_ATTR_PAGE: @@ -815,11 +815,11 @@ void SwView::Execute(SfxRequest &rReq) { if(pArgs) { - const sal_uInt16 nCurIdx = pWrtShell->GetCurPageDesc(); - SwPageDesc aPageDesc( pWrtShell->GetPageDesc( nCurIdx ) ); + const sal_uInt16 nCurIdx = m_pWrtShell->GetCurPageDesc(); + SwPageDesc aPageDesc( m_pWrtShell->GetPageDesc( nCurIdx ) ); ::ItemSetToPageDesc( *pArgs, aPageDesc ); // Den Descriptor der Core veraendern. - pWrtShell->ChgPageDesc( nCurIdx, aPageDesc ); + m_pWrtShell->ChgPageDesc( nCurIdx, aPageDesc ); } } break; @@ -844,40 +844,40 @@ void SwView::Execute(SfxRequest &rReq) break; case FN_UPDATE_CUR_TOX: { - const SwTOXBase* pBase = pWrtShell->GetCurTOX(); + const SwTOXBase* pBase = m_pWrtShell->GetCurTOX(); if(pBase) { - pWrtShell->StartAction(); + m_pWrtShell->StartAction(); if(TOX_INDEX == pBase->GetType()) - pWrtShell->ApplyAutoMark(); - pWrtShell->UpdateTableOf( *pBase ); - pWrtShell->EndAction(); + m_pWrtShell->ApplyAutoMark(); + m_pWrtShell->UpdateTableOf( *pBase ); + m_pWrtShell->EndAction(); } } break; case FN_UPDATE_TOX: { - pWrtShell->StartAction(); - pWrtShell->EnterStdMode(); - sal_Bool bOldCrsrInReadOnly = pWrtShell->IsReadOnlyAvailable(); - pWrtShell->SetReadOnlyAvailable( sal_True ); + m_pWrtShell->StartAction(); + m_pWrtShell->EnterStdMode(); + sal_Bool bOldCrsrInReadOnly = m_pWrtShell->IsReadOnlyAvailable(); + m_pWrtShell->SetReadOnlyAvailable( sal_True ); for( sal_uInt16 i = 0; i < 2; ++i ) { - sal_uInt16 nCount = pWrtShell->GetTOXCount(); + sal_uInt16 nCount = m_pWrtShell->GetTOXCount(); if( 1 == nCount ) ++i; - while( pWrtShell->GotoPrevTOXBase() ) + while( m_pWrtShell->GotoPrevTOXBase() ) ; // aufs erste Verzeichnis springen // falls wir nicht mehr in einem stehen, dann zum naechsten // springen. - const SwTOXBase* pBase = pWrtShell->GetCurTOX(); + const SwTOXBase* pBase = m_pWrtShell->GetCurTOX(); if( !pBase ) { - pWrtShell->GotoNextTOXBase(); - pBase = pWrtShell->GetCurTOX(); + m_pWrtShell->GotoNextTOXBase(); + pBase = m_pWrtShell->GetCurTOX(); } sal_Bool bAutoMarkApplied = sal_False; @@ -885,43 +885,43 @@ void SwView::Execute(SfxRequest &rReq) { if(TOX_INDEX == pBase->GetType() && !bAutoMarkApplied) { - pWrtShell->ApplyAutoMark(); + m_pWrtShell->ApplyAutoMark(); bAutoMarkApplied = sal_True; } // das pBase wird nur fuer die Schnittstelle // benoetigt. Muss mal umgetstellt werden!!! - pWrtShell->UpdateTableOf( *pBase ); + m_pWrtShell->UpdateTableOf( *pBase ); - if( pWrtShell->GotoNextTOXBase() ) - pBase = pWrtShell->GetCurTOX(); + if( m_pWrtShell->GotoNextTOXBase() ) + pBase = m_pWrtShell->GetCurTOX(); else pBase = 0; } } - pWrtShell->SetReadOnlyAvailable( bOldCrsrInReadOnly ); - pWrtShell->EndAction(); + m_pWrtShell->SetReadOnlyAvailable( bOldCrsrInReadOnly ); + m_pWrtShell->EndAction(); } break; case SID_ATTR_BRUSH: { if(pArgs && SFX_ITEM_SET == pArgs->GetItemState(RES_BACKGROUND, sal_False, &pItem)) { - const sal_uInt16 nCurIdx = pWrtShell->GetCurPageDesc(); - SwPageDesc aDesc( pWrtShell->GetPageDesc( nCurIdx )); + const sal_uInt16 nCurIdx = m_pWrtShell->GetCurPageDesc(); + SwPageDesc aDesc( m_pWrtShell->GetPageDesc( nCurIdx )); SwFrmFmt& rMaster = aDesc.GetMaster(); rMaster.SetFmtAttr(*pItem); - pWrtShell->ChgPageDesc( nCurIdx, aDesc); + m_pWrtShell->ChgPageDesc( nCurIdx, aDesc); } } break; case SID_CLEARHISTORY: { - pWrtShell->DelAllUndoObj(); + m_pWrtShell->DelAllUndoObj(); } break; case SID_UNDO: { - pShell->ExecuteSlot(rReq); + m_pShell->ExecuteSlot(rReq); } break; case FN_INSERT_CTRL: @@ -936,12 +936,12 @@ void SwView::Execute(SfxRequest &rReq) { sal_Bool bWeb = 0 != PTR_CAST(SwWebView, this); if(bWeb) - SwView::nWebInsertCtrlState = nValue; + SwView::m_nWebInsertCtrlState = nValue; else - SwView::nInsertCtrlState = nValue; + SwView::m_nInsertCtrlState = nValue; } break; - case FN_INSERT_OBJ_CTRL: SwView::nInsertObjectCtrlState = nValue ;break; + case FN_INSERT_OBJ_CTRL: SwView::m_nInsertObjectCtrlState = nValue ;break; } } @@ -962,7 +962,7 @@ void SwView::Execute(SfxRequest &rReq) SvxTabStopItem aDefTabs( 0, 0, SVX_TAB_ADJUST_DEFAULT, RES_PARATR_TABSTOP ); sal_uInt16 nTab = ((const SfxUInt16Item*)pItem)->GetValue(); MakeDefTabs( nTab, aDefTabs ); - pWrtShell->SetDefault( aDefTabs ); + m_pWrtShell->SetDefault( aDefTabs ); } } break; @@ -970,22 +970,22 @@ void SwView::Execute(SfxRequest &rReq) if(pArgs && SFX_ITEM_SET == pArgs->GetItemState(SID_ATTR_LANGUAGE, sal_False, &pItem)) { SvxLanguageItem aLang(((SvxLanguageItem*)pItem)->GetLanguage(), RES_CHRATR_LANGUAGE); - pWrtShell->SetDefault( aLang ); - lcl_SetAllTextToDefaultLanguage( *pWrtShell, RES_CHRATR_LANGUAGE ); + m_pWrtShell->SetDefault( aLang ); + lcl_SetAllTextToDefaultLanguage( *m_pWrtShell, RES_CHRATR_LANGUAGE ); } break; case SID_ATTR_CHAR_CTL_LANGUAGE: if(pArgs && SFX_ITEM_SET == pArgs->GetItemState(RES_CHRATR_CTL_LANGUAGE, sal_False, &pItem)) { - pWrtShell->SetDefault( *pItem ); - lcl_SetAllTextToDefaultLanguage( *pWrtShell, RES_CHRATR_CTL_LANGUAGE ); + m_pWrtShell->SetDefault( *pItem ); + lcl_SetAllTextToDefaultLanguage( *m_pWrtShell, RES_CHRATR_CTL_LANGUAGE ); } break; case SID_ATTR_CHAR_CJK_LANGUAGE: if(pArgs && SFX_ITEM_SET == pArgs->GetItemState(RES_CHRATR_CJK_LANGUAGE, sal_False, &pItem)) { - pWrtShell->SetDefault( *pItem ); - lcl_SetAllTextToDefaultLanguage( *pWrtShell, RES_CHRATR_CJK_LANGUAGE ); + m_pWrtShell->SetDefault( *pItem ); + lcl_SetAllTextToDefaultLanguage( *m_pWrtShell, RES_CHRATR_CJK_LANGUAGE ); } break; case FN_SCROLL_NEXT_PREV: @@ -1024,12 +1024,12 @@ void SwView::Execute(SfxRequest &rReq) if( pArgs && SFX_ITEM_SET == pArgs->GetItemState(nSlot, sal_False, &pItem )) bShow = ((const SfxBoolItem*)pItem)->GetValue(); - if((bShow && bInMailMerge) != GetViewFrame()->HasChildWindow(nSlot)) + if((bShow && m_bInMailMerge) != GetViewFrame()->HasChildWindow(nSlot)) GetViewFrame()->ToggleChildWindow(nSlot); //if fields have been successfully inserted call the "real" //mail merge dialog SwWrtShell &rSh = GetWrtShell(); - if(bInMailMerge && rSh.IsAnyDatabaseFieldInDoc()) + if(m_bInMailMerge && rSh.IsAnyDatabaseFieldInDoc()) { SwNewDBMgr* pNewDBMgr = rSh.GetNewDBMgr(); if (pNewDBMgr) @@ -1052,7 +1052,7 @@ void SwView::Execute(SfxRequest &rReq) pNewDBMgr->ExecuteFormLetter(rSh, aProperties, sal_True); } } - bInMailMerge &= bShow; + m_bInMailMerge &= bShow; GetViewFrame()->GetBindings().Invalidate(FN_INSERT_FIELD); } break; @@ -1093,7 +1093,7 @@ void SwView::Execute(SfxRequest &rReq) if( xDictionary.is() ) xDictionary->clear(); // put cursor to the start of the document - pWrtShell->SttDoc(); + m_pWrtShell->SttDoc(); } // no break; - but call spell/grammar dialog case FN_SPELL_GRAMMAR_DIALOG: @@ -1121,7 +1121,7 @@ void SwView::Execute(SfxRequest &rReq) case SID_ALIGN_ANY_VDEFAULT : { sal_uInt16 nAlias = 0; - if( nSelectionType & (nsSelectionType::SEL_DRW_TXT|nsSelectionType::SEL_TXT) ) + if( m_nSelectionType & (nsSelectionType::SEL_DRW_TXT|nsSelectionType::SEL_TXT) ) { switch( nSlot ) { @@ -1147,7 +1147,7 @@ void SwView::Execute(SfxRequest &rReq) } } //special handling for the draw shell - if(nAlias && (nSelectionType & (nsSelectionType::SEL_DRW))) + if(nAlias && (m_nSelectionType & (nsSelectionType::SEL_DRW))) { SfxAllEnumItem aEnumItem(SID_OBJECT_ALIGN, nAlias - SID_OBJECT_ALIGN_LEFT); GetViewFrame()->GetDispatcher()->Execute( @@ -1164,13 +1164,13 @@ void SwView::Execute(SfxRequest &rReq) //#i33307# restore editing position Point aCrsrPos; bool bSelectObj; - if(pViewImpl->GetRestorePosition(aCrsrPos, bSelectObj)) + if(m_pViewImpl->GetRestorePosition(aCrsrPos, bSelectObj)) { - pWrtShell->SwCrsrShell::SetCrsr( aCrsrPos, !bSelectObj ); + m_pWrtShell->SwCrsrShell::SetCrsr( aCrsrPos, !bSelectObj ); if( bSelectObj ) { - pWrtShell->SelectObj( aCrsrPos ); - pWrtShell->EnterSelFrmMode( &aCrsrPos ); + m_pWrtShell->SelectObj( aCrsrPos ); + m_pWrtShell->EnterSelFrmMode( &aCrsrPos ); } } } @@ -1238,9 +1238,9 @@ void SwView::StateStatusLine(SfxItemSet &rSet) GetPageStr( nPage, nLogPage, sDisplay) )); sal_uInt16 nCnt = GetWrtShell().GetPageCnt(); - if (nPageCnt != nCnt) // Basic benachrichtigen + if (m_nPageCnt != nCnt) // Basic benachrichtigen { - nPageCnt = nCnt; + m_nPageCnt = nCnt; SFX_APP()->NotifyEvent(SfxEventHint(SW_EVENT_PAGE_COUNT, SwDocShell::GetEventName(STR_SW_EVENT_PAGE_COUNT), GetViewFrame()->GetObjectShell()), sal_False); } } @@ -1325,7 +1325,7 @@ void SwView::StateStatusLine(SfxItemSet &rSet) SvxZoomSliderItem aZoomSliderItem( nCurrentZoom, MINZOOM, MAXZOOM ); aZoomSliderItem.AddSnappingPoint( 100 ); - if ( !pWrtShell->getIDocumentSettingAccess()->get(IDocumentSettingAccess::BROWSE_MODE) ) + if ( !m_pWrtShell->getIDocumentSettingAccess()->get(IDocumentSettingAccess::BROWSE_MODE) ) { const sal_uInt16 nColumns = pVOpt->GetViewLayoutColumns(); const bool bAutomaticViewLayout = 0 == nColumns; @@ -1335,8 +1335,8 @@ void SwView::StateStatusLine(SfxItemSet &rSet) // automatic mode: 1 Page, 2 Pages, 100% // n Columns mode: n Pages, 100% // n Columns book mode: nPages without gaps, 100% - const SwRect aPageRect( pWrtShell->GetAnyCurRect( RECT_PAGE_CALC ) ); - const SwRect aRootRect( pWrtShell->GetAnyCurRect( RECT_PAGES_AREA ) ); // width of columns + const SwRect aPageRect( m_pWrtShell->GetAnyCurRect( RECT_PAGE_CALC ) ); + const SwRect aRootRect( m_pWrtShell->GetAnyCurRect( RECT_PAGES_AREA ) ); // width of columns Size aPageSize( aPageRect.SSize() ); aPageSize.Width() += pMgr->HasNotes() && pMgr->ShowNotes() ? pMgr->GetSidebarWidth() + pMgr->GetSidebarBorderWidth() : @@ -1423,7 +1423,7 @@ void SwView::StateStatusLine(SfxItemSet &rSet) case TOX_HEADER_SECTION: case TOX_CONTENT_SECTION: { - const SwTOXBase* pTOX = pWrtShell->GetCurTOX(); + const SwTOXBase* pTOX = m_pWrtShell->GetCurTOX(); if( pTOX ) sStr = pTOX->GetTOXName(); else @@ -1590,7 +1590,7 @@ void SwView::ExecuteStatusLine(SfxRequest &rReq) else { const SwViewOption& rViewOptions = *rSh.GetViewOptions(); - SfxItemSet aCoreSet(pShell->GetPool(), SID_ATTR_ZOOM, SID_ATTR_ZOOM, SID_ATTR_VIEWLAYOUT, SID_ATTR_VIEWLAYOUT, 0 ); + SfxItemSet aCoreSet(m_pShell->GetPool(), SID_ATTR_ZOOM, SID_ATTR_ZOOM, SID_ATTR_VIEWLAYOUT, SID_ATTR_VIEWLAYOUT, 0 ); SvxZoomItem aZoom( (SvxZoomType)rViewOptions.GetZoomType(), rViewOptions.GetZoom() ); const bool bBrowseMode = rSh.GetViewOptions()->getBrowseMode(); @@ -1793,12 +1793,12 @@ void SwView::ExecuteStatusLine(SfxRequest &rReq) void SwView::InsFrmMode(sal_uInt16 nCols) { - if ( pWrtShell->HasWholeTabSelection() ) + if ( m_pWrtShell->HasWholeTabSelection() ) { - SwFlyFrmAttrMgr aMgr( sal_True, pWrtShell, FRMMGR_TYPE_TEXT ); + SwFlyFrmAttrMgr aMgr( sal_True, m_pWrtShell, FRMMGR_TYPE_TEXT ); const SwFrmFmt &rPageFmt = - pWrtShell->GetPageDesc(pWrtShell->GetCurPageDesc()).GetMaster(); + m_pWrtShell->GetPageDesc(m_pWrtShell->GetCurPageDesc()).GetMaster(); SwTwips lWidth = rPageFmt.GetFrmSize().GetWidth(); const SvxLRSpaceItem &rLR = rPageFmt.GetLRSpace(); lWidth -= rLR.GetLeft() + rLR.GetRight(); @@ -1842,9 +1842,9 @@ bool SwView::JumpToSwMark( const String& rMark ) // Damit in FrameSet auch gescrollt werden kann, muss die // entsprechende Shell auch das Focus-Flag gesetzt haben! - sal_Bool bHasShFocus = pWrtShell->HasShFcs(); + sal_Bool bHasShFocus = m_pWrtShell->HasShFcs(); if( !bHasShFocus ) - pWrtShell->ShGetFcs( sal_False ); + m_pWrtShell->ShGetFcs( sal_False ); const SwFmtINetFmt* pINet; String sCmp, sMark( INetURLObject::decode( rMark, INET_HEX_ESCAPE, @@ -1858,7 +1858,7 @@ bool SwView::JumpToSwMark( const String& rMark ) nPos = nLastPos; IDocumentMarkAccess::const_iterator_t ppMark; - IDocumentMarkAccess* const pMarkAccess = pWrtShell->getIDocumentMarkAccess(); + IDocumentMarkAccess* const pMarkAccess = m_pWrtShell->getIDocumentMarkAccess(); if( STRING_NOTFOUND != nPos ) sCmp = comphelper::string::remove(sMark.Copy(nPos + 1), ' '); @@ -1870,13 +1870,13 @@ bool SwView::JumpToSwMark( const String& rMark ) if( COMPARE_EQUAL == sCmp.CompareToAscii( pMarkToRegion ) ) { - pWrtShell->EnterStdMode(); - bRet = pWrtShell->GotoRegion( sName ); + m_pWrtShell->EnterStdMode(); + bRet = m_pWrtShell->GotoRegion( sName ); } else if( COMPARE_EQUAL == sCmp.CompareToAscii( pMarkToOutline ) ) { - pWrtShell->EnterStdMode(); - bRet = pWrtShell->GotoOutline( sName ); + m_pWrtShell->EnterStdMode(); + bRet = m_pWrtShell->GotoOutline( sName ); } else if( COMPARE_EQUAL == sCmp.CompareToAscii( pMarkToFrame ) ) eFlyType = FLYCNTTYPE_FRM; @@ -1886,13 +1886,13 @@ bool SwView::JumpToSwMark( const String& rMark ) eFlyType = FLYCNTTYPE_OLE; else if( COMPARE_EQUAL == sCmp.CompareToAscii( pMarkToTable ) ) { - pWrtShell->EnterStdMode(); - bRet = pWrtShell->GotoTable( sName ); + m_pWrtShell->EnterStdMode(); + bRet = m_pWrtShell->GotoTable( sName ); } else if( COMPARE_EQUAL == sCmp.CompareToAscii( pMarkToText ) ) { // Normale Textsuche - pWrtShell->EnterStdMode(); + m_pWrtShell->EnterStdMode(); SearchOptions aSearchOpt( SearchAlgorithms_ABSOLUTE, 0, @@ -1903,50 +1903,50 @@ bool SwView::JumpToSwMark( const String& rMark ) //todo/mba: assuming that notes shouldn't be searched sal_Bool bSearchInNotes = sal_False; - if( pWrtShell->SearchPattern( aSearchOpt, bSearchInNotes, DOCPOS_START, DOCPOS_END )) + if( m_pWrtShell->SearchPattern( aSearchOpt, bSearchInNotes, DOCPOS_START, DOCPOS_END )) { - pWrtShell->EnterStdMode(); // Selektion wieder aufheben + m_pWrtShell->EnterStdMode(); // Selektion wieder aufheben bRet = true; } } else if( pMarkAccess->getMarksEnd() != (ppMark = pMarkAccess->findMark(sMark)) ) - pWrtShell->GotoMark( ppMark->get(), sal_False, sal_True ), bRet = true; - else if( 0 != ( pINet = pWrtShell->FindINetAttr( sMark ) )) { - pWrtShell->addCurrentPosition(); - bRet = pWrtShell->GotoINetAttr( *pINet->GetTxtINetFmt() ); + m_pWrtShell->GotoMark( ppMark->get(), sal_False, sal_True ), bRet = true; + else if( 0 != ( pINet = m_pWrtShell->FindINetAttr( sMark ) )) { + m_pWrtShell->addCurrentPosition(); + bRet = m_pWrtShell->GotoINetAttr( *pINet->GetTxtINetFmt() ); } // fuer alle Arten von Flys - if( FLYCNTTYPE_ALL != eFlyType && pWrtShell->GotoFly( sName, eFlyType )) + if( FLYCNTTYPE_ALL != eFlyType && m_pWrtShell->GotoFly( sName, eFlyType )) { bRet = true; if( FLYCNTTYPE_FRM == eFlyType ) { // TextFrames: Cursor in den Frame setzen - pWrtShell->UnSelectFrm(); - pWrtShell->LeaveSelFrmMode(); + m_pWrtShell->UnSelectFrm(); + m_pWrtShell->LeaveSelFrmMode(); } else { - pWrtShell->HideCrsr(); - pWrtShell->EnterSelFrmMode(); + m_pWrtShell->HideCrsr(); + m_pWrtShell->EnterSelFrmMode(); } } } else if( pMarkAccess->getMarksEnd() != (ppMark = pMarkAccess->findMark(sMark))) - pWrtShell->GotoMark( ppMark->get(), sal_False, sal_True ), bRet = true; - else if( 0 != ( pINet = pWrtShell->FindINetAttr( sMark ) )) - bRet = pWrtShell->GotoINetAttr( *pINet->GetTxtINetFmt() ); + m_pWrtShell->GotoMark( ppMark->get(), sal_False, sal_True ), bRet = true; + else if( 0 != ( pINet = m_pWrtShell->FindINetAttr( sMark ) )) + bRet = m_pWrtShell->GotoINetAttr( *pINet->GetTxtINetFmt() ); // make selection visible later - if ( aVisArea.IsEmpty() ) - bMakeSelectionVisible = sal_True; + if ( m_aVisArea.IsEmpty() ) + m_bMakeSelectionVisible = sal_True; // ViewStatus wieder zurueck setzen SetCrsrAtTop( bSaveCT, bSaveCC ); if( !bHasShFocus ) - pWrtShell->ShLooseFcs(); + m_pWrtShell->ShLooseFcs(); } return bRet; } @@ -1978,8 +1978,8 @@ static sal_uInt16 lcl_PageDescWithHeader( const SwDoc& rDoc ) --------------------------------------------------------------------*/ void SwView::ExecuteInsertDoc( SfxRequest& rRequest, const SfxPoolItem* pItem ) { - pViewImpl->InitRequest( rRequest ); - pViewImpl->SetParam( pItem ? 1 : 0 ); + m_pViewImpl->InitRequest( rRequest ); + m_pViewImpl->SetParam( pItem ? 1 : 0 ); sal_uInt16 nSlot = rRequest.GetSlot(); if ( !pItem ) @@ -2031,7 +2031,7 @@ long SwView::InsertDoc( sal_uInt16 nSlotId, const String& rFileName, const Strin else { rtl::OUString sFactory = rtl::OUString::createFromAscii( pDocSh->GetFactory().GetShortName() ); - pViewImpl->StartDocumentInserter( sFactory, LINK( this, SwView, DialogClosedHdl ) ); + m_pViewImpl->StartDocumentInserter( sFactory, LINK( this, SwView, DialogClosedHdl ) ); return -1; } @@ -2087,7 +2087,7 @@ long SwView::InsertMedium( sal_uInt16 nSlotId, SfxMedium* pMedium, sal_Int16 nVe if( aRef.Is() && 1 < aRef->GetRefCount() ) // noch gueltige Ref? { SwReader* pRdr; - Reader *pRead = pDocSh->StartConvertFrom( *pMedium, &pRdr, pWrtShell ); + Reader *pRead = pDocSh->StartConvertFrom( *pMedium, &pRdr, m_pWrtShell ); if( pRead || (pMedium->GetFilter()->GetFilterFlags() & SFX_FILTER_STARONEFILTER) != 0 ) { @@ -2099,9 +2099,9 @@ long SwView::InsertMedium( sal_uInt16 nSlotId, SfxMedium* pMedium, sal_Int16 nVe { //Scope for SwWait-Object, to be able to execute slots //outside this scope. SwWait aWait( *GetDocShell(), sal_True ); - pWrtShell->StartAllAction(); - if ( pWrtShell->HasSelection() ) - pWrtShell->DelRight(); // Selektionen loeschen + m_pWrtShell->StartAllAction(); + if ( m_pWrtShell->HasSelection() ) + m_pWrtShell->DelRight(); // Selektionen loeschen if( pRead ) { nErrno = pRdr->Read( *pRead ); // und Dokument einfuegen @@ -2116,11 +2116,11 @@ long SwView::InsertMedium( sal_uInt16 nSlotId, SfxMedium* pMedium, sal_Int16 nVe } // ggfs. alle Verzeichnisse updaten: - if( pWrtShell->IsUpdateTOX() ) + if( m_pWrtShell->IsUpdateTOX() ) { SfxRequest aReq( FN_UPDATE_TOX, SFX_CALLMODE_SLOT, GetPool() ); Execute( aReq ); - pWrtShell->SetUpdateTOX( sal_False ); // wieder zurueck setzen + m_pWrtShell->SetUpdateTOX( sal_False ); // wieder zurueck setzen } if( pDoc ) @@ -2132,7 +2132,7 @@ long SwView::InsertMedium( sal_uInt16 nSlotId, SfxMedium* pMedium, sal_Int16 nVe } } - pWrtShell->EndAllAction(); + m_pWrtShell->EndAllAction(); if( nErrno ) { ErrorHandler::HandleError( nErrno ); @@ -2159,16 +2159,16 @@ long SwView::InsertMedium( sal_uInt16 nSlotId, SfxMedium* pMedium, sal_Int16 nVe if( nRet ) { SwWait aWait( *GetDocShell(), sal_True ); - pWrtShell->StartAllAction(); + m_pWrtShell->StartAllAction(); - pWrtShell->EnterStdMode(); // Selektionen loeschen + m_pWrtShell->EnterStdMode(); // Selektionen loeschen if( bCompare ) - nFound = pWrtShell->CompareDoc( *((SwDocShell*)&xDocSh)->GetDoc() ); + nFound = m_pWrtShell->CompareDoc( *((SwDocShell*)&xDocSh)->GetDoc() ); else - nFound = pWrtShell->MergeDoc( *((SwDocShell*)&xDocSh)->GetDoc() ); + nFound = m_pWrtShell->MergeDoc( *((SwDocShell*)&xDocSh)->GetDoc() ); - pWrtShell->EndAllAction(); + m_pWrtShell->EndAllAction(); if (!bCompare && !nFound) { @@ -2186,7 +2186,7 @@ long SwView::InsertMedium( sal_uInt16 nSlotId, SfxMedium* pMedium, sal_Int16 nVe void SwView::EnableMailMerge(sal_Bool bEnable ) { - bInMailMerge = bEnable; + m_bInMailMerge = bEnable; SfxBindings& rBind = GetViewFrame()->GetBindings(); rBind.Invalidate(FN_INSERT_FIELD_DATA_ONLY); rBind.Update(FN_INSERT_FIELD_DATA_ONLY); @@ -2400,28 +2400,28 @@ IMPL_LINK( SwView, DialogClosedHdl, sfx2::FileDialogHelper*, _pFileDlg ) { if ( ERRCODE_NONE == _pFileDlg->GetError() ) { - SfxMedium* pMed = pViewImpl->CreateMedium(); + SfxMedium* pMed = m_pViewImpl->CreateMedium(); if ( pMed ) { - sal_uInt16 nSlot = pViewImpl->GetRequest()->GetSlot(); - long nFound = InsertMedium( nSlot, pMed, pViewImpl->GetParam() ); + sal_uInt16 nSlot = m_pViewImpl->GetRequest()->GetSlot(); + long nFound = InsertMedium( nSlot, pMed, m_pViewImpl->GetParam() ); if ( SID_INSERTDOC == nSlot ) { - if ( pViewImpl->GetParam() == 0 ) + if ( m_pViewImpl->GetParam() == 0 ) { - pViewImpl->GetRequest()->SetReturnValue( SfxBoolItem( nSlot, nFound != -1 ) ); - pViewImpl->GetRequest()->Ignore(); + m_pViewImpl->GetRequest()->SetReturnValue( SfxBoolItem( nSlot, nFound != -1 ) ); + m_pViewImpl->GetRequest()->Ignore(); } else { - pViewImpl->GetRequest()->SetReturnValue( SfxBoolItem( nSlot, nFound != -1 ) ); - pViewImpl->GetRequest()->Done(); + m_pViewImpl->GetRequest()->SetReturnValue( SfxBoolItem( nSlot, nFound != -1 ) ); + m_pViewImpl->GetRequest()->Done(); } } else if ( SID_DOCUMENT_COMPARE == nSlot || SID_DOCUMENT_MERGE == nSlot ) { - pViewImpl->GetRequest()->SetReturnValue( SfxInt32Item( nSlot, nFound ) ); + m_pViewImpl->GetRequest()->SetReturnValue( SfxInt32Item( nSlot, nFound ) ); if ( nFound > 0 ) // Redline-Browser anzeigen { @@ -2442,8 +2442,8 @@ IMPL_LINK( SwView, DialogClosedHdl, sfx2::FileDialogHelper*, _pFileDlg ) void SwView::ExecuteScan( SfxRequest& rReq ) { - if (pViewImpl) - pViewImpl->ExecuteScan(rReq) ; + if (m_pViewImpl) + m_pViewImpl->ExecuteScan(rReq) ; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/ui/uiview/viewdlg.cxx b/sw/source/ui/uiview/viewdlg.cxx index 43b1caaa40c8..1c8fe6867c35 100644 --- a/sw/source/ui/uiview/viewdlg.cxx +++ b/sw/source/ui/uiview/viewdlg.cxx @@ -53,17 +53,17 @@ void SwView::ExecDlg(SfxRequest &rReq) if ( pItem ) { sal_uInt16 nValue = ((SfxUInt16Item *)pItem)->GetValue(); - sal_uInt16 nOldValue = pWrtShell->GetPageOffset(); + sal_uInt16 nOldValue = m_pWrtShell->GetPageOffset(); sal_uInt16 nPage, nLogPage; - pWrtShell->GetPageNum( nPage, nLogPage, - pWrtShell->IsCrsrVisible(), sal_False); + m_pWrtShell->GetPageNum( nPage, nLogPage, + m_pWrtShell->IsCrsrVisible(), sal_False); if(nValue != nOldValue || nValue != nLogPage) { if(!nOldValue) - pWrtShell->SetNewPageOffset( nValue ); + m_pWrtShell->SetNewPageOffset( nValue ); else - pWrtShell->SetPageOffset( nValue ); + m_pWrtShell->SetPageOffset( nValue ); } } } diff --git a/sw/source/ui/uiview/viewdlg2.cxx b/sw/source/ui/uiview/viewdlg2.cxx index 3c6acb5ff3a4..136da959671e 100644 --- a/sw/source/ui/uiview/viewdlg2.cxx +++ b/sw/source/ui/uiview/viewdlg2.cxx @@ -73,7 +73,7 @@ void SwView::ExecDlgExt(SfxRequest &rReq) SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create(); OSL_ENSURE(pFact, "Dialogdiet fail!"); AbstractInsFootNoteDlg* pDlg = pFact->CreateInsFootNoteDlg( - pMDI, *pWrtShell, sal_True); + pMDI, *m_pWrtShell, sal_True); OSL_ENSURE(pDlg, "Dialogdiet fail!"); pDlg->SetHelpId(GetStaticInterface()->GetSlot(FN_EDIT_FOOTNOTE)->GetCommand()); diff --git a/sw/source/ui/uiview/viewdraw.cxx b/sw/source/ui/uiview/viewdraw.cxx index 87b66bc9d20b..d65846cfb794 100644 --- a/sw/source/ui/uiview/viewdraw.cxx +++ b/sw/source/ui/uiview/viewdraw.cxx @@ -79,7 +79,7 @@ void SwView::ExecDraw(SfxRequest& rReq) const SfxPoolItem* pItem; const SfxAllEnumItem* pEItem = 0; const SfxStringItem* pStringItem = 0; - SdrView *pSdrView = pWrtShell->GetDrawView(); + SdrView *pSdrView = m_pWrtShell->GetDrawView(); sal_Bool bDeselect = sal_False; sal_uInt16 nSlotId = rReq.GetSlot(); @@ -109,7 +109,7 @@ void SwView::ExecDraw(SfxRequest& rReq) case SVX_SNAP_DRAW_CAPTION_VERTICAL: nSlotId = SID_DRAW_CAPTION_VERTICAL; break; } - if (nSlotId == SID_OBJECT_SELECT && nFormSfxId == nSlotId) + if (nSlotId == SID_OBJECT_SELECT && m_nFormSfxId == nSlotId) { bDeselect = sal_True; } @@ -119,7 +119,7 @@ void SwView::ExecDraw(SfxRequest& rReq) if( pIdentifierItem ) { sal_uInt16 nNewId = pIdentifierItem->GetValue(); - if (nNewId == nFormSfxId) + if (nNewId == m_nFormSfxId) { bDeselect = sal_True; GetViewFrame()->GetDispatcher()->Execute(SID_FM_LEAVE_CREATE); // Button soll rauspoppen @@ -140,8 +140,8 @@ void SwView::ExecDraw(SfxRequest& rReq) if ( pObj ) { - Size aDocSize(pWrtShell->GetDocSize()); - const SwRect& rVisArea = pWrtShell->VisArea(); + Size aDocSize(m_pWrtShell->GetDocSize()); + const SwRect& rVisArea = m_pWrtShell->VisArea(); Point aStartPos = rVisArea.Center(); if(rVisArea.Width() > aDocSize.Width()) aStartPos.X() = aDocSize.Width() / 2 + rVisArea.Left(); @@ -157,23 +157,23 @@ void SwView::ExecDraw(SfxRequest& rReq) } // TODO: unmark all other - pWrtShell->EnterStdMode(); - pWrtShell->SwFEShell::InsertDrawObj( *pObj, aStartPos ); + m_pWrtShell->EnterStdMode(); + m_pWrtShell->SwFEShell::InsertDrawObj( *pObj, aStartPos ); } } } } else if ( nSlotId == SID_FONTWORK_GALLERY_FLOATER ) { - Window* pWin = &( pWrtShell->GetView().GetViewFrame()->GetWindow() ); + Window* pWin = &( m_pWrtShell->GetView().GetViewFrame()->GetWindow() ); if ( pWin ) pWin->EnterWait(); - if( !pWrtShell->HasDrawView() ) - pWrtShell->MakeDrawView(); + if( !m_pWrtShell->HasDrawView() ) + m_pWrtShell->MakeDrawView(); - pSdrView = pWrtShell->GetDrawView(); + pSdrView = m_pWrtShell->GetDrawView(); if ( pSdrView ) { SdrObject* pObj = NULL; @@ -182,8 +182,8 @@ void SwView::ExecDraw(SfxRequest& rReq) aDlg.Execute(); if ( pObj ) { - Size aDocSize( pWrtShell->GetDocSize() ); - const SwRect& rVisArea = pWrtShell->VisArea(); + Size aDocSize( m_pWrtShell->GetDocSize() ); + const SwRect& rVisArea = m_pWrtShell->VisArea(); Point aPos( rVisArea.Center() ); Size aSize; Size aPrefSize( pObj->GetSnapRect().GetSize() ); @@ -204,8 +204,8 @@ void SwView::ExecDraw(SfxRequest& rReq) else aSize = Size( 2835, 2835 ); - pWrtShell->EnterStdMode(); - pWrtShell->SwFEShell::InsertDrawObj( *pObj, aPos ); + m_pWrtShell->EnterStdMode(); + m_pWrtShell->SwFEShell::InsertDrawObj( *pObj, aPos ); rReq.Ignore (); } } @@ -230,8 +230,8 @@ void SwView::ExecDraw(SfxRequest& rReq) } //deselect if same shape is selected again (but different custom shapes do have same slot id) - if ( bDeselect || (nSlotId == nDrawSfxId && - (!pStringItem || (pStringItem->GetValue() == sDrawCustom)) + if ( bDeselect || (nSlotId == m_nDrawSfxId && + (!pStringItem || (pStringItem->GetValue() == m_sDrawCustom)) && (nSlotId != SID_DRAW_CS_ID) ) ) { if (GetDrawFuncPtr()) @@ -240,20 +240,20 @@ void SwView::ExecDraw(SfxRequest& rReq) SetDrawFuncPtr(NULL); } - if (pWrtShell->IsObjSelected() && !pWrtShell->IsSelFrmMode()) - pWrtShell->EnterSelFrmMode(NULL); + if (m_pWrtShell->IsObjSelected() && !m_pWrtShell->IsSelFrmMode()) + m_pWrtShell->EnterSelFrmMode(NULL); LeaveDrawCreate(); GetViewFrame()->GetBindings().Invalidate(SID_INSERT_DRAW); - AttrChangedNotify(pWrtShell); + AttrChangedNotify(m_pWrtShell); return; } LeaveDrawCreate(); - if (pWrtShell->IsFrmSelected()) - pWrtShell->EnterStdMode(); // wegen Bug #45639 + if (m_pWrtShell->IsFrmSelected()) + m_pWrtShell->EnterStdMode(); // wegen Bug #45639 SwDrawBase* pFuncPtr = NULL; @@ -261,9 +261,9 @@ void SwView::ExecDraw(SfxRequest& rReq) { case SID_OBJECT_SELECT: case SID_DRAW_SELECT: - pFuncPtr = new DrawSelection(pWrtShell, pEditWin, this); - nDrawSfxId = nFormSfxId = SID_OBJECT_SELECT; - sDrawCustom.Erase(); + pFuncPtr = new DrawSelection(m_pWrtShell, m_pEditWin, this); + m_nDrawSfxId = m_nFormSfxId = SID_OBJECT_SELECT; + m_sDrawCustom.Erase(); break; case SID_DRAW_LINE: @@ -274,25 +274,25 @@ void SwView::ExecDraw(SfxRequest& rReq) case SID_DRAW_TEXT_MARQUEE: case SID_DRAW_CAPTION: case SID_DRAW_CAPTION_VERTICAL: - pFuncPtr = new ConstRectangle(pWrtShell, pEditWin, this); - nDrawSfxId = nSlotId; - sDrawCustom.Erase(); + pFuncPtr = new ConstRectangle(m_pWrtShell, m_pEditWin, this); + m_nDrawSfxId = nSlotId; + m_sDrawCustom.Erase(); break; case SID_DRAW_POLYGON_NOFILL: case SID_DRAW_BEZIER_NOFILL: case SID_DRAW_FREELINE_NOFILL: - pFuncPtr = new ConstPolygon(pWrtShell, pEditWin, this); - nDrawSfxId = nSlotId; - sDrawCustom.Erase(); + pFuncPtr = new ConstPolygon(m_pWrtShell, m_pEditWin, this); + m_nDrawSfxId = nSlotId; + m_sDrawCustom.Erase(); break; case SID_DRAW_ARC: case SID_DRAW_PIE: case SID_DRAW_CIRCLECUT: - pFuncPtr = new ConstArc(pWrtShell, pEditWin, this); - nDrawSfxId = nSlotId; - sDrawCustom.Erase(); + pFuncPtr = new ConstArc(m_pWrtShell, m_pEditWin, this); + m_nDrawSfxId = nSlotId; + m_sDrawCustom.Erase(); break; case SID_FM_CREATE_CONTROL: @@ -300,8 +300,8 @@ void SwView::ExecDraw(SfxRequest& rReq) SFX_REQUEST_ARG( rReq, pIdentifierItem, SfxUInt16Item, SID_FM_CONTROL_IDENTIFIER, sal_False ); if( pIdentifierItem ) nSlotId = pIdentifierItem->GetValue(); - pFuncPtr = new ConstFormControl(pWrtShell, pEditWin, this); - nFormSfxId = nSlotId; + pFuncPtr = new ConstFormControl(m_pWrtShell, m_pEditWin, this); + m_nFormSfxId = nSlotId; } break; @@ -313,14 +313,14 @@ void SwView::ExecDraw(SfxRequest& rReq) case SID_DRAWTBX_CS_STAR : case SID_DRAW_CS_ID : { - pFuncPtr = new ConstCustomShape(pWrtShell, pEditWin, this, rReq ); - nDrawSfxId = nSlotId; + pFuncPtr = new ConstCustomShape(m_pWrtShell, m_pEditWin, this, rReq ); + m_nDrawSfxId = nSlotId; if ( nSlotId != SID_DRAW_CS_ID ) { if ( pStringItem ) { - sDrawCustom = pStringItem->GetValue(); - aCurrShapeEnumCommand[ nSlotId - SID_DRAWTBX_CS_BASIC ] = sDrawCustom; + m_sDrawCustom = pStringItem->GetValue(); + m_aCurrShapeEnumCommand[ nSlotId - SID_DRAWTBX_CS_BASIC ] = m_sDrawCustom; SfxBindings& rBind = GetViewFrame()->GetBindings(); rBind.Invalidate( nSlotId ); rBind.Update( nSlotId ); @@ -352,15 +352,15 @@ void SwView::ExecDraw(SfxRequest& rReq) } SetDrawFuncPtr(pFuncPtr); - AttrChangedNotify(pWrtShell); + AttrChangedNotify(m_pWrtShell); pFuncPtr->Activate(nSlotId); NoRotate(); if(rReq.GetModifier() == KEY_MOD1) { - if(SID_OBJECT_SELECT == nDrawSfxId ) + if(SID_OBJECT_SELECT == m_nDrawSfxId ) { - pWrtShell->GotoObj(sal_True); + m_pWrtShell->GotoObj(sal_True); } else { @@ -368,8 +368,8 @@ void SwView::ExecDraw(SfxRequest& rReq) pFuncPtr->Deactivate(); SetDrawFuncPtr(NULL); LeaveDrawCreate(); - pWrtShell->EnterStdMode(); - SdrView *pTmpSdrView = pWrtShell->GetDrawView(); + m_pWrtShell->EnterStdMode(); + SdrView *pTmpSdrView = m_pWrtShell->GetDrawView(); const SdrMarkList& rMarkList = pTmpSdrView->GetMarkedObjectList(); if(rMarkList.GetMarkCount() == 1 && (SID_DRAW_TEXT == nSlotId || SID_DRAW_TEXT_VERTICAL == nSlotId || @@ -384,14 +384,14 @@ void SwView::ExecDraw(SfxRequest& rReq) } else { - if (pWrtShell->IsObjSelected() && !pWrtShell->IsSelFrmMode()) - pWrtShell->EnterSelFrmMode(NULL); + if (m_pWrtShell->IsObjSelected() && !m_pWrtShell->IsSelFrmMode()) + m_pWrtShell->EnterSelFrmMode(NULL); } if(bEndTextEdit && pSdrView && pSdrView->IsTextEdit()) pSdrView->SdrEndTextEdit( sal_True ); - AttrChangedNotify(pWrtShell); + AttrChangedNotify(m_pWrtShell); } /*-------------------------------------------------------------------- @@ -401,7 +401,7 @@ void SwView::ExitDraw() { NoRotate(); - if(pShell) + if(m_pShell) { // the shell may be invalid at close/reload/SwitchToViewShell SfxDispatcher* pDispatch = GetViewFrame()->GetDispatcher(); @@ -411,16 +411,16 @@ void SwView::ExitDraw() { pTest = pDispatch->GetShell(nIdx++); } - while( pTest && pTest != this && pTest != pShell); - if(pTest == pShell && + while( pTest && pTest != this && pTest != m_pShell); + if(pTest == m_pShell && // don't call LeaveSelFrmMode() etc. for the below, // because objects may still be selected: - !pShell->ISA(SwDrawBaseShell) && - !pShell->ISA(SwBezierShell) && - !pShell->ISA(svx::ExtrusionBar) && - !pShell->ISA(svx::FontworkBar)) + !m_pShell->ISA(SwDrawBaseShell) && + !m_pShell->ISA(SwBezierShell) && + !m_pShell->ISA(svx::ExtrusionBar) && + !m_pShell->ISA(svx::FontworkBar)) { - SdrView *pSdrView = pWrtShell->GetDrawView(); + SdrView *pSdrView = m_pWrtShell->GetDrawView(); if (pSdrView && pSdrView->IsGroupEntered()) { @@ -431,8 +431,8 @@ void SwView::ExitDraw() if (GetDrawFuncPtr()) { - if (pWrtShell->IsSelFrmMode()) - pWrtShell->LeaveSelFrmMode(); + if (m_pWrtShell->IsSelFrmMode()) + m_pWrtShell->LeaveSelFrmMode(); GetDrawFuncPtr()->Deactivate(); SetDrawFuncPtr(NULL); @@ -452,7 +452,7 @@ void SwView::NoRotate() { if (IsDrawRotate()) { - pWrtShell->SetDragMode(SDRDRAG_MOVE); + m_pWrtShell->SetDragMode(SDRDRAG_MOVE); FlipDrawRotate(); const SfxBoolItem aTmp( SID_OBJECT_ROTATE, sal_False ); @@ -485,9 +485,9 @@ sal_Bool SwView::EnterDrawTextMode(const Point& aDocPos) ( pObj->ISA(SwDrawVirtObj) && ((SwDrawVirtObj*)pObj)->GetReferencedObj().ISA(SdrTextObj) ) ) && - !pWrtShell->IsSelObjProtected(FLYPROTECT_CONTENT)) + !m_pWrtShell->IsSelObjProtected(FLYPROTECT_CONTENT)) { - bReturn = BeginTextEdit( pObj, pPV, pEditWin, sal_False ); + bReturn = BeginTextEdit( pObj, pPV, m_pEditWin, sal_False ); } pSdrView->SetHitTolerancePixel( nOld ); @@ -534,8 +534,8 @@ sal_Bool SwView::BeginTextEdit(SdrObject* pObj, SdrPageView* pPV, Window* pWin, pOutliner->SetDefaultLanguage(((const SvxLanguageItem&)rItem).GetLanguage()); if( bIsNewObj ) - pOutliner->SetVertical( SID_DRAW_TEXT_VERTICAL == nDrawSfxId || - SID_DRAW_CAPTION_VERTICAL == nDrawSfxId ); + pOutliner->SetVertical( SID_DRAW_TEXT_VERTICAL == m_nDrawSfxId || + SID_DRAW_CAPTION_VERTICAL == m_nDrawSfxId ); // set default horizontal text direction at outliner EEHorizontalTextDirection aDefHoriTextDir = @@ -629,14 +629,14 @@ bool SwView::IsFormMode() const void SwView::SetDrawFuncPtr(SwDrawBase* pFuncPtr) { - delete pDrawActual; - pDrawActual = pFuncPtr; + delete m_pDrawActual; + m_pDrawActual = pFuncPtr; } void SwView::SetSelDrawSlot() { - nDrawSfxId = SID_OBJECT_SELECT; - sDrawCustom.Erase(); + m_nDrawSfxId = SID_OBJECT_SELECT; + m_sDrawCustom.Erase(); } bool SwView::AreOnlyFormsSelected() const @@ -720,7 +720,7 @@ IMPL_LINK(SwView, OnlineSpellCallback, SpellCallbackInfo*, pInfo) sal_Bool SwView::ExecDrwTxtSpellPopup(const Point& rPt) { sal_Bool bRet = sal_False; - SdrView *pSdrView = pWrtShell->GetDrawView(); + SdrView *pSdrView = m_pWrtShell->GetDrawView(); OutlinerView* pOLV = pSdrView->GetTextEditOutlinerView(); Point aPos( GetEditWin().LogicToPixel( rPt ) ); @@ -735,7 +735,7 @@ sal_Bool SwView::ExecDrwTxtSpellPopup(const Point& rPt) sal_Bool SwView::IsDrawTextHyphenate() { - SdrView *pSdrView = pWrtShell->GetDrawView(); + SdrView *pSdrView = m_pWrtShell->GetDrawView(); sal_Bool bHyphenate = sal_False; SfxItemSet aNewAttr( pSdrView->GetModel()->GetItemPool(), @@ -750,7 +750,7 @@ sal_Bool SwView::IsDrawTextHyphenate() void SwView::HyphenateDrawText() { - SdrView *pSdrView = pWrtShell->GetDrawView(); + SdrView *pSdrView = m_pWrtShell->GetDrawView(); sal_Bool bHyphenate = IsDrawTextHyphenate(); SfxItemSet aSet( GetPool(), EE_PARA_HYPHENATE, EE_PARA_HYPHENATE ); diff --git a/sw/source/ui/uiview/viewling.cxx b/sw/source/ui/uiview/viewling.cxx index af559acb2025..b30175c5311d 100644 --- a/sw/source/ui/uiview/viewling.cxx +++ b/sw/source/ui/uiview/viewling.cxx @@ -171,21 +171,21 @@ void SwView::ExecLingu(SfxRequest &rReq) // disallow formatting, updating the view, ... while // converting the document. (saves time) // Also remember the current view and cursor position for later - pWrtShell->StartAction(); + m_pWrtShell->StartAction(); // remember cursor position data for later restoration of the cursor - const SwPosition *pPoint = pWrtShell->GetCrsr()->GetPoint(); + const SwPosition *pPoint = m_pWrtShell->GetCrsr()->GetPoint(); sal_Bool bRestoreCursor = pPoint->nNode.GetNode().IsTxtNode(); const SwNodeIndex aPointNodeIndex( pPoint->nNode ); xub_StrLen nPointIndex = pPoint->nContent.GetIndex(); // since this conversion is not interactive the whole converted // document should be undone in a single undo step. - pWrtShell->StartUndo( UNDO_OVERWRITE ); + m_pWrtShell->StartUndo( UNDO_OVERWRITE ); StartTextConversion( nSourceLang, nTargetLang, &aTargetFont, nOptions, sal_False ); - pWrtShell->EndUndo( UNDO_OVERWRITE ); + m_pWrtShell->EndUndo( UNDO_OVERWRITE ); if (bRestoreCursor) { @@ -196,11 +196,11 @@ void SwView::ExecLingu(SfxRequest &rReq) if (!pTxtNode || pTxtNode->GetTxt().getLength() < nPointIndex) nPointIndex = 0; // restore cursor to its original position - pWrtShell->GetCrsr()->GetPoint()->nContent.Assign( pTxtNode, nPointIndex ); + m_pWrtShell->GetCrsr()->GetPoint()->nContent.Assign( pTxtNode, nPointIndex ); } // enable all, restore view and cursor position - pWrtShell->EndAction(); + m_pWrtShell->EndAction(); } } Reference< lang::XComponent > xComponent( xDialog, UNO_QUERY ); @@ -237,18 +237,18 @@ void SwView::StartTextConversion( SpellKontext(sal_True); - const SwViewOption* pVOpt = pWrtShell->GetViewOptions(); + const SwViewOption* pVOpt = m_pWrtShell->GetViewOptions(); const sal_Bool bOldIdle = pVOpt->IsIdle(); pVOpt->SetIdle( sal_False ); - sal_Bool bOldIns = pWrtShell->IsInsMode(); - pWrtShell->SetInsMode( sal_True ); + sal_Bool bOldIns = m_pWrtShell->IsInsMode(); + m_pWrtShell->SetInsMode( sal_True ); - sal_Bool bSelection = ((SwCrsrShell*)pWrtShell)->HasSelection() || - pWrtShell->GetCrsr() != pWrtShell->GetCrsr()->GetNext(); + sal_Bool bSelection = ((SwCrsrShell*)m_pWrtShell)->HasSelection() || + m_pWrtShell->GetCrsr() != m_pWrtShell->GetCrsr()->GetNext(); - sal_Bool bStart = bSelection || pWrtShell->IsStartOfDoc(); - sal_Bool bOther = !bSelection && !(pWrtShell->GetFrmType(0,sal_True) & FRMTYPE_BODY); + sal_Bool bStart = bSelection || m_pWrtShell->IsStartOfDoc(); + sal_Bool bOther = !bSelection && !(m_pWrtShell->GetFrmType(0,sal_True) & FRMTYPE_BODY); { const uno::Reference< uno::XComponentContext > xContext( @@ -259,7 +259,7 @@ void SwView::StartTextConversion( aWrap.Convert(); } - pWrtShell->SetInsMode( bOldIns ); + m_pWrtShell->SetInsMode( bOldIns ); pVOpt->SetIdle( bOldIdle ); SpellKontext(sal_False); } @@ -323,7 +323,7 @@ void SwView::SpellStart( SvxSpellArea eWhich, default: OSL_ENSURE( !this, "SpellStart with unknown Area" ); } - pWrtShell->SpellStart( eStart, eEnde, eCurr, pConvArgs ); + m_pWrtShell->SpellStart( eStart, eEnde, eCurr, pConvArgs ); } /*-------------------------------------------------------------------- @@ -337,16 +337,16 @@ void SwView::SpellError(LanguageType eLang) #endif sal_uInt16 nPend = 0; - if ( pWrtShell->ActionPend() ) + if ( m_pWrtShell->ActionPend() ) { - pWrtShell->Push(); - pWrtShell->ClearMark(); + m_pWrtShell->Push(); + m_pWrtShell->ClearMark(); do { - pWrtShell->EndAction(); + m_pWrtShell->EndAction(); ++nPend; } - while( pWrtShell->ActionPend() ); + while( m_pWrtShell->ActionPend() ); } String aErr(SvtLanguageTable::GetLanguageString( eLang ) ); @@ -377,8 +377,8 @@ void SwView::SpellError(LanguageType eLang) if ( nPend ) { while( nPend-- ) - pWrtShell->StartAction(); - pWrtShell->Combine(); + m_pWrtShell->StartAction(); + m_pWrtShell->Combine(); } #if OSL_DEBUG_LEVEL > 1 if( !bFocus ) @@ -392,9 +392,9 @@ void SwView::SpellError(LanguageType eLang) --------------------------------------------------------------------*/ void SwView::SpellEnd( SwConversionArgs *pConvArgs ) { - pWrtShell->SpellEnd( pConvArgs ); - if( pWrtShell->IsExtMode() ) - pWrtShell->SetMark(); + m_pWrtShell->SpellEnd( pConvArgs ); + if( m_pWrtShell->IsExtMode() ) + m_pWrtShell->SetMark(); } void SwView::HyphStart( SvxSpellArea eWhich ) @@ -402,16 +402,16 @@ void SwView::HyphStart( SvxSpellArea eWhich ) switch ( eWhich ) { case SVX_SPELL_BODY: - pWrtShell->HyphStart( DOCPOS_START, DOCPOS_END ); + m_pWrtShell->HyphStart( DOCPOS_START, DOCPOS_END ); break; case SVX_SPELL_BODY_END: - pWrtShell->HyphStart( DOCPOS_CURR, DOCPOS_END ); + m_pWrtShell->HyphStart( DOCPOS_CURR, DOCPOS_END ); break; case SVX_SPELL_BODY_START: - pWrtShell->HyphStart( DOCPOS_START, DOCPOS_CURR ); + m_pWrtShell->HyphStart( DOCPOS_START, DOCPOS_CURR ); break; case SVX_SPELL_OTHER: - pWrtShell->HyphStart( DOCPOS_OTHERSTART, DOCPOS_OTHEREND ); + m_pWrtShell->HyphStart( DOCPOS_OTHERSTART, DOCPOS_OTHEREND ); break; default: OSL_ENSURE( !this, "HyphStart with unknown Area" ); @@ -431,7 +431,7 @@ void SwView::HyphenateDocument() return; } - SfxErrorContext aContext( ERRCTX_SVX_LINGU_HYPHENATION, aEmptyStr, pEditWin, + SfxErrorContext aContext( ERRCTX_SVX_LINGU_HYPHENATION, aEmptyStr, m_pEditWin, RID_SVXERRCTX, &DIALOG_MGR() ); Reference< XHyphenator > xHyph( ::GetHyphenator() ); @@ -441,30 +441,30 @@ void SwView::HyphenateDocument() return; } - if (pWrtShell->GetSelectionType() & (nsSelectionType::SEL_DRW_TXT|nsSelectionType::SEL_DRW)) + if (m_pWrtShell->GetSelectionType() & (nsSelectionType::SEL_DRW_TXT|nsSelectionType::SEL_DRW)) { // Silbentrennung in einem Draw-Objekt HyphenateDrawText(); } else { - SwViewOption* pVOpt = (SwViewOption*)pWrtShell->GetViewOptions(); + SwViewOption* pVOpt = (SwViewOption*)m_pWrtShell->GetViewOptions(); sal_Bool bOldIdle = pVOpt->IsIdle(); pVOpt->SetIdle( sal_False ); Reference< beans::XPropertySet > xProp( ::GetLinguPropertySet() ); - pWrtShell->StartUndo(UNDO_INSATTR); // spaeter gueltig + m_pWrtShell->StartUndo(UNDO_INSATTR); // spaeter gueltig sal_Bool bHyphSpecial = xProp.is() ? *(sal_Bool*)xProp->getPropertyValue( UPN_IS_HYPH_SPECIAL ).getValue() : sal_False; - sal_Bool bSelection = ((SwCrsrShell*)pWrtShell)->HasSelection() || - pWrtShell->GetCrsr() != pWrtShell->GetCrsr()->GetNext(); - sal_Bool bOther = pWrtShell->HasOtherCnt() && bHyphSpecial && !bSelection; - sal_Bool bStart = bSelection || ( !bOther && pWrtShell->IsStartOfDoc() ); + sal_Bool bSelection = ((SwCrsrShell*)m_pWrtShell)->HasSelection() || + m_pWrtShell->GetCrsr() != m_pWrtShell->GetCrsr()->GetNext(); + sal_Bool bOther = m_pWrtShell->HasOtherCnt() && bHyphSpecial && !bSelection; + sal_Bool bStart = bSelection || ( !bOther && m_pWrtShell->IsStartOfDoc() ); bool bStop = false; - if( !bOther && !(pWrtShell->GetFrmType(0,sal_True) & FRMTYPE_BODY) && !bSelection ) + if( !bOther && !(m_pWrtShell->GetFrmType(0,sal_True) & FRMTYPE_BODY) && !bSelection ) // kein Sonderbereich eingeschaltet { // Ich will auch in Sonderbereichen trennen @@ -487,7 +487,7 @@ void SwView::HyphenateDocument() { SwHyphWrapper aWrap( this, xHyph, bStart, bOther, bSelection ); aWrap.SpellDocument(); - pWrtShell->EndUndo(UNDO_INSATTR); + m_pWrtShell->EndUndo(UNDO_INSATTR); } pVOpt->SetIdle( bOldIdle ); } @@ -498,30 +498,30 @@ bool SwView::IsValidSelectionForThesaurus() const // must not be a multi-selection, and if it is a selection it needs // to be within a single paragraph - const bool bMultiSel = pWrtShell->GetCrsr() != pWrtShell->GetCrsr()->GetNext(); - const sal_Bool bSelection = ((SwCrsrShell*)pWrtShell)->HasSelection(); - return !bMultiSel && (!bSelection || pWrtShell->IsSelOnePara() ); + const bool bMultiSel = m_pWrtShell->GetCrsr() != m_pWrtShell->GetCrsr()->GetNext(); + const sal_Bool bSelection = ((SwCrsrShell*)m_pWrtShell)->HasSelection(); + return !bMultiSel && (!bSelection || m_pWrtShell->IsSelOnePara() ); } String SwView::GetThesaurusLookUpText( bool bSelection ) const { - return bSelection ? pWrtShell->GetSelTxt() : pWrtShell->GetCurWord(); + return bSelection ? m_pWrtShell->GetSelTxt() : m_pWrtShell->GetCurWord(); } void SwView::InsertThesaurusSynonym( const String &rSynonmText, const String &rLookUpText, bool bSelection ) { - sal_Bool bOldIns = pWrtShell->IsInsMode(); - pWrtShell->SetInsMode( sal_True ); + sal_Bool bOldIns = m_pWrtShell->IsInsMode(); + m_pWrtShell->SetInsMode( sal_True ); - pWrtShell->StartAllAction(); - pWrtShell->StartUndo(UNDO_DELETE); + m_pWrtShell->StartAllAction(); + m_pWrtShell->StartUndo(UNDO_DELETE); if( !bSelection ) { - if(pWrtShell->IsEndWrd()) - pWrtShell->Left(CRSR_SKIP_CELLS, sal_False, 1, sal_False ); + if(m_pWrtShell->IsEndWrd()) + m_pWrtShell->Left(CRSR_SKIP_CELLS, sal_False, 1, sal_False ); - pWrtShell->SelWrd(); + m_pWrtShell->SelWrd(); // make sure the selection build later from the data below does not // include "in word" character to the left and right in order to @@ -537,17 +537,17 @@ void SwView::InsertThesaurusSynonym( const String &rSynonmText, const String &rL ++nRight; // adjust existing selection - SwPaM *pCrsr = pWrtShell->GetCrsr(); + SwPaM *pCrsr = m_pWrtShell->GetCrsr(); pCrsr->GetPoint()->nContent -= nRight; pCrsr->GetMark()->nContent += nLeft; } - pWrtShell->Insert( rSynonmText ); + m_pWrtShell->Insert( rSynonmText ); - pWrtShell->EndUndo(UNDO_DELETE); - pWrtShell->EndAllAction(); + m_pWrtShell->EndUndo(UNDO_DELETE); + m_pWrtShell->EndAllAction(); - pWrtShell->SetInsMode( bOldIns ); + m_pWrtShell->SetInsMode( bOldIns ); } /*-------------------------------------------------------------------- @@ -558,12 +558,12 @@ void SwView::StartThesaurus() if (!IsValidSelectionForThesaurus()) return; - SfxErrorContext aContext( ERRCTX_SVX_LINGU_THESAURUS, aEmptyStr, pEditWin, + SfxErrorContext aContext( ERRCTX_SVX_LINGU_THESAURUS, aEmptyStr, m_pEditWin, RID_SVXERRCTX, &DIALOG_MGR() ); // Sprache rausholen // - LanguageType eLang = pWrtShell->GetCurLang(); + LanguageType eLang = m_pWrtShell->GetCurLang(); if( LANGUAGE_SYSTEM == eLang ) eLang = GetAppLanguage(); @@ -573,12 +573,12 @@ void SwView::StartThesaurus() return; } - SwViewOption* pVOpt = (SwViewOption*)pWrtShell->GetViewOptions(); + SwViewOption* pVOpt = (SwViewOption*)m_pWrtShell->GetViewOptions(); sal_Bool bOldIdle = pVOpt->IsIdle(); pVOpt->SetIdle( sal_False ); // get initial LookUp text - const sal_Bool bSelection = ((SwCrsrShell*)pWrtShell)->HasSelection(); + const sal_Bool bSelection = ((SwCrsrShell*)m_pWrtShell)->HasSelection(); String aTmp = GetThesaurusLookUpText( bSelection ); Reference< XThesaurus > xThes( ::GetThesaurus() ); @@ -645,24 +645,24 @@ IMPL_STATIC_LINK_NOINSTANCE( AsyncExecute, ExecuteHdl_Impl, ExecuteInfo*, pExecu sal_Bool SwView::ExecSpellPopup(const Point& rPt) { sal_Bool bRet = sal_False; - const SwViewOption* pVOpt = pWrtShell->GetViewOptions(); + const SwViewOption* pVOpt = m_pWrtShell->GetViewOptions(); if( pVOpt->IsOnlineSpell() && - !pWrtShell->IsSelection()) + !m_pWrtShell->IsSelection()) { - if (pWrtShell->GetSelectionType() & nsSelectionType::SEL_DRW_TXT) + if (m_pWrtShell->GetSelectionType() & nsSelectionType::SEL_DRW_TXT) bRet = ExecDrwTxtSpellPopup(rPt); - else if (!pWrtShell->IsSelFrmMode()) + else if (!m_pWrtShell->IsSelFrmMode()) { - const sal_Bool bOldViewLock = pWrtShell->IsViewLocked(); - pWrtShell->LockView( sal_True ); - pWrtShell->Push(); + const sal_Bool bOldViewLock = m_pWrtShell->IsViewLocked(); + m_pWrtShell->LockView( sal_True ); + m_pWrtShell->Push(); SwRect aToFill; // decide which variant of the context menu to use... // if neither spell checking nor grammar checking provides suggestions use the // default context menu. bool bUseGrammarContext = false; - Reference< XSpellAlternatives > xAlt( pWrtShell->GetCorrection(&rPt, aToFill) ); + Reference< XSpellAlternatives > xAlt( m_pWrtShell->GetCorrection(&rPt, aToFill) ); ProofreadingResult aGrammarCheckRes; sal_Int32 nErrorInResult = -1; uno::Sequence< rtl::OUString > aSuggestions; @@ -670,7 +670,7 @@ sal_Bool SwView::ExecSpellPopup(const Point& rPt) if (!xAlt.is() || xAlt->getAlternatives().getLength() == 0) { sal_Int32 nErrorPosInText = -1; - bCorrectionRes = pWrtShell->GetGrammarCorrection( aGrammarCheckRes, nErrorPosInText, nErrorInResult, aSuggestions, &rPt, aToFill ); + bCorrectionRes = m_pWrtShell->GetGrammarCorrection( aGrammarCheckRes, nErrorPosInText, nErrorInResult, aSuggestions, &rPt, aToFill ); ::rtl::OUString aMessageText; if (nErrorInResult >= 0) aMessageText = aGrammarCheckRes.aErrors[ nErrorInResult ].aShortComment; @@ -686,7 +686,7 @@ sal_Bool SwView::ExecSpellPopup(const Point& rPt) { // get paragraph text String aParaText; - SwPosition aPoint( *pWrtShell->GetCrsr()->GetPoint() ); + SwPosition aPoint( *m_pWrtShell->GetCrsr()->GetPoint() ); const SwTxtNode *pNode = dynamic_cast< const SwTxtNode * >( &aPoint.nNode.GetNode() ); if (pNode) @@ -697,20 +697,20 @@ sal_Bool SwView::ExecSpellPopup(const Point& rPt) } bRet = sal_True; - pWrtShell->SttSelect(); + m_pWrtShell->SttSelect(); std::auto_ptr< SwSpellPopup > pPopup; if (bUseGrammarContext) { sal_Int32 nPos = aPoint.nContent.GetIndex(); (void) nPos; - pPopup = std::auto_ptr< SwSpellPopup >(new SwSpellPopup( pWrtShell, aGrammarCheckRes, nErrorInResult, aSuggestions, aParaText )); + pPopup = std::auto_ptr< SwSpellPopup >(new SwSpellPopup( m_pWrtShell, aGrammarCheckRes, nErrorInResult, aSuggestions, aParaText )); } else - pPopup = std::auto_ptr< SwSpellPopup >(new SwSpellPopup( pWrtShell, xAlt, aParaText )); + pPopup = std::auto_ptr< SwSpellPopup >(new SwSpellPopup( m_pWrtShell, xAlt, aParaText )); ui::ContextMenuExecuteEvent aEvent; const Point aPixPos = GetEditWin().LogicToPixel( rPt ); - aEvent.SourceWindow = VCLUnoHelper::GetInterface( pEditWin ); + aEvent.SourceWindow = VCLUnoHelper::GetInterface( m_pEditWin ); aEvent.ExecutePosition.X = aPixPos.X(); aEvent.ExecutePosition.Y = aPixPos.Y(); Menu* pMenu = 0; @@ -724,7 +724,7 @@ sal_Bool SwView::ExecSpellPopup(const Point& rPt) //! 'custom made' menu... *sigh* (code copied from sfx2 and framework) if ( pMenu ) { - sal_uInt16 nId = ((PopupMenu*)pMenu)->Execute(pEditWin, aPixPos); + sal_uInt16 nId = ((PopupMenu*)pMenu)->Execute(m_pEditWin, aPixPos); OUString aCommand = ((PopupMenu*)pMenu)->GetItemCommand(nId); if (aCommand.isEmpty() ) { @@ -768,13 +768,13 @@ sal_Bool SwView::ExecSpellPopup(const Point& rPt) } else { - pPopup->Execute( aToFill.SVRect(), pEditWin ); + pPopup->Execute( aToFill.SVRect(), m_pEditWin ); } } } - pWrtShell->Pop( sal_False ); - pWrtShell->LockView( bOldViewLock ); + m_pWrtShell->Pop( sal_False ); + m_pWrtShell->LockView( bOldViewLock ); } } return bRet; @@ -788,9 +788,9 @@ sal_Bool SwView::ExecSpellPopup(const Point& rPt) sal_Bool SwView::ExecSmartTagPopup( const Point& rPt ) { sal_Bool bRet = sal_False; - const sal_Bool bOldViewLock = pWrtShell->IsViewLocked(); - pWrtShell->LockView( sal_True ); - pWrtShell->Push(); + const sal_Bool bOldViewLock = m_pWrtShell->IsViewLocked(); + m_pWrtShell->LockView( sal_True ); + m_pWrtShell->Push(); // get word that was clicked on @@ -800,17 +800,17 @@ sal_Bool SwView::ExecSmartTagPopup( const Point& rPt ) Sequence< Reference< container::XStringKeyMap > > aStringKeyMaps; Reference<text::XTextRange> xRange; - pWrtShell->GetSmartTagTerm( rPt, aToFill, aSmartTagTypes, aStringKeyMaps, xRange); + m_pWrtShell->GetSmartTagTerm( rPt, aToFill, aSmartTagTypes, aStringKeyMaps, xRange); if ( xRange.is() && aSmartTagTypes.getLength() ) { bRet = sal_True; - pWrtShell->SttSelect(); + m_pWrtShell->SttSelect(); SwSmartTagPopup aPopup( this, aSmartTagTypes, aStringKeyMaps, xRange ); - aPopup.Execute( aToFill.SVRect(), pEditWin ); + aPopup.Execute( aToFill.SVRect(), m_pEditWin ); } - pWrtShell->Pop( sal_False ); - pWrtShell->LockView( bOldViewLock ); + m_pWrtShell->Pop( sal_False ); + m_pWrtShell->LockView( bOldViewLock ); return bRet; } @@ -894,10 +894,10 @@ IMPL_LINK( SwFieldDialog, MyListBoxHandler, ListBox *, pBox ) IMPL_LINK_NOARG(SwView, FieldPopupModeEndHdl) { - if ( mpFieldPopup ) + if ( m_pFieldPopup ) { - delete mpFieldPopup; - mpFieldPopup = NULL; + delete m_pFieldPopup; + m_pFieldPopup = NULL; } return 0; } @@ -906,11 +906,11 @@ void SwView::ExecFieldPopup( const Point& rPt, IFieldmark *fieldBM ) { const Point aPixPos = GetEditWin().LogicToPixel( rPt ); - mpFieldPopup = new SwFieldDialog( pEditWin, fieldBM ); - mpFieldPopup->SetPopupModeEndHdl( LINK( this, SwView, FieldPopupModeEndHdl ) ); + m_pFieldPopup = new SwFieldDialog( m_pEditWin, fieldBM ); + m_pFieldPopup->SetPopupModeEndHdl( LINK( this, SwView, FieldPopupModeEndHdl ) ); - Rectangle aRect( pEditWin->OutputToScreenPixel( aPixPos ), Size( 0, 0 ) ); - mpFieldPopup->StartPopupMode( aRect, FLOATWIN_POPUPMODE_DOWN|FLOATWIN_POPUPMODE_GRABFOCUS ); + Rectangle aRect( m_pEditWin->OutputToScreenPixel( aPixPos ), Size( 0, 0 ) ); + m_pFieldPopup->StartPopupMode( aRect, FLOATWIN_POPUPMODE_DOWN|FLOATWIN_POPUPMODE_GRABFOCUS ); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/ui/uiview/viewmdi.cxx b/sw/source/ui/uiview/viewmdi.cxx index 9a791d080716..d359ce9bf061 100644 --- a/sw/source/ui/uiview/viewmdi.cxx +++ b/sw/source/ui/uiview/viewmdi.cxx @@ -53,8 +53,8 @@ #include <IDocumentSettingAccess.hxx> #include <PostItMgr.hxx> -sal_uInt16 SwView::nMoveType = NID_PGE; -sal_Int32 SwView::nActMark = 0; +sal_uInt16 SwView::m_nMoveType = NID_PGE; +sal_Int32 SwView::m_nActMark = 0; #define VIEW_IMAGECOLOR COL_LIGHTBLUE @@ -64,39 +64,39 @@ using namespace ::com::sun::star::frame; void SwView::SetZoom( SvxZoomType eZoomType, short nFactor, sal_Bool bViewOnly ) { - bool const bCrsrIsVisible(pWrtShell->IsCrsrVisible()); + bool const bCrsrIsVisible(m_pWrtShell->IsCrsrVisible()); _SetZoom( GetEditWin().GetOutputSizePixel(), eZoomType, nFactor, bViewOnly ); // fdo#40465 force the cursor to stay in view whilst zooming if (bCrsrIsVisible) - pWrtShell->ShowCrsr(); + m_pWrtShell->ShowCrsr(); } void SwView::_SetZoom( const Size &rEditSize, SvxZoomType eZoomType, short nFactor, sal_Bool bViewOnly ) { - sal_Bool bUnLockView = !pWrtShell->IsViewLocked(); - pWrtShell->LockView( sal_True ); - pWrtShell->LockPaint(); + sal_Bool bUnLockView = !m_pWrtShell->IsViewLocked(); + m_pWrtShell->LockView( sal_True ); + m_pWrtShell->LockPaint(); { - SwActContext aActContext(pWrtShell); + SwActContext aActContext(m_pWrtShell); long nFac = nFactor; sal_Bool bWeb = 0 != PTR_CAST(SwWebView, this); SwMasterUsrPref *pUsrPref = (SwMasterUsrPref*)SW_MOD()->GetUsrPref(bWeb); - const SwPageDesc &rDesc = pWrtShell->GetPageDesc( pWrtShell->GetCurPageDesc() ); + const SwPageDesc &rDesc = m_pWrtShell->GetPageDesc( m_pWrtShell->GetCurPageDesc() ); const SvxLRSpaceItem &rLRSpace = rDesc.GetMaster().GetLRSpace(); - const SwViewOption *pOpt = pWrtShell->GetViewOptions(); + const SwViewOption *pOpt = m_pWrtShell->GetViewOptions(); long lLeftMargin = 0; if( eZoomType != SVX_ZOOM_PERCENT ) { const bool bAutomaticViewLayout = 0 == pOpt->GetViewLayoutColumns(); - const SwRect aPageRect( pWrtShell->GetAnyCurRect( RECT_PAGE_CALC ) ); - const SwRect aRootRect( pWrtShell->GetAnyCurRect( RECT_PAGES_AREA ) ); + const SwRect aPageRect( m_pWrtShell->GetAnyCurRect( RECT_PAGE_CALC ) ); + const SwRect aRootRect( m_pWrtShell->GetAnyCurRect( RECT_PAGES_AREA ) ); Size aPageSize( aPageRect.SSize() ); Size aRootSize( aRootRect.SSize() ); @@ -164,20 +164,20 @@ void SwView::_SetZoom( const Size &rEditSize, SvxZoomType eZoomType, { aOpt.SetZoom ( sal_uInt16(nFac) ); aOpt.SetReadonly(pOpt->IsReadonly()); - pWrtShell->ApplyViewOptions( aOpt ); + m_pWrtShell->ApplyViewOptions( aOpt ); } if ( eZoomType != SVX_ZOOM_PERCENT ) { Point aPos; if ( eZoomType == SVX_ZOOM_WHOLEPAGE ) - aPos.Y() = pWrtShell->GetAnyCurRect(RECT_PAGE).Top() - DOCUMENTBORDER; + aPos.Y() = m_pWrtShell->GetAnyCurRect(RECT_PAGE).Top() - DOCUMENTBORDER; else { //sicherstellen, dass sich der Cursor im sichtbaren //Bereich befindet, damit nur 1x gescrollt wird aPos.X() = lLeftMargin; - const SwRect &rCharRect = pWrtShell->GetCharRect(); + const SwRect &rCharRect = m_pWrtShell->GetCharRect(); if ( rCharRect.Top() > GetVisArea().Bottom() || rCharRect.Bottom() < aPos.Y() ) aPos.Y() = rCharRect.Top() - rCharRect.Height(); @@ -188,36 +188,36 @@ void SwView::_SetZoom( const Size &rEditSize, SvxZoomType eZoomType, } // OS: Notloesung - in CalcVisArea wird u.U. wieder SetZoom gerufen und // dann werden falsche Werte eingestellt - ((SwViewOption*)pWrtShell->GetViewOptions())->SetZoomType( eZoomType ); + ((SwViewOption*)m_pWrtShell->GetViewOptions())->SetZoomType( eZoomType ); CalcVisArea( rEditSize ); //fuer das Neuberechnen des sichtbaren Bereiches } else if ( sal_uInt16(nFac) != pOpt->GetZoom() ) { aOpt.SetZoom ( sal_uInt16(nFac) ); - pWrtShell->ApplyViewOptions( aOpt ); + m_pWrtShell->ApplyViewOptions( aOpt ); } const Fraction aFrac( nFac, 100 ); - pVRuler->SetZoom( aFrac ); - pVRuler->ForceUpdate(); - pHRuler->SetZoom( aFrac ); - pHRuler->ForceUpdate(); - ((SwViewOption*)pWrtShell->GetViewOptions())->SetZoomType( eZoomType ); + m_pVRuler->SetZoom( aFrac ); + m_pVRuler->ForceUpdate(); + m_pHRuler->SetZoom( aFrac ); + m_pHRuler->ForceUpdate(); + ((SwViewOption*)m_pWrtShell->GetViewOptions())->SetZoomType( eZoomType ); } - pWrtShell->UnlockPaint(); + m_pWrtShell->UnlockPaint(); if( bUnLockView ) - pWrtShell->LockView( sal_False ); + m_pWrtShell->LockView( sal_False ); } void SwView::SetViewLayout( sal_uInt16 nColumns, bool bBookMode, sal_Bool bViewOnly ) { - const sal_Bool bUnLockView = !pWrtShell->IsViewLocked(); - pWrtShell->LockView( sal_True ); - pWrtShell->LockPaint(); + const sal_Bool bUnLockView = !m_pWrtShell->IsViewLocked(); + m_pWrtShell->LockView( sal_True ); + m_pWrtShell->LockPaint(); { - SwActContext aActContext(pWrtShell); + SwActContext aActContext(m_pWrtShell); if ( !GetViewFrame()->GetFrame().IsInPlace() && !bViewOnly ) { @@ -238,7 +238,7 @@ void SwView::SetViewLayout( sal_uInt16 nColumns, bool bBookMode, sal_Bool bViewO } } - const SwViewOption *pOpt = pWrtShell->GetViewOptions(); + const SwViewOption *pOpt = m_pWrtShell->GetViewOptions(); if ( nColumns != pOpt->GetViewLayoutColumns() || bBookMode != pOpt->IsViewLayoutBookMode() ) @@ -246,17 +246,17 @@ void SwView::SetViewLayout( sal_uInt16 nColumns, bool bBookMode, sal_Bool bViewO SwViewOption aOpt( *pOpt ); aOpt.SetViewLayoutColumns( nColumns ); aOpt.SetViewLayoutBookMode( bBookMode ); - pWrtShell->ApplyViewOptions( aOpt ); + m_pWrtShell->ApplyViewOptions( aOpt ); } - pVRuler->ForceUpdate(); - pHRuler->ForceUpdate(); + m_pVRuler->ForceUpdate(); + m_pHRuler->ForceUpdate(); } - pWrtShell->UnlockPaint(); + m_pWrtShell->UnlockPaint(); if( bUnLockView ) - pWrtShell->LockView( sal_False ); + m_pWrtShell->LockView( sal_False ); SfxBindings& rBnd = GetViewFrame()->GetBindings(); rBnd.Invalidate( SID_ATTR_VIEWLAYOUT ); @@ -278,15 +278,15 @@ IMPL_LINK( SwView, WindowChildEventListener, VclSimpleEvent*, pEvent ) switch ( pVclEvent->GetId() ) { case VCLEVENT_WINDOW_HIDE: - if( pChildWin == pHScrollbar ) + if( pChildWin == m_pHScrollbar ) ShowHScrollbar( sal_False ); - else if( pChildWin == pVScrollbar ) + else if( pChildWin == m_pVScrollbar ) ShowVScrollbar( sal_False ); break; case VCLEVENT_WINDOW_SHOW: - if( pChildWin == pHScrollbar ) + if( pChildWin == m_pHScrollbar ) ShowHScrollbar( sal_True ); - else if( pChildWin == pVScrollbar ) + else if( pChildWin == m_pVScrollbar ) ShowVScrollbar( sal_True ); break; } @@ -298,12 +298,12 @@ IMPL_LINK( SwView, WindowChildEventListener, VclSimpleEvent*, pEvent ) int SwView::_CreateScrollbar( sal_Bool bHori ) { Window *pMDI = &GetViewFrame()->GetWindow(); - SwScrollbar** ppScrollbar = bHori ? &pHScrollbar : &pVScrollbar; + SwScrollbar** ppScrollbar = bHori ? &m_pHScrollbar : &m_pVScrollbar; OSL_ENSURE( !*ppScrollbar, "vorher abpruefen!" ); if( !bHori ) - CreatePageButtons( !bShowAtResize ); + CreatePageButtons( !m_bShowAtResize ); *ppScrollbar = new SwScrollbar( pMDI, bHori ); UpdateScrollbars(); @@ -320,7 +320,7 @@ int SwView::_CreateScrollbar( sal_Bool bHori ) // Scrollbar muss nochmals getestet werden, da im InvalidateBorder u.U. der // Scrollbar wieder geloescht wurde - if ( !bShowAtResize && (*ppScrollbar)) + if ( !m_bShowAtResize && (*ppScrollbar)) (*ppScrollbar)->ExtendedShow(); return 1; @@ -329,17 +329,17 @@ int SwView::_CreateScrollbar( sal_Bool bHori ) void SwView::CreatePageButtons(sal_Bool bShow) { Window *pMDI = &GetViewFrame()->GetWindow(); - pPageUpBtn = new SwHlpImageButton(pMDI, SW_RES( BTN_PAGEUP ), sal_True ); - pPageUpBtn->SetHelpId(HID_SCRL_PAGEUP); - pPageDownBtn = new SwHlpImageButton(pMDI, SW_RES( BTN_PAGEDOWN ), sal_False ); - pPageDownBtn->SetHelpId(HID_SCRL_PAGEDOWN); + m_pPageUpBtn = new SwHlpImageButton(pMDI, SW_RES( BTN_PAGEUP ), sal_True ); + m_pPageUpBtn->SetHelpId(HID_SCRL_PAGEUP); + m_pPageDownBtn = new SwHlpImageButton(pMDI, SW_RES( BTN_PAGEDOWN ), sal_False ); + m_pPageDownBtn->SetHelpId(HID_SCRL_PAGEDOWN); Reference< XFrame > xFrame = GetViewFrame()->GetFrame().GetFrameInterface(); - pNaviBtn = new SwNaviImageButton(pMDI, xFrame ); - pNaviBtn->SetHelpId(HID_SCRL_NAVI); + m_pNaviBtn = new SwNaviImageButton(pMDI, xFrame ); + m_pNaviBtn->SetHelpId(HID_SCRL_NAVI); Link aLk( LINK( this, SwView, BtnPage ) ); - pPageUpBtn->SetClickHdl( aLk ); - pPageDownBtn->SetClickHdl( aLk ); - if(nMoveType != NID_PGE) + m_pPageUpBtn->SetClickHdl( aLk ); + m_pPageDownBtn->SetClickHdl( aLk ); + if(m_nMoveType != NID_PGE) { Color aColor(VIEW_IMAGECOLOR); SetImageButtonColor(aColor); @@ -347,9 +347,9 @@ void SwView::CreatePageButtons(sal_Bool bShow) if(bShow) { - pPageUpBtn->Show(); - pPageDownBtn->Show(); - pNaviBtn->Show(); + m_pPageUpBtn->Show(); + m_pPageDownBtn->Show(); + m_pNaviBtn->Show(); } }; @@ -359,7 +359,7 @@ void SwView::CreatePageButtons(sal_Bool bShow) IMPL_LINK( SwView, BtnPage, Button *, pButton ) { // #i75416# move the execution of the search to an asynchronously called static link - bool* pbNext = new bool( (pButton == pPageDownBtn) ); + bool* pbNext = new bool( (pButton == m_pPageDownBtn) ); Application::PostUserEvent( STATIC_LINK(this, SwView, MoveNavigationHdl), pbNext ); return 0; } @@ -370,7 +370,7 @@ IMPL_STATIC_LINK( SwView, MoveNavigationHdl, bool *, pbNext ) return 0; bool bNext = *pbNext; SwWrtShell& rSh = pThis->GetWrtShell(); - switch( nMoveType ) + switch( m_nMoveType ) { case NID_PGE: bNext ? pThis->PhyPageDown() : pThis->PhyPageUp(); @@ -387,9 +387,9 @@ IMPL_STATIC_LINK( SwView, MoveNavigationHdl, bool *, pbNext ) case NID_OLE: { sal_uInt16 eType = GOTOOBJ_FLY_FRM; - if(nMoveType == NID_GRF) + if(m_nMoveType == NID_GRF) eType = GOTOOBJ_FLY_GRF; - else if(nMoveType == NID_OLE) + else if(m_nMoveType == NID_OLE) eType = GOTOOBJ_FLY_OLE; sal_Bool bSuccess = bNext ? rSh.GotoNextFly(eType) : @@ -404,7 +404,7 @@ IMPL_STATIC_LINK( SwView, MoveNavigationHdl, bool *, pbNext ) case NID_DRW : case NID_CTRL: rSh.GotoObj(bNext, - nMoveType == NID_DRW ? + m_nMoveType == NID_DRW ? GOTOOBJ_DRAW_SIMPLE : GOTOOBJ_DRAW_CONTROL); break; @@ -457,17 +457,17 @@ IMPL_STATIC_LINK( SwView, MoveNavigationHdl, bool *, pbNext ) { if(bNext) { - nActMark++; - if (nActMark >= MAX_MARKS || nActMark >= static_cast<sal_Int32>(vNavMarks.size())) - nActMark = 0; + m_nActMark++; + if (m_nActMark >= MAX_MARKS || m_nActMark >= static_cast<sal_Int32>(vNavMarks.size())) + m_nActMark = 0; } else { - nActMark--; - if (nActMark < 0 || nActMark >= static_cast<sal_Int32>(vNavMarks.size())) - nActMark = vNavMarks.size()-1; + m_nActMark--; + if (m_nActMark < 0 || m_nActMark >= static_cast<sal_Int32>(vNavMarks.size())) + m_nActMark = vNavMarks.size()-1; } - rSh.GotoMark(vNavMarks[nActMark]); + rSh.GotoMark(vNavMarks[m_nActMark]); } } break; @@ -485,15 +485,15 @@ IMPL_STATIC_LINK( SwView, MoveNavigationHdl, bool *, pbNext ) } break; case NID_SRCH_REP: - if(pSrchItem) + if(m_pSrchItem) { - sal_Bool bBackward = pSrchItem->GetBackward(); + sal_Bool bBackward = m_pSrchItem->GetBackward(); if(rSh.HasSelection() && !bNext == rSh.IsCrsrPtAtEnd()) rSh.SwapPam(); - pSrchItem->SetBackward(!bNext); + m_pSrchItem->SetBackward(!bNext); SfxRequest aReq(FN_REPEAT_SEARCH, SFX_CALLMODE_SLOT, pThis->GetPool()); pThis->ExecSearch(aReq); - pSrchItem->SetBackward(bBackward); + m_pSrchItem->SetBackward(bBackward); } break; case NID_INDEX_ENTRY: @@ -508,69 +508,69 @@ IMPL_STATIC_LINK( SwView, MoveNavigationHdl, bool *, pbNext ) rSh.GotoNxtPrvTblFormula( bNext, sal_True ); break; } - pThis->pEditWin->GrabFocus(); + pThis->m_pEditWin->GrabFocus(); delete pbNext; return 0; } int SwView::CreateTab() { - pHRuler->SetActive(GetFrame() && IsActive()); + m_pHRuler->SetActive(GetFrame() && IsActive()); - pHRuler->Show(); + m_pHRuler->Show(); InvalidateBorder(); return 1; } int SwView::KillTab() { - pHRuler->Hide(); + m_pHRuler->Hide(); InvalidateBorder(); return 1; } void SwView::ChangeTabMetric( FieldUnit eUnit ) { - if(pHRuler->GetUnit() != eUnit ) + if(m_pHRuler->GetUnit() != eUnit ) { - pHRuler->SetUnit( eUnit ); - pHRuler->Invalidate(); + m_pHRuler->SetUnit( eUnit ); + m_pHRuler->Invalidate(); } } void SwView::ChangeVLinealMetric( FieldUnit eUnit ) { - if(pVRuler->GetUnit() != eUnit) + if(m_pVRuler->GetUnit() != eUnit) { - pVRuler->SetUnit( eUnit ); - pVRuler->Invalidate(); + m_pVRuler->SetUnit( eUnit ); + m_pVRuler->Invalidate(); } } void SwView::GetVLinealMetric(FieldUnit& eToFill) const { - eToFill = pVRuler->GetUnit(); + eToFill = m_pVRuler->GetUnit(); } void SwView::GetHLinealMetric(FieldUnit& eToFill) const { - eToFill = pHRuler->GetUnit(); + eToFill = m_pHRuler->GetUnit(); } int SwView::CreateVLineal() { - pHRuler->SetBorderPos( pVRuler->GetSizePixel().Width()-1 ); + m_pHRuler->SetBorderPos( m_pVRuler->GetSizePixel().Width()-1 ); - pVRuler->SetActive(GetFrame() && IsActive()); - pVRuler->Show(); + m_pVRuler->SetActive(GetFrame() && IsActive()); + m_pVRuler->Show(); InvalidateBorder(); return 1; } int SwView::KillVLineal() { - pVRuler->Hide(); - pHRuler->SetBorderPos( 0 ); + m_pVRuler->Hide(); + m_pHRuler->SetBorderPos( 0 ); InvalidateBorder(); return 1; } @@ -601,14 +601,14 @@ IMPL_LINK( SwView, ExecRulerClick, Ruler *, pRuler ) sal_uInt16 SwView::GetMoveType() { - return nMoveType; + return m_nMoveType; } void SwView::SetMoveType(sal_uInt16 nSet) { - sal_Bool bLastPage = nMoveType == NID_PGE; - nMoveType = nSet; - sal_Bool bNewPage = nMoveType == NID_PGE; + sal_Bool bLastPage = m_nMoveType == NID_PGE; + m_nMoveType = nSet; + sal_Bool bNewPage = m_nMoveType == NID_PGE; if(bNewPage != bLastPage) { Color aColor(bNewPage ? COL_BLACK : VIEW_IMAGECOLOR); @@ -624,59 +624,59 @@ void SwView::SetMoveType(sal_uInt16 nSet) void SwView::SetActMark(sal_Int32 nSet) { - nActMark = nSet; + m_nActMark = nSet; } void SwView::SetImageButtonColor(Color& rColor) { - if(pPageUpBtn) + if(m_pPageUpBtn) { - pPageUpBtn->SetControlForeground(rColor); - pPageDownBtn->SetControlForeground(rColor); + m_pPageUpBtn->SetControlForeground(rColor); + m_pPageDownBtn->SetControlForeground(rColor); } } void SwView::ShowHScrollbar(sal_Bool bShow) { - OSL_ENSURE(pHScrollbar, "Scrollbar invalid"); - pHScrollbar->ExtendedShow(bShow); + OSL_ENSURE(m_pHScrollbar, "Scrollbar invalid"); + m_pHScrollbar->ExtendedShow(bShow); } sal_Bool SwView::IsHScrollbarVisible()const { - OSL_ENSURE(pHScrollbar, "Scrollbar invalid"); - return pHScrollbar->IsVisible( sal_False ) || pHScrollbar->IsAuto(); + OSL_ENSURE(m_pHScrollbar, "Scrollbar invalid"); + return m_pHScrollbar->IsVisible( sal_False ) || m_pHScrollbar->IsAuto(); } void SwView::ShowVScrollbar(sal_Bool bShow) { - OSL_ENSURE(pVScrollbar, "Scrollbar invalid"); - pVScrollbar->ExtendedShow(bShow); - pPageUpBtn->Show(bShow); - pPageDownBtn->Show(bShow); - pNaviBtn->Show(bShow); + OSL_ENSURE(m_pVScrollbar, "Scrollbar invalid"); + m_pVScrollbar->ExtendedShow(bShow); + m_pPageUpBtn->Show(bShow); + m_pPageDownBtn->Show(bShow); + m_pNaviBtn->Show(bShow); } sal_Bool SwView::IsVScrollbarVisible()const { - OSL_ENSURE(pVScrollbar, "Scrollbar invalid"); - return pVScrollbar->IsVisible( sal_False ); + OSL_ENSURE(m_pVScrollbar, "Scrollbar invalid"); + return m_pVScrollbar->IsVisible( sal_False ); } void SwView::EnableHScrollbar(bool bEnable) { - if (mbHScrollbarEnabled != bEnable) + if (m_bHScrollbarEnabled != bEnable) { - mbHScrollbarEnabled = bEnable; + m_bHScrollbarEnabled = bEnable; InvalidateBorder(); } } void SwView::EnableVScrollbar(bool bEnable) { - if (mbVScrollbarEnabled != bEnable) + if (m_bVScrollbarEnabled != bEnable) { - mbVScrollbarEnabled = bEnable; + m_bVScrollbarEnabled = bEnable; InvalidateBorder(); } } diff --git a/sw/source/ui/uiview/viewport.cxx b/sw/source/ui/uiview/viewport.cxx index 9fd7d63e5383..f7233229f867 100644 --- a/sw/source/ui/uiview/viewport.cxx +++ b/sw/source/ui/uiview/viewport.cxx @@ -58,8 +58,8 @@ static sal_uInt16 nPgNum = 0; sal_Bool SwView::IsDocumentBorder() { return GetDocShell()->GetCreateMode() == SFX_CREATE_MODE_EMBEDDED || - pWrtShell->GetViewOptions()->getBrowseMode() || - SVX_ZOOM_PAGEWIDTH_NOBORDER == (SvxZoomType)pWrtShell->GetViewOptions()->GetZoomType(); + m_pWrtShell->GetViewOptions()->getBrowseMode() || + SVX_ZOOM_PAGEWIDTH_NOBORDER == (SvxZoomType)m_pWrtShell->GetViewOptions()->GetZoomType(); } inline long GetLeftMargin( SwView &rView ) @@ -77,7 +77,7 @@ static void lcl_GetPos(SwView* pView, sal_Bool bBorder) { SwWrtShell &rSh = pView->GetWrtShell(); - const Size aDocSz( rSh.GetDocSize() ); + const Size m_aDocSz( rSh.GetDocSize() ); const long lBorder = bBorder ? DOCUMENTBORDER : DOCUMENTBORDER * 2; const bool bHori = pScrollbar->IsHoriScroll(); @@ -86,7 +86,7 @@ static void lcl_GetPos(SwView* pView, long lDelta = lPos - (bHori ? rSh.VisArea().Pos().X() : rSh.VisArea().Pos().Y()); - const long lSize = (bHori ? aDocSz.A() : aDocSz.B()) + lBorder; + const long lSize = (bHori ? m_aDocSz.A() : m_aDocSz.B()) + lBorder; // sollte rechts oder unten zuviel Wiese sein, dann muss // diese von der VisArea herausgerechnet werden! long nTmp = pView->GetVisArea().Right()+lDelta; @@ -122,9 +122,9 @@ void SwView::InvalidateRulerPos() GetViewFrame()->GetBindings().Invalidate(aInval); - OSL_ENSURE(pHRuler, "warum ist das Lineal nicht da?"); - pHRuler->ForceUpdate(); - pVRuler->ForceUpdate(); + OSL_ENSURE(m_pHRuler, "warum ist das Lineal nicht da?"); + m_pHRuler->ForceUpdate(); + m_pVRuler->ForceUpdate(); } /*-------------------------------------------------------------------- @@ -135,7 +135,7 @@ void SwView::InvalidateRulerPos() long SwView::SetHScrollMax( long lMax ) { const long lBorder = IsDocumentBorder() ? DOCUMENTBORDER : DOCUMENTBORDER * 2; - const long lSize = GetDocSz().Width() + lBorder - aVisArea.GetWidth(); + const long lSize = GetDocSz().Width() + lBorder - m_aVisArea.GetWidth(); // bei negativen Werten ist das Dokument vollstaendig sichtbar; // in diesem Fall kein Scrollen @@ -145,7 +145,7 @@ long SwView::SetHScrollMax( long lMax ) long SwView::SetVScrollMax( long lMax ) { const long lBorder = IsDocumentBorder() ? DOCUMENTBORDER : DOCUMENTBORDER * 2; - long lSize = GetDocSz().Height() + lBorder - aVisArea.GetHeight(); + long lSize = GetDocSz().Height() + lBorder - m_aVisArea.GetHeight(); return Max( Min( lMax, lSize), 0L ); // siehe horz. } @@ -163,9 +163,9 @@ void SwView::DocSzChgd(const Size &rSz) extern int bDocSzUpdated; -aDocSz = rSz; +m_aDocSz = rSz; - if( !pWrtShell || aVisArea.IsEmpty() ) // keine Shell -> keine Aenderung + if( !m_pWrtShell || m_aVisArea.IsEmpty() ) // keine Shell -> keine Aenderung { bDocSzUpdated = sal_False; return; @@ -173,10 +173,10 @@ aDocSz = rSz; //Wenn Text geloescht worden ist, kann es sein, dass die VisArea hinter //den sichtbaren Bereich verweist - Rectangle aNewVisArea( aVisArea ); + Rectangle aNewVisArea( m_aVisArea ); bool bModified = false; SwTwips lGreenOffset = IsDocumentBorder() ? DOCUMENTBORDER : DOCUMENTBORDER * 2; - SwTwips lTmp = aDocSz.Width() + lGreenOffset; + SwTwips lTmp = m_aDocSz.Width() + lGreenOffset; if ( aNewVisArea.Right() >= lTmp ) { @@ -186,7 +186,7 @@ aDocSz = rSz; bModified = true; } - lTmp = aDocSz.Height() + lGreenOffset; + lTmp = m_aDocSz.Height() + lGreenOffset; if ( aNewVisArea.Bottom() >= lTmp ) { lTmp = aNewVisArea.Bottom() - lTmp; @@ -198,7 +198,7 @@ aDocSz = rSz; if ( bModified ) SetVisArea( aNewVisArea, sal_False ); - if ( UpdateScrollbars() && !bInOuterResizePixel && !bInInnerResizePixel && + if ( UpdateScrollbars() && !m_bInOuterResizePixel && !m_bInInnerResizePixel && !GetViewFrame()->GetFrame().IsInPlace()) OuterResizePixel( Point(), GetViewFrame()->GetWindow().GetOutputSizePixel() ); @@ -209,13 +209,13 @@ aDocSz = rSz; --------------------------------------------------------------------*/ void SwView::SetVisArea( const Rectangle &rRect, sal_Bool bUpdateScrollbar ) { - const Size aOldSz( aVisArea.GetSize() ); + const Size aOldSz( m_aVisArea.GetSize() ); const Point aTopLeft( AlignToPixel( rRect.TopLeft() )); const Point aBottomRight( AlignToPixel( rRect.BottomRight() )); Rectangle aLR( aTopLeft, aBottomRight ); - if( aLR == aVisArea ) + if( aLR == m_aVisArea ) return; const SwTwips lMin = IsDocumentBorder() ? DOCUMENTBORDER : 0; @@ -236,7 +236,7 @@ void SwView::SetVisArea( const Rectangle &rRect, sal_Bool bUpdateScrollbar ) if( aLR.Bottom() < 0 ) aLR.Bottom() = 0; - if( aLR == aVisArea ) + if( aLR == m_aVisArea ) return; const Size aSize( aLR.GetSize() ); @@ -249,20 +249,20 @@ void SwView::SetVisArea( const Rectangle &rRect, sal_Bool bUpdateScrollbar ) //Vorsichtshalber tun wir das nur wenn an der Shell eine Action laeuft, //denn dann wir nicht wirklich gepaintet sondern die Rechtecke werden //lediglich (in Dokumentkoordinaten) vorgemerkt. - if ( pWrtShell && pWrtShell->ActionPend() ) - pWrtShell->GetWin()->Update(); + if ( m_pWrtShell && m_pWrtShell->ActionPend() ) + m_pWrtShell->GetWin()->Update(); - aVisArea = aLR; + m_aVisArea = aLR; const sal_Bool bOuterResize = bUpdateScrollbar && UpdateScrollbars(); - if ( pWrtShell ) + if ( m_pWrtShell ) { - pWrtShell->VisPortChgd( aVisArea ); - if ( aOldSz != pWrtShell->VisArea().SSize() && - ( Abs(aOldSz.Width() - pWrtShell->VisArea().Width()) > 2 || - Abs(aOldSz.Height() - pWrtShell->VisArea().Height()) > 2 ) ) - pWrtShell->CheckBrowseView( sal_False ); + m_pWrtShell->VisPortChgd( m_aVisArea ); + if ( aOldSz != m_pWrtShell->VisArea().SSize() && + ( Abs(aOldSz.Width() - m_pWrtShell->VisArea().Width()) > 2 || + Abs(aOldSz.Height() - m_pWrtShell->VisArea().Height()) > 2 ) ) + m_pWrtShell->CheckBrowseView( sal_False ); } if ( !bProtectDocShellVisArea ) @@ -270,7 +270,7 @@ void SwView::SetVisArea( const Rectangle &rRect, sal_Bool bUpdateScrollbar ) //Wenn die Groesse der VisArea unveraendert ist, reichen wir die //Groesse der VisArea vom InternalObject weiter. Damit soll der //Transport von Fehlern vermieden werden. - Rectangle aVis( aVisArea ); + Rectangle aVis( m_aVisArea ); if ( aVis.GetSize() == aOldSz ) aVis.SetSize( GetDocShell()->SfxObjectShell::GetVisArea(ASPECT_CONTENT).GetSize() ); // TODO/LATER: why casting?! @@ -286,11 +286,11 @@ void SwView::SetVisArea( const Rectangle &rRect, sal_Bool bUpdateScrollbar ) GetDocShell()->SvEmbeddedObject::SetVisArea( aVis );*/ } - SfxViewShell::VisAreaChanged( aVisArea ); + SfxViewShell::VisAreaChanged( m_aVisArea ); InvalidateRulerPos(); - if ( bOuterResize && !bInOuterResizePixel && !bInInnerResizePixel) + if ( bOuterResize && !m_bInOuterResizePixel && !m_bInInnerResizePixel) OuterResizePixel( Point(), GetViewFrame()->GetWindow().GetOutputSizePixel() ); } @@ -314,28 +314,28 @@ void SwView::SetVisArea( const Point &rPt, sal_Bool bUpdateScrollbar ) aPt.Y() -= aPt.Y() % nTmp; aPt = GetEditWin().PixelToLogic( aPt ); - if ( aPt == aVisArea.TopLeft() ) + if ( aPt == m_aVisArea.TopLeft() ) return; - const long lXDiff = aVisArea.Left() - aPt.X(); - const long lYDiff = aVisArea.Top() - aPt.Y(); + const long lXDiff = m_aVisArea.Left() - aPt.X(); + const long lYDiff = m_aVisArea.Top() - aPt.Y(); SetVisArea( Rectangle( aPt, - Point( aVisArea.Right() - lXDiff, aVisArea.Bottom() - lYDiff ) ), + Point( m_aVisArea.Right() - lXDiff, m_aVisArea.Bottom() - lYDiff ) ), bUpdateScrollbar); } void SwView::CheckVisArea() { - pHScrollbar->SetAuto( pWrtShell->GetViewOptions()->getBrowseMode() && + m_pHScrollbar->SetAuto( m_pWrtShell->GetViewOptions()->getBrowseMode() && !GetViewFrame()->GetFrame().IsInPlace() ); if ( IsDocumentBorder() ) { - if ( aVisArea.Left() != DOCUMENTBORDER || - aVisArea.Top() != DOCUMENTBORDER ) + if ( m_aVisArea.Left() != DOCUMENTBORDER || + m_aVisArea.Top() != DOCUMENTBORDER ) { - Rectangle aNewVisArea( aVisArea ); - aNewVisArea.Move( DOCUMENTBORDER - aVisArea.Left(), - DOCUMENTBORDER - aVisArea.Top() ); + Rectangle aNewVisArea( m_aVisArea ); + aNewVisArea.Move( DOCUMENTBORDER - m_aVisArea.Left(), + DOCUMENTBORDER - m_aVisArea.Top() ); SetVisArea( aNewVisArea, sal_True ); } } @@ -359,34 +359,34 @@ void SwView::CalcPt( Point *pPt, const Rectangle &rRect, long nYScroll = GetYScroll(); long nDesHeight = rRect.GetHeight(); - long nCurHeight = aVisArea.GetHeight(); + long nCurHeight = m_aVisArea.GetHeight(); nYScroll = Min(nYScroll, nCurHeight - nDesHeight); // wird es knapp, dann nicht zuviel scrollen if(nDesHeight > nCurHeight) // die Hoehe reicht nicht aus, dann interessiert nYScroll nicht mehr { pPt->Y() = rRect.Top(); pPt->Y() = Max( lMin, pPt->Y() ); } - else if ( rRect.Top() < aVisArea.Top() ) //Verschiebung nach oben + else if ( rRect.Top() < m_aVisArea.Top() ) //Verschiebung nach oben { pPt->Y() = rRect.Top() - (nRangeY != USHRT_MAX ? nRangeY : nYScroll); pPt->Y() = Max( lMin, pPt->Y() ); } - else if( rRect.Bottom() > aVisArea.Bottom() ) //Verschiebung nach unten + else if( rRect.Bottom() > m_aVisArea.Bottom() ) //Verschiebung nach unten { pPt->Y() = rRect.Bottom() - - (aVisArea.GetHeight()) + ( nRangeY != USHRT_MAX ? + (m_aVisArea.GetHeight()) + ( nRangeY != USHRT_MAX ? nRangeY : nYScroll ); pPt->Y() = SetVScrollMax( pPt->Y() ); } long nXScroll = GetXScroll(); - if ( rRect.Right() > aVisArea.Right() ) //Verschiebung nach rechts + if ( rRect.Right() > m_aVisArea.Right() ) //Verschiebung nach rechts { pPt->X() = rRect.Right() - - (aVisArea.GetWidth()) + + (m_aVisArea.GetWidth()) + (nRangeX != USHRT_MAX ? nRangeX : nXScroll); pPt->X() = SetHScrollMax( pPt->X() ); } - else if ( rRect.Left() < aVisArea.Left() ) //Verschiebung nach links + else if ( rRect.Left() < m_aVisArea.Left() ) //Verschiebung nach links { pPt->X() = rRect.Left() - (nRangeX != USHRT_MAX ? nRangeX : nXScroll); pPt->X() = Max( ::GetLeftMargin( *this ) + nLeftOfst, pPt->X() ); @@ -400,15 +400,15 @@ void SwView::CalcPt( Point *pPt, const Rectangle &rRect, --------------------------------------------------------------------*/ sal_Bool SwView::IsScroll( const Rectangle &rRect ) const { - return bCenterCrsr || bTopCrsr || !aVisArea.IsInside(rRect); + return m_bCenterCrsr || m_bTopCrsr || !m_aVisArea.IsInside(rRect); } void SwView::Scroll( const Rectangle &rRect, sal_uInt16 nRangeX, sal_uInt16 nRangeY ) { - if ( aVisArea.IsEmpty() ) + if ( m_aVisArea.IsEmpty() ) return; - Rectangle aOldVisArea( aVisArea ); + Rectangle aOldVisArea( m_aVisArea ); long nDiffY = 0; Window* pCareWn = ViewShell::GetCareWin(GetWrtShell()); @@ -417,12 +417,12 @@ void SwView::Scroll( const Rectangle &rRect, sal_uInt16 nRangeX, sal_uInt16 nRan Rectangle aDlgRect( GetEditWin().PixelToLogic( pCareWn->GetWindowExtentsRelative( &GetEditWin() ) ) ); // Nur, wenn der Dialog nicht rechts oder links der VisArea liegt: - if ( aDlgRect.Left() < aVisArea.Right() && - aDlgRect.Right() > aVisArea.Left() ) + if ( aDlgRect.Left() < m_aVisArea.Right() && + aDlgRect.Right() > m_aVisArea.Left() ) { // Falls wir nicht zentriert werden sollen, in der VisArea liegen // und nicht vom Dialog ueberdeckt werden ... - if ( !bCenterCrsr && aOldVisArea.IsInside( rRect ) + if ( !m_bCenterCrsr && aOldVisArea.IsInside( rRect ) && ( rRect.Left() > aDlgRect.Right() || rRect.Right() < aDlgRect.Left() || rRect.Top() > aDlgRect.Bottom() @@ -430,39 +430,39 @@ void SwView::Scroll( const Rectangle &rRect, sal_uInt16 nRangeX, sal_uInt16 nRan return; // Ist oberhalb oder unterhalb der Dialogs mehr Platz? - long nTopDiff = aDlgRect.Top() - aVisArea.Top(); - long nBottomDiff = aVisArea.Bottom() - aDlgRect.Bottom(); + long nTopDiff = aDlgRect.Top() - m_aVisArea.Top(); + long nBottomDiff = m_aVisArea.Bottom() - aDlgRect.Bottom(); if ( nTopDiff < nBottomDiff ) { if ( nBottomDiff > 0 ) // Ist unterhalb ueberhaupt Platz? { // dann verschieben wir die Oberkante und merken uns dies - nDiffY = aDlgRect.Bottom() - aVisArea.Top(); - aVisArea.Top() += nDiffY; + nDiffY = aDlgRect.Bottom() - m_aVisArea.Top(); + m_aVisArea.Top() += nDiffY; } } else { if ( nTopDiff > 0 ) // Ist oberhalb ueberhaupt Platz? - aVisArea.Bottom() = aDlgRect.Top(); // Unterkante aendern + m_aVisArea.Bottom() = aDlgRect.Top(); // Unterkante aendern } } } //s.o. !IsScroll() - if( !(bCenterCrsr || bTopCrsr) && aVisArea.IsInside( rRect ) ) + if( !(m_bCenterCrsr || m_bTopCrsr) && m_aVisArea.IsInside( rRect ) ) { - aVisArea = aOldVisArea; + m_aVisArea = aOldVisArea; return; } //falls das Rechteck groesser als der sichtbare Bereich --> //obere linke Ecke Size aSize( rRect.GetSize() ); - const Size aVisSize( aVisArea.GetSize() ); - if( !aVisArea.IsEmpty() && ( + const Size aVisSize( m_aVisArea.GetSize() ); + if( !m_aVisArea.IsEmpty() && ( aSize.Width() + GetXScroll() > aVisSize.Width() || aSize.Height()+ GetYScroll() > aVisSize.Height() )) { - Point aPt( aVisArea.TopLeft() ); + Point aPt( m_aVisArea.TopLeft() ); aSize.Width() = Min( aSize.Width(), aVisSize.Width() ); aSize.Height()= Min( aSize.Height(),aVisSize.Height()); @@ -470,53 +470,53 @@ void SwView::Scroll( const Rectangle &rRect, sal_uInt16 nRangeX, sal_uInt16 nRan static_cast< sal_uInt16 >((aVisSize.Width() - aSize.Width()) / 2), static_cast< sal_uInt16 >((aVisSize.Height()- aSize.Height())/ 2) ); - if( bTopCrsr ) + if( m_bTopCrsr ) { const long nBorder = IsDocumentBorder() ? DOCUMENTBORDER : 0; aPt.Y() = Min( Max( nBorder, rRect.Top() ), - aDocSz.Height() + nBorder - - aVisArea.GetHeight() ); + m_aDocSz.Height() + nBorder - + m_aVisArea.GetHeight() ); } aPt.Y() -= nDiffY; - aVisArea = aOldVisArea; + m_aVisArea = aOldVisArea; SetVisArea( aPt ); return; } - if( !bCenterCrsr ) + if( !m_bCenterCrsr ) { - Point aPt( aVisArea.TopLeft() ); + Point aPt( m_aVisArea.TopLeft() ); CalcPt( &aPt, rRect, nRangeX, nRangeY ); - if( bTopCrsr ) + if( m_bTopCrsr ) { const long nBorder = IsDocumentBorder() ? DOCUMENTBORDER : 0; aPt.Y() = Min( Max( nBorder, rRect.Top() ), - aDocSz.Height() + nBorder - - aVisArea.GetHeight() ); + m_aDocSz.Height() + nBorder - + m_aVisArea.GetHeight() ); } aPt.Y() -= nDiffY; - aVisArea = aOldVisArea; + m_aVisArea = aOldVisArea; SetVisArea( aPt ); return; } //Cursor zentrieren - Point aPnt( aVisArea.TopLeft() ); + Point aPnt( m_aVisArea.TopLeft() ); // ... in Y-Richtung auf jeden Fall aPnt.Y() += ( rRect.Top() + rRect.Bottom() - - aVisArea.Top() - aVisArea.Bottom() ) / 2 - nDiffY; + - m_aVisArea.Top() - m_aVisArea.Bottom() ) / 2 - nDiffY; // ... in X-Richtung nur, wenn das Rechteck rechts oder links aus der // VisArea hinausragt. - if ( rRect.Right() > aVisArea.Right() || rRect.Left() < aVisArea.Left() ) + if ( rRect.Right() > m_aVisArea.Right() || rRect.Left() < m_aVisArea.Left() ) { aPnt.X() += ( rRect.Left() + rRect.Right() - - aVisArea.Left() - aVisArea.Right() ) / 2; + - m_aVisArea.Left() - m_aVisArea.Right() ) / 2; aPnt.X() = SetHScrollMax( aPnt.X() ); const SwTwips lMin = IsDocumentBorder() ? DOCUMENTBORDER : 0; aPnt.X() = Max( (GetLeftMargin( *this ) - lMin) + nLeftOfst, aPnt.X() ); } - aVisArea = aOldVisArea; + m_aVisArea = aOldVisArea; if( pCareWn ) { // Wenn wir nur einem Dialog ausweichen wollen, wollen wir nicht ueber // das Ende des Dokument hinausgehen. @@ -531,30 +531,30 @@ void SwView::Scroll( const Rectangle &rRect, sal_uInt16 nRangeX, sal_uInt16 nRan --------------------------------------------------------------------*/ sal_Bool SwView::GetPageScrollUpOffset( SwTwips &rOff ) const { - if ( !aVisArea.Top() || !aVisArea.GetHeight() ) + if ( !m_aVisArea.Top() || !m_aVisArea.GetHeight() ) return sal_False; long nYScrl = GetYScroll() / 2; - rOff = -(aVisArea.GetHeight() - nYScrl); + rOff = -(m_aVisArea.GetHeight() - nYScrl); //nicht vor den Dokumentanfang scrollen - if( aVisArea.Top() - rOff < 0 ) - rOff = rOff - aVisArea.Top(); - else if( GetWrtShell().GetCharRect().Top() < (aVisArea.Top() + nYScrl)) + if( m_aVisArea.Top() - rOff < 0 ) + rOff = rOff - m_aVisArea.Top(); + else if( GetWrtShell().GetCharRect().Top() < (m_aVisArea.Top() + nYScrl)) rOff += nYScrl; return sal_True; } sal_Bool SwView::GetPageScrollDownOffset( SwTwips &rOff ) const { - if ( !aVisArea.GetHeight() || - (aVisArea.GetHeight() > aDocSz.Height()) ) + if ( !m_aVisArea.GetHeight() || + (m_aVisArea.GetHeight() > m_aDocSz.Height()) ) return sal_False; long nYScrl = GetYScroll() / 2; - rOff = aVisArea.GetHeight() - nYScrl; + rOff = m_aVisArea.GetHeight() - nYScrl; //nicht hinter das Dokumentende scrollen - if ( aVisArea.Top() + rOff > aDocSz.Height() ) - rOff = aDocSz.Height() - aVisArea.Bottom(); + if ( m_aVisArea.Top() + rOff > m_aDocSz.Height() ) + rOff = m_aDocSz.Height() - m_aVisArea.Bottom(); else if( GetWrtShell().GetCharRect().Bottom() > - ( aVisArea.Bottom() - nYScrl )) + ( m_aVisArea.Bottom() - nYScrl )) rOff -= nYScrl; return rOff > 0; } @@ -562,11 +562,11 @@ sal_Bool SwView::GetPageScrollDownOffset( SwTwips &rOff ) const // Seitenweises Blaettern long SwView::PageUp() { - if (!aVisArea.GetHeight()) + if (!m_aVisArea.GetHeight()) return 0; - Point aPos(aVisArea.TopLeft()); - aPos.Y() -= aVisArea.GetHeight() - (GetYScroll() / 2); + Point aPos(m_aVisArea.TopLeft()); + aPos.Y() -= m_aVisArea.GetHeight() - (GetYScroll() / 2); aPos.Y() = Max(0L, aPos.Y()); SetVisArea( aPos ); return 1; @@ -574,10 +574,10 @@ long SwView::PageUp() long SwView::PageDown() { - if ( !aVisArea.GetHeight() ) + if ( !m_aVisArea.GetHeight() ) return 0; - Point aPos( aVisArea.TopLeft() ); - aPos.Y() += aVisArea.GetHeight() - (GetYScroll() / 2); + Point aPos( m_aVisArea.TopLeft() ); + aPos.Y() += m_aVisArea.GetHeight() - (GetYScroll() / 2); aPos.Y() = SetVScrollMax( aPos.Y() ); SetVisArea( aPos ); return 1; @@ -586,12 +586,12 @@ long SwView::PageDown() long SwView::PhyPageUp() { //aktuell sichtbare Seite erfragen, nicht formatieren - sal_uInt16 nActPage = pWrtShell->GetNextPrevPageNum( sal_False ); + sal_uInt16 nActPage = m_pWrtShell->GetNextPrevPageNum( sal_False ); if( USHRT_MAX != nActPage ) { - const Point aPt( aVisArea.Left(), - pWrtShell->GetPagePos( nActPage ).Y() ); + const Point aPt( m_aVisArea.Left(), + m_pWrtShell->GetPagePos( nActPage ).Y() ); Point aAlPt( AlignToPixel( aPt ) ); // falls ein Unterschied besteht, wurde abgeschnitten --> dann // einen Pixel addieren, damit kein Rest der Vorgaengerseite @@ -606,12 +606,12 @@ long SwView::PhyPageUp() long SwView::PhyPageDown() { //aktuell sichtbare Seite erfragen, nicht formatieren - sal_uInt16 nActPage = pWrtShell->GetNextPrevPageNum( sal_True ); + sal_uInt16 nActPage = m_pWrtShell->GetNextPrevPageNum( sal_True ); // falls die letzte Dokumentseite sichtbar ist, nichts tun if( USHRT_MAX != nActPage ) { - const Point aPt( aVisArea.Left(), - pWrtShell->GetPagePos( nActPage ).Y() ); + const Point aPt( m_aVisArea.Left(), + m_pWrtShell->GetPagePos( nActPage ).Y() ); Point aAlPt( AlignToPixel( aPt ) ); // falls ein Unterschied besteht, wurde abgeschnitten --> dann // einen Pixel addieren, damit kein Rest der Vorgaengerseite sichtbar ist @@ -626,23 +626,23 @@ long SwView::PageUpCrsr( sal_Bool bSelect ) { if ( !bSelect ) { - const sal_uInt16 eType = pWrtShell->GetFrmType(0,sal_True); + const sal_uInt16 eType = m_pWrtShell->GetFrmType(0,sal_True); if ( eType & FRMTYPE_FOOTNOTE ) { - pWrtShell->MoveCrsr(); - pWrtShell->GotoFtnAnchor(); - pWrtShell->Right(CRSR_SKIP_CHARS, sal_False, 1, sal_False ); + m_pWrtShell->MoveCrsr(); + m_pWrtShell->GotoFtnAnchor(); + m_pWrtShell->Right(CRSR_SKIP_CHARS, sal_False, 1, sal_False ); return 1; } } SwTwips lOff = 0; if ( GetPageScrollUpOffset( lOff ) && - (pWrtShell->IsCrsrReadonly() || - !pWrtShell->PageCrsr( lOff, bSelect )) && + (m_pWrtShell->IsCrsrReadonly() || + !m_pWrtShell->PageCrsr( lOff, bSelect )) && PageUp() ) { - pWrtShell->ResetCursorStack(); + m_pWrtShell->ResetCursorStack(); return sal_True; } return sal_False; @@ -652,11 +652,11 @@ long SwView::PageDownCrsr(sal_Bool bSelect) { SwTwips lOff = 0; if ( GetPageScrollDownOffset( lOff ) && - (pWrtShell->IsCrsrReadonly() || - !pWrtShell->PageCrsr( lOff, bSelect )) && + (m_pWrtShell->IsCrsrReadonly() || + !m_pWrtShell->PageCrsr( lOff, bSelect )) && PageDown() ) { - pWrtShell->ResetCursorStack(); + m_pWrtShell->ResetCursorStack(); return sal_True; } return sal_False; @@ -671,9 +671,9 @@ IMPL_LINK( SwView, ScrollHdl, SwScrollbar *, pScrollbar ) return 0; if ( pScrollbar->GetType() == SCROLL_DRAG ) - pWrtShell->EnableSmooth( sal_False ); + m_pWrtShell->EnableSmooth( sal_False ); - if(!pWrtShell->GetViewOptions()->getBrowseMode() && + if(!m_pWrtShell->GetViewOptions()->getBrowseMode() && pScrollbar->GetType() == SCROLL_DRAG) { //Hier wieder auskommentieren wenn das mitscrollen nicht gewuenscht ist. @@ -681,18 +681,18 @@ IMPL_LINK( SwView, ScrollHdl, SwScrollbar *, pScrollbar ) // so we dont must do it agin. EndScrollHdl(pScrollbar); - Point aPos( aVisArea.TopLeft() ); + Point aPos( m_aVisArea.TopLeft() ); lcl_GetPos(this, aPos, pScrollbar, IsDocumentBorder()); sal_uInt16 nPhNum = 1; sal_uInt16 nVirtNum = 1; String sDisplay; - if(pWrtShell->GetPageNumber( aPos.Y(), sal_False, nPhNum, nVirtNum, sDisplay )) + if(m_pWrtShell->GetPageNumber( aPos.Y(), sal_False, nPhNum, nVirtNum, sDisplay )) { //QuickHelp: - if( !mbWheelScrollInProgress && pWrtShell->GetPageCnt() > 1 && Help::IsQuickHelpEnabled() ) + if( !m_bWheelScrollInProgress && m_pWrtShell->GetPageCnt() > 1 && Help::IsQuickHelpEnabled() ) { if( !nPgNum || nPgNum != nPhNum ) { @@ -706,7 +706,7 @@ IMPL_LINK( SwView, ScrollHdl, SwScrollbar *, pScrollbar ) String sPageStr( GetPageStr( nPhNum, nVirtNum, sDisplay )); SwContentAtPos aCnt( SwContentAtPos::SW_OUTLINE ); - pWrtShell->GetContentAtPos( aPos, aCnt ); + m_pWrtShell->GetContentAtPos( aPos, aCnt ); if( aCnt.sStr.Len() ) { sPageStr += rtl::OUString(" - "); @@ -726,7 +726,7 @@ IMPL_LINK( SwView, ScrollHdl, SwScrollbar *, pScrollbar ) EndScrollHdl(pScrollbar); if ( pScrollbar->GetType() == SCROLL_DRAG ) - pWrtShell->EnableSmooth( sal_True ); + m_pWrtShell->EnableSmooth( sal_True ); return 0; } @@ -743,10 +743,10 @@ IMPL_LINK( SwView, EndScrollHdl, SwScrollbar *, pScrollbar ) nPgNum = 0; Help::ShowQuickHelp(pScrollbar, Rectangle(), aEmptyStr, 0); } - Point aPos( aVisArea.TopLeft() ); + Point aPos( m_aVisArea.TopLeft() ); sal_Bool bBorder = IsDocumentBorder(); lcl_GetPos(this, aPos, pScrollbar, bBorder); - if ( bBorder && aPos == aVisArea.TopLeft() ) + if ( bBorder && aPos == m_aVisArea.TopLeft() ) UpdateScrollbars(); else SetVisArea( aPos, sal_False ); @@ -758,7 +758,7 @@ IMPL_LINK( SwView, EndScrollHdl, SwScrollbar *, pScrollbar ) /*-------------------------------------------------------------------- Beschreibung: - berechnet die Groesse von aVisArea abhaengig von der Groesse + berechnet die Groesse von m_aVisArea abhaengig von der Groesse des EditWin auf dem Schirm. --------------------------------------------------------------------*/ void SwView::CalcVisArea( const Size &rOutPixel ) @@ -806,30 +806,30 @@ void SwView::CalcVisArea( const Size &rOutPixel ) --------------------------------------------------------------------*/ void SwView::CalcAndSetBorderPixel( SvBorder &rToFill, sal_Bool /*bInner*/ ) { - sal_Bool bRightVRuler = pWrtShell->GetViewOptions()->IsVRulerRight(); - if ( pVRuler->IsVisible() ) + sal_Bool bRightVRuler = m_pWrtShell->GetViewOptions()->IsVRulerRight(); + if ( m_pVRuler->IsVisible() ) { - long nWidth = pVRuler->GetSizePixel().Width(); + long nWidth = m_pVRuler->GetSizePixel().Width(); if(bRightVRuler) rToFill.Right() = nWidth; else rToFill.Left() = nWidth; } - OSL_ENSURE(pHRuler, "warum ist das Lineal nicht da?"); - if ( pHRuler->IsVisible() ) - rToFill.Top() = pHRuler->GetSizePixel().Height(); + OSL_ENSURE(m_pHRuler, "warum ist das Lineal nicht da?"); + if ( m_pHRuler->IsVisible() ) + rToFill.Top() = m_pHRuler->GetSizePixel().Height(); const StyleSettings &rSet = GetEditWin().GetSettings().GetStyleSettings(); const long nTmp = rSet.GetScrollBarSize(); - if( pVScrollbar->IsVisible(sal_True) ) + if( m_pVScrollbar->IsVisible(sal_True) ) { if(bRightVRuler) rToFill.Left() = nTmp; else rToFill.Right() = nTmp; } - if ( pHScrollbar->IsVisible(sal_True) ) + if ( m_pHScrollbar->IsVisible(sal_True) ) rToFill.Bottom() = nTmp; SetBorderPixel( rToFill ); @@ -962,9 +962,9 @@ void ViewResizePixel( const Window &rRef, void SwView::ShowAtResize() { - bShowAtResize = sal_False; - if ( pWrtShell->GetViewOptions()->IsViewHRuler() ) - pHRuler->Show(); + m_bShowAtResize = sal_False; + if ( m_pWrtShell->GetViewOptions()->IsViewHRuler() ) + m_pHRuler->Show(); } void SwView::InnerResizePixel( const Point &rOfst, const Size &rSize ) @@ -981,9 +981,9 @@ void SwView::InnerResizePixel( const Point &rOfst, const Size &rSize ) Fraction( aSize.Height(), aObjSizePixel.Height() ) ); } - bInInnerResizePixel = sal_True; - const sal_Bool bHScrollVisible = pHScrollbar->IsVisible(sal_True); - const sal_Bool bVScrollVisible = pVScrollbar->IsVisible(sal_True); + m_bInInnerResizePixel = sal_True; + const sal_Bool bHScrollVisible = m_pHScrollbar->IsVisible(sal_True); + const sal_Bool bVScrollVisible = m_pVScrollbar->IsVisible(sal_True); sal_Bool bRepeat = sal_False; do { @@ -1007,16 +1007,16 @@ void SwView::InnerResizePixel( const Point &rOfst, const Size &rSize ) } Size aEditSz( GetEditWin().GetOutputSizePixel() ); - ViewResizePixel( GetEditWin(), rOfst, aSz, aEditSz, sal_True, *pVScrollbar, - *pHScrollbar, pPageUpBtn, pPageDownBtn, - pNaviBtn, - *pScrollFill, pVRuler, pHRuler, + ViewResizePixel( GetEditWin(), rOfst, aSz, aEditSz, sal_True, *m_pVScrollbar, + *m_pHScrollbar, m_pPageUpBtn, m_pPageDownBtn, + m_pNaviBtn, + *m_pScrollFill, m_pVRuler, m_pHRuler, 0 != PTR_CAST(SwWebView, this), - pWrtShell->GetViewOptions()->IsVRulerRight()); - if ( bShowAtResize ) + m_pWrtShell->GetViewOptions()->IsVRulerRight()); + if ( m_bShowAtResize ) ShowAtResize(); - if( pHRuler->IsVisible() || pVRuler->IsVisible() ) + if( m_pHRuler->IsVisible() || m_pVRuler->IsVisible() ) { const Fraction& rFrac = GetEditWin().GetMapMode().GetScaleX(); sal_uInt16 nZoom = 100; @@ -1024,13 +1024,13 @@ void SwView::InnerResizePixel( const Point &rOfst, const Size &rSize ) nZoom = sal_uInt16(rFrac.GetNumerator() * 100L / rFrac.GetDenominator()); const Fraction aFrac( nZoom, 100 ); - pVRuler->SetZoom( aFrac ); - pHRuler->SetZoom( aFrac ); + m_pVRuler->SetZoom( aFrac ); + m_pHRuler->SetZoom( aFrac ); InvalidateRulerPos(); //Inhalt invalidieren. } //CursorStack zuruecksetzen, da die Cursorpositionen fuer PageUp/-Down //nicht mehr zum aktuell sichtbaren Bereich passen - pWrtShell->ResetCursorStack(); + m_pWrtShell->ResetCursorStack(); //EditWin niemals einstellen! @@ -1041,20 +1041,20 @@ void SwView::InnerResizePixel( const Point &rOfst, const Size &rSize ) //require to repeat the ViewResizePixel() call - but only once! if(bRepeat) bRepeat = sal_False; - else if(bHScrollVisible != pHScrollbar->IsVisible(sal_True) || - bVScrollVisible != pVScrollbar->IsVisible(sal_True)) + else if(bHScrollVisible != m_pHScrollbar->IsVisible(sal_True) || + bVScrollVisible != m_pVScrollbar->IsVisible(sal_True)) bRepeat = sal_True; }while( bRepeat ); bProtectDocShellVisArea = sal_False; - bInInnerResizePixel = sal_False; + m_bInInnerResizePixel = sal_False; } void SwView::OuterResizePixel( const Point &rOfst, const Size &rSize ) { // #i16909# return, if no size (caused by minimize window). - if ( bInOuterResizePixel || ( !rSize.Width() && !rSize.Height() ) ) + if ( m_bInOuterResizePixel || ( !rSize.Width() && !rSize.Height() ) ) return; - bInOuterResizePixel = sal_True; + m_bInOuterResizePixel = sal_True; #if !defined(ANDROID) && !defined(IOS) // feststellen, ob Scrollbars angezeigt werden duerfen @@ -1063,18 +1063,18 @@ void SwView::OuterResizePixel( const Point &rOfst, const Size &rSize ) bAuto = sal_True, bHAuto = sal_True; - const SwViewOption *pVOpt = pWrtShell->GetViewOptions(); + const SwViewOption *pVOpt = m_pWrtShell->GetViewOptions(); if ( !pVOpt->IsReadonly() || pVOpt->IsStarOneSetting() ) { bShowH = pVOpt->IsViewHScrollBar(); bShowV = pVOpt->IsViewVScrollBar(); } - if (!mbHScrollbarEnabled) + if (!m_bHScrollbarEnabled) { bHAuto = bShowH = false; } - if (!mbVScrollbarEnabled) + if (!m_bVScrollbarEnabled) { bAuto = bShowV = false; } @@ -1085,57 +1085,57 @@ void SwView::OuterResizePixel( const Point &rOfst, const Size &rSize ) { bShowH = bShowV = bHAuto = bAuto = sal_False; } - if(pHScrollbar->IsVisible(sal_False) != bShowH && !bHAuto) + if(m_pHScrollbar->IsVisible(sal_False) != bShowH && !bHAuto) ShowHScrollbar(bShowH); - pHScrollbar->SetAuto( bHAuto ); - if(pVScrollbar->IsVisible(sal_False) != bShowV && !bAuto) + m_pHScrollbar->SetAuto( bHAuto ); + if(m_pVScrollbar->IsVisible(sal_False) != bShowV && !bAuto) ShowVScrollbar(bShowV); - pVScrollbar->SetAuto(bAuto); + m_pVScrollbar->SetAuto(bAuto); #else const sal_Bool bAuto = sal_False; const sal_Bool bHAuto = sal_False; #endif - SET_CURR_SHELL( pWrtShell ); + SET_CURR_SHELL( m_pWrtShell ); sal_Bool bRepeat = sal_False; long nCnt = 0; - sal_Bool bUnLockView = !pWrtShell->IsViewLocked(); - pWrtShell->LockView( sal_True ); - pWrtShell->LockPaint(); + sal_Bool bUnLockView = !m_pWrtShell->IsViewLocked(); + m_pWrtShell->LockView( sal_True ); + m_pWrtShell->LockPaint(); do { ++nCnt; - const sal_Bool bScroll1 = pVScrollbar->IsVisible(sal_True); - const sal_Bool bScroll2 = pHScrollbar->IsVisible(sal_True); + const sal_Bool bScroll1 = m_pVScrollbar->IsVisible(sal_True); + const sal_Bool bScroll2 = m_pHScrollbar->IsVisible(sal_True); SvBorder aBorder; CalcAndSetBorderPixel( aBorder, sal_False ); const Size aEditSz( GetEditWin().GetOutputSizePixel() ); - ViewResizePixel( GetEditWin(), rOfst, rSize, aEditSz, sal_False, *pVScrollbar, - *pHScrollbar, pPageUpBtn, pPageDownBtn, - pNaviBtn, - *pScrollFill, pVRuler, pHRuler, + ViewResizePixel( GetEditWin(), rOfst, rSize, aEditSz, sal_False, *m_pVScrollbar, + *m_pHScrollbar, m_pPageUpBtn, m_pPageDownBtn, + m_pNaviBtn, + *m_pScrollFill, m_pVRuler, m_pHRuler, 0 != PTR_CAST(SwWebView, this), - pWrtShell->GetViewOptions()->IsVRulerRight() ); - if ( bShowAtResize ) + m_pWrtShell->GetViewOptions()->IsVRulerRight() ); + if ( m_bShowAtResize ) ShowAtResize(); - if( pHRuler->IsVisible() || pVRuler->IsVisible() ) + if( m_pHRuler->IsVisible() || m_pVRuler->IsVisible() ) InvalidateRulerPos(); //Inhalt invalidieren. //CursorStack zuruecksetzen, da die Cursorpositionen fuer PageUp/-Down //nicht mehr zum aktuell sichtbaren Bereich passen - pWrtShell->ResetCursorStack(); + m_pWrtShell->ResetCursorStack(); OSL_ENSURE( !GetEditWin().IsVisible() || (( aEditSz.Width() > 0 && aEditSz.Height() > 0 ) - || !aVisArea.IsEmpty()), "Small world, isn't it?" ); + || !m_aVisArea.IsEmpty()), "Small world, isn't it?" ); //EditWin niemals einstellen! //Die VisArea muss aber natuerlich eingestellt werden. //jetzt ist auch der richtige Zeitpunkt den Zoom neu zu berechnen wenn //es kein einfacher Faktor ist. - pWrtShell->StartAction(); + m_pWrtShell->StartAction(); CalcVisArea( aEditSz ); //Damit auch beim outplace editing die Seitenbreite sofort @@ -1145,14 +1145,14 @@ void SwView::OuterResizePixel( const Point &rOfst, const Size &rSize ) if ( pDocSh->GetCreateMode() == SFX_CREATE_MODE_EMBEDDED ) pDocSh->SetVisArea( pDocSh->SfxInPlaceObject::GetVisArea() );*/ - if ( pWrtShell->GetViewOptions()->GetZoomType() != SVX_ZOOM_PERCENT && - !pWrtShell->GetViewOptions()->getBrowseMode() ) - _SetZoom( aEditSz, (SvxZoomType)pWrtShell->GetViewOptions()->GetZoomType(), 100, sal_True ); - pWrtShell->EndAction(); + if ( m_pWrtShell->GetViewOptions()->GetZoomType() != SVX_ZOOM_PERCENT && + !m_pWrtShell->GetViewOptions()->getBrowseMode() ) + _SetZoom( aEditSz, (SvxZoomType)m_pWrtShell->GetViewOptions()->GetZoomType(), 100, sal_True ); + m_pWrtShell->EndAction(); - bRepeat = bScroll1 != pVScrollbar->IsVisible(sal_True); + bRepeat = bScroll1 != m_pVScrollbar->IsVisible(sal_True); if ( !bRepeat ) - bRepeat = bScroll2 != pHScrollbar->IsVisible(sal_True); + bRepeat = bScroll2 != m_pHScrollbar->IsVisible(sal_True); //Nicht endlosschleifen. Moeglichst dann stoppen wenn die //(Auto-)Scrollbars sichtbar sind. @@ -1165,29 +1165,29 @@ void SwView::OuterResizePixel( const Point &rOfst, const Size &rSize ) }while ( bRepeat ); - if( pVScrollbar->IsVisible(sal_False) || pVScrollbar->IsAuto()) + if( m_pVScrollbar->IsVisible(sal_False) || m_pVScrollbar->IsAuto()) { - sal_Bool bShowButtons = pVScrollbar->IsVisible(sal_True); - if(pPageUpBtn && pPageUpBtn->IsVisible() != bShowButtons) + sal_Bool bShowButtons = m_pVScrollbar->IsVisible(sal_True); + if(m_pPageUpBtn && m_pPageUpBtn->IsVisible() != bShowButtons) { - pPageUpBtn->Show(bShowButtons); - if(pPageDownBtn) - pPageDownBtn->Show(bShowButtons); - if(pNaviBtn) - pNaviBtn->Show(bShowButtons); + m_pPageUpBtn->Show(bShowButtons); + if(m_pPageDownBtn) + m_pPageDownBtn->Show(bShowButtons); + if(m_pNaviBtn) + m_pNaviBtn->Show(bShowButtons); } } - pWrtShell->UnlockPaint(); + m_pWrtShell->UnlockPaint(); if( bUnLockView ) - pWrtShell->LockView( sal_False ); + m_pWrtShell->LockView( sal_False ); - bInOuterResizePixel = sal_False; + m_bInOuterResizePixel = sal_False; - if ( mpPostItMgr ) + if ( m_pPostItMgr ) { - mpPostItMgr->CalcRects(); - mpPostItMgr->LayoutPostIts(); + m_pPostItMgr->CalcRects(); + m_pPostItMgr->LayoutPostIts(); } } @@ -1207,10 +1207,10 @@ sal_Bool SwView::UpdateScrollbars() return sal_True; #else sal_Bool bRet = sal_False; - if ( !aVisArea.IsEmpty() ) + if ( !m_aVisArea.IsEmpty() ) { const sal_Bool bBorder = IsDocumentBorder(); - Rectangle aTmpRect( aVisArea ); + Rectangle aTmpRect( m_aVisArea ); if ( bBorder ) { Point aPt( DOCUMENTBORDER, DOCUMENTBORDER ); @@ -1218,35 +1218,35 @@ sal_Bool SwView::UpdateScrollbars() aTmpRect.Move( -aPt.X(), -aPt.Y() ); } - Size aTmpSz( aDocSz ); + Size aTmpSz( m_aDocSz ); const long lOfst = bBorder ? 0 : DOCUMENTBORDER * 2L; aTmpSz.Width() += lOfst; aTmpSz.Height() += lOfst; { - const sal_Bool bVScrollVisible = pVScrollbar->IsVisible(sal_True); - pVScrollbar->DocSzChgd( aTmpSz ); - pVScrollbar->ViewPortChgd( aTmpRect ); + const sal_Bool bVScrollVisible = m_pVScrollbar->IsVisible(sal_True); + m_pVScrollbar->DocSzChgd( aTmpSz ); + m_pVScrollbar->ViewPortChgd( aTmpRect ); - sal_Bool bShowButtons = pVScrollbar->IsVisible(sal_True); - if(pPageUpBtn && pPageUpBtn->IsVisible() != bShowButtons) + sal_Bool bShowButtons = m_pVScrollbar->IsVisible(sal_True); + if(m_pPageUpBtn && m_pPageUpBtn->IsVisible() != bShowButtons) { - pPageUpBtn->Show(bShowButtons); - if(pPageDownBtn) - pPageDownBtn->Show(bShowButtons); - if(pNaviBtn) - pNaviBtn->Show(bShowButtons); + m_pPageUpBtn->Show(bShowButtons); + if(m_pPageDownBtn) + m_pPageDownBtn->Show(bShowButtons); + if(m_pNaviBtn) + m_pNaviBtn->Show(bShowButtons); } - if ( bVScrollVisible != pVScrollbar->IsVisible(sal_True) ) + if ( bVScrollVisible != m_pVScrollbar->IsVisible(sal_True) ) bRet = sal_True; } { - const sal_Bool bHScrollVisible = pHScrollbar->IsVisible(sal_True); - pHScrollbar->DocSzChgd( aTmpSz ); - pHScrollbar->ViewPortChgd( aTmpRect ); - if ( bHScrollVisible != pHScrollbar->IsVisible(sal_True) ) + const sal_Bool bHScrollVisible = m_pHScrollbar->IsVisible(sal_True); + m_pHScrollbar->DocSzChgd( aTmpSz ); + m_pHScrollbar->ViewPortChgd( aTmpRect ); + if ( bHScrollVisible != m_pHScrollbar->IsVisible(sal_True) ) bRet = sal_True; - pScrollFill->Show(pHScrollbar->IsVisible(sal_True) && pVScrollbar->IsVisible(sal_True) ); + m_pScrollFill->Show(m_pHScrollbar->IsVisible(sal_True) && m_pVScrollbar->IsVisible(sal_True) ); } } return bRet; @@ -1266,7 +1266,7 @@ sal_Bool SwView::HandleWheelCommands( const CommandEvent& rCEvt ) const CommandWheelData* pWData = rCEvt.GetWheelData(); if( pWData && COMMAND_WHEEL_ZOOM == pWData->GetMode() ) { - long nFact = pWrtShell->GetViewOptions()->GetZoom(); + long nFact = m_pWrtShell->GetViewOptions()->GetZoom(); if( 0L > pWData->GetDelta() ) nFact = Max( (long) 20, basegfx::zoomtools::zoomOut( nFact )); else @@ -1277,7 +1277,7 @@ sal_Bool SwView::HandleWheelCommands( const CommandEvent& rCEvt ) } else if( pWData && COMMAND_WHEEL_ZOOM_SCALE == pWData->GetMode() ) { - int newZoom = 100 * (pWrtShell->GetViewOptions()->GetZoom() / 100.0) * (pWData->GetDelta() / 100.0); + int newZoom = 100 * (m_pWrtShell->GetViewOptions()->GetZoom() / 100.0) * (pWData->GetDelta() / 100.0); SetZoom( SVX_ZOOM_PERCENT, Max( 20, Min( 600, newZoom ) ) ); bOk = sal_True; } @@ -1286,7 +1286,7 @@ sal_Bool SwView::HandleWheelCommands( const CommandEvent& rCEvt ) if(pWData->GetMode()==COMMAND_WHEEL_SCROLL) { // This influences whether quick help is shown - mbWheelScrollInProgress=true; + m_bWheelScrollInProgress=true; } if (pWData && (COMMAND_WHEEL_SCROLL==pWData->GetMode()) && (((sal_uLong)0xFFFFFFFF) == pWData->GetScrollLines())) @@ -1298,11 +1298,11 @@ sal_Bool SwView::HandleWheelCommands( const CommandEvent& rCEvt ) bOk = sal_True; } else - bOk = pEditWin->HandleScrollCommand( rCEvt, - pHScrollbar, pVScrollbar); + bOk = m_pEditWin->HandleScrollCommand( rCEvt, + m_pHScrollbar, m_pVScrollbar); // Restore default state for case when scroll command comes from dragging scrollbar handle - mbWheelScrollInProgress=false; + m_bWheelScrollInProgress=false; } return bOk; } diff --git a/sw/source/ui/uiview/viewsrch.cxx b/sw/source/ui/uiview/viewsrch.cxx index b6a6d68d32dd..7802df1bd0ad 100644 --- a/sw/source/ui/uiview/viewsrch.cxx +++ b/sw/source/ui/uiview/viewsrch.cxx @@ -78,19 +78,19 @@ struct SwSearchOptions }; -inline Window* GetParentWindow( SvxSearchDialog* pSrchDlg ) +inline Window* GetParentWindow( SvxSearchDialog* m_pSrchDlg ) { Window* pWin; - if( pSrchDlg && pSrchDlg->IsVisible() ) - pWin = pSrchDlg; + if( m_pSrchDlg && m_pSrchDlg->IsVisible() ) + pWin = m_pSrchDlg; else pWin = 0; return pWin; } -inline void ShowNotFoundInfoBox( SvxSearchDialog* pSrchDlg ) +inline void ShowNotFoundInfoBox( SvxSearchDialog* m_pSrchDlg ) { - Window* pParentWindow = GetParentWindow( pSrchDlg ); + Window* pParentWindow = GetParentWindow( m_pSrchDlg ); InfoBox aBox( pParentWindow, SW_RES(MSG_NOT_FOUND)); if (pParentWindow) { @@ -116,7 +116,7 @@ void SwView::ExecSearch(SfxRequest& rReq, sal_Bool bNoMessage) sal_Bool bApi = bQuiet | bNoMessage; sal_uInt16 nSlot = rReq.GetSlot(); - if (nSlot == FN_REPEAT_SEARCH && !pSrchItem) + if (nSlot == FN_REPEAT_SEARCH && !m_pSrchItem) { if(bApi) { @@ -124,20 +124,20 @@ void SwView::ExecSearch(SfxRequest& rReq, sal_Bool bNoMessage) nSlot = 0; } } - if( pWrtShell->IsBlockMode() ) - pWrtShell->LeaveBlockMode(); + if( m_pWrtShell->IsBlockMode() ) + m_pWrtShell->LeaveBlockMode(); switch (nSlot) { // erstmal Nichts tun case SID_SEARCH_ITEM: { - delete pSrchItem; - pSrchItem = (SvxSearchItem*) pArgs->Get(SID_SEARCH_ITEM).Clone(); + delete m_pSrchItem; + m_pSrchItem = (SvxSearchItem*) pArgs->Get(SID_SEARCH_ITEM).Clone(); } break; case FID_SEARCH_ON: - bJustOpened = true; + m_bJustOpened = true; GetViewFrame()->GetBindings().Invalidate(SID_SEARCH_ITEM); break; @@ -145,23 +145,23 @@ void SwView::ExecSearch(SfxRequest& rReq, sal_Bool bNoMessage) if(pArgs) { // Dialog abmelden - delete pSrchItem; - pSrchItem = (SvxSearchItem*) pArgs->Get(SID_SEARCH_ITEM).Clone(); + delete m_pSrchItem; + m_pSrchItem = (SvxSearchItem*) pArgs->Get(SID_SEARCH_ITEM).Clone(); - DELETEZ( pSrchList ); - DELETEZ( pReplList ); + DELETEZ( m_pSrchList ); + DELETEZ( m_pReplList ); if ( pWrp ) { - pSrchDlg = static_cast <SvxSearchDialog*> (pWrp->getDialog ()); + m_pSrchDlg = static_cast <SvxSearchDialog*> (pWrp->getDialog ()); // die Search / Replace -Items merken wir uns - const SearchAttrItemList* pList = pSrchDlg->GetSearchItemList(); + const SearchAttrItemList* pList = m_pSrchDlg->GetSearchItemList(); if( pList && pList->Count() ) - pSrchList = new SearchAttrItemList( *pList ); + m_pSrchList = new SearchAttrItemList( *pList ); - if( 0 != (pList = pSrchDlg->GetReplaceItemList() ) && + if( 0 != (pList = m_pSrchDlg->GetReplaceItemList() ) && pList->Count() ) - pReplList = new SearchAttrItemList( *pList ); + m_pReplList = new SearchAttrItemList( *pList ); } } break; @@ -174,31 +174,31 @@ void SwView::ExecSearch(SfxRequest& rReq, sal_Bool bNoMessage) SwView::SetMoveType(NID_SRCH_REP); if ( pWrp ) { - pSrchDlg = static_cast <SvxSearchDialog*> (pWrp->getDialog ()); + m_pSrchDlg = static_cast <SvxSearchDialog*> (pWrp->getDialog ()); } else - pSrchDlg = 0; + m_pSrchDlg = 0; } - if (pSrchDlg) + if (m_pSrchDlg) { - DELETEZ( pSrchList ); - DELETEZ( pReplList ); + DELETEZ( m_pSrchList ); + DELETEZ( m_pReplList ); - const SearchAttrItemList* pList = pSrchDlg->GetSearchItemList(); + const SearchAttrItemList* pList = m_pSrchDlg->GetSearchItemList(); if( pList && pList->Count() ) - pSrchList = new SearchAttrItemList( *pList ); + m_pSrchList = new SearchAttrItemList( *pList ); - if( 0 != (pList = pSrchDlg->GetReplaceItemList() ) && + if( 0 != (pList = m_pSrchDlg->GetReplaceItemList() ) && pList->Count() ) - pReplList = new SearchAttrItemList( *pList ); + m_pReplList = new SearchAttrItemList( *pList ); } if (nSlot == FN_REPEAT_SEARCH) { - OSL_ENSURE(pSrchItem, "SearchItem missing"); - if( !pSrchItem ) - pSrchItem = new SvxSearchItem(SID_SEARCH_ITEM); + OSL_ENSURE(m_pSrchItem, "SearchItem missing"); + if( !m_pSrchItem ) + m_pSrchItem = new SvxSearchItem(SID_SEARCH_ITEM); } else { @@ -206,17 +206,17 @@ void SwView::ExecSearch(SfxRequest& rReq, sal_Bool bNoMessage) OSL_ENSURE(pArgs, "Args missing"); if ( pArgs ) { - delete pSrchItem; - pSrchItem = (SvxSearchItem*) pArgs->Get(SID_SEARCH_ITEM).Clone(); + delete m_pSrchItem; + m_pSrchItem = (SvxSearchItem*) pArgs->Get(SID_SEARCH_ITEM).Clone(); } } - switch (pSrchItem->GetCommand()) + switch (m_pSrchItem->GetCommand()) { case SVX_SEARCHCMD_FIND: { sal_Bool bRet = SearchAndWrap(bApi); if( bRet ) - Scroll(pWrtShell->GetCharRect().SVRect()); + Scroll(m_pWrtShell->GetCharRect().SVRect()); rReq.SetReturnValue(SfxBoolItem(nSlot, bRet)); } break; @@ -227,9 +227,9 @@ void SwView::ExecSearch(SfxRequest& rReq, sal_Bool bNoMessage) { if( !bApi ) { - ShowNotFoundInfoBox( pSrchDlg ); + ShowNotFoundInfoBox( m_pSrchDlg ); } - bFound = sal_False; + m_bFound = sal_False; } rReq.SetReturnValue(SfxBoolItem(nSlot, bRet)); } @@ -243,82 +243,82 @@ void SwView::ExecSearch(SfxRequest& rReq, sal_Bool bNoMessage) // was ist, wenn man das gefundene nur attributieren will?? sal_uInt16 nCmd = SVX_SEARCHCMD_FIND; - if( pSrchItem->GetReplaceString().Len() || - !pReplList ) + if( m_pSrchItem->GetReplaceString().Len() || + !m_pReplList ) { // Verhindern, dass - falls der Suchstring im // Ersetzungsstring enthalten ist - der ersetzte String // noch einmal gefunden wird. - sal_Bool bBack = pSrchItem->GetBackward(); + sal_Bool bBack = m_pSrchItem->GetBackward(); if (bBack) - pWrtShell->Push(); - String aReplace( pSrchItem->GetReplaceString() ); - SearchOptions aTmp( pSrchItem->GetSearchOptions() ); - String *pBackRef = ReplaceBackReferences( aTmp, pWrtShell->GetCrsr() ); + m_pWrtShell->Push(); + String aReplace( m_pSrchItem->GetReplaceString() ); + SearchOptions aTmp( m_pSrchItem->GetSearchOptions() ); + String *pBackRef = ReplaceBackReferences( aTmp, m_pWrtShell->GetCrsr() ); if( pBackRef ) - pSrchItem->SetReplaceString( *pBackRef ); + m_pSrchItem->SetReplaceString( *pBackRef ); Replace(); if( pBackRef ) { - pSrchItem->SetReplaceString( aReplace ); + m_pSrchItem->SetReplaceString( aReplace ); delete pBackRef; } if (bBack) { - pWrtShell->Pop(); - pWrtShell->SwapPam(); + m_pWrtShell->Pop(); + m_pWrtShell->SwapPam(); } } - else if( pReplList ) + else if( m_pReplList ) nCmd = SVX_SEARCHCMD_REPLACE; // 2) Weiter suchen (ohne zu ersetzen!) - sal_uInt16 nOldCmd = pSrchItem->GetCommand(); - pSrchItem->SetCommand( nCmd ); + sal_uInt16 nOldCmd = m_pSrchItem->GetCommand(); + m_pSrchItem->SetCommand( nCmd ); sal_Bool bRet = SearchAndWrap(bApi); if( bRet ) - Scroll( pWrtShell->GetCharRect().SVRect()); - pSrchItem->SetCommand( nOldCmd ); + Scroll( m_pWrtShell->GetCharRect().SVRect()); + m_pSrchItem->SetCommand( nOldCmd ); rReq.SetReturnValue(SfxBoolItem(nSlot, bRet)); } break; case SVX_SEARCHCMD_REPLACE_ALL: { - SwSearchOptions aOpts( pWrtShell, pSrchItem->GetBackward() ); - bExtra = sal_False; + SwSearchOptions aOpts( m_pWrtShell, m_pSrchItem->GetBackward() ); + m_bExtra = sal_False; sal_uLong nFound; { //Scope for SwWait-Object SwWait aWait( *GetDocShell(), sal_True ); - pWrtShell->StartAllAction(); - if (!pSrchItem->GetSelection()) + m_pWrtShell->StartAllAction(); + if (!m_pSrchItem->GetSelection()) { // if we don't want to search in the selection... - pWrtShell->KillSelection(0, false); + m_pWrtShell->KillSelection(0, false); // i#8288 "replace all" should not change cursor // position, so save current cursor - pWrtShell->Push(); + m_pWrtShell->Push(); if (DOCPOS_START == aOpts.eEnd) { - pWrtShell->EndDoc(); + m_pWrtShell->EndDoc(); } else { - pWrtShell->SttDoc(); + m_pWrtShell->SttDoc(); } } nFound = FUNC_Search( aOpts ); - if (!pSrchItem->GetSelection()) + if (!m_pSrchItem->GetSelection()) { // create it just to overwrite it with stack cursor - pWrtShell->CreateCrsr(); + m_pWrtShell->CreateCrsr(); // i#8288 restore the original cursor position - pWrtShell->Pop(false); + m_pWrtShell->Pop(false); } - pWrtShell->EndAllAction(); + m_pWrtShell->EndAllAction(); } rReq.SetReturnValue(SfxBoolItem(nSlot, nFound != 0 && ULONG_MAX != nFound)); @@ -326,9 +326,9 @@ void SwView::ExecSearch(SfxRequest& rReq, sal_Bool bNoMessage) { if( !bApi ) { - ShowNotFoundInfoBox( pSrchDlg ); + ShowNotFoundInfoBox( m_pSrchDlg ); } - bFound = sal_False; + m_bFound = sal_False; return; } @@ -338,7 +338,7 @@ void SwView::ExecSearch(SfxRequest& rReq, sal_Bool bNoMessage) const xub_StrLen nPos = aText.Search( rtl::OUString("XX") ); aText.Erase( nPos, 2 ); aText.Insert( OUString::number( nFound ), nPos ); - Window* pParentWindow = GetParentWindow( pSrchDlg ); + Window* pParentWindow = GetParentWindow( m_pSrchDlg ); InfoBox( pParentWindow, aText ).Execute(); } } @@ -401,23 +401,23 @@ void SwView::ExecSearch(SfxRequest& rReq, sal_Bool bNoMessage) aCJKAttr + SAL_N_ELEMENTS( aCJKAttr )); } - SfxItemSet aSet( pWrtShell->GetAttrPool(), &aArr[0] ); + SfxItemSet aSet( m_pWrtShell->GetAttrPool(), &aArr[0] ); sal_uInt16 nWhich = SID_SEARCH_SEARCHSET; if ( FID_SEARCH_REPLACESET == nSlot ) { nWhich = SID_SEARCH_REPLACESET; - if ( pReplList ) + if ( m_pReplList ) { - pReplList->Get( aSet ); - DELETEZ( pReplList ); + m_pReplList->Get( aSet ); + DELETEZ( m_pReplList ); } } - else if ( pSrchList ) + else if ( m_pSrchList ) { - pSrchList->Get( aSet ); - DELETEZ( pSrchList ); + m_pSrchList->Get( aSet ); + DELETEZ( m_pSrchList ); } rReq.SetReturnValue( SvxSetItem( nWhich, aSet ) ); } @@ -437,29 +437,29 @@ void SwView::ExecSearch(SfxRequest& rReq, sal_Bool bNoMessage) sal_Bool SwView::SearchAndWrap(sal_Bool bApi) { - SwSearchOptions aOpts( pWrtShell, pSrchItem->GetBackward() ); + SwSearchOptions aOpts( m_pWrtShell, m_pSrchItem->GetBackward() ); // Startposition der Suche fuer WrapAround merken // Start- / EndAction wegen vielleicht bestehender Selektionen // aus 'Suche alle' - pWrtShell->StartAllAction(); - pWrtShell->Push(); + m_pWrtShell->StartAllAction(); + m_pWrtShell->Push(); // falls in selektierten Bereichen gesucht werden soll, duerfen sie // nicht aufgehoben werden - if (!pSrchItem->GetSelection()) - pWrtShell->KillSelection(0, false); + if (!m_pSrchItem->GetSelection()) + m_pWrtShell->KillSelection(0, false); SwWait *pWait = new SwWait( *GetDocShell(), sal_True ); if( FUNC_Search( aOpts ) ) { - bFound = sal_True; - if(pWrtShell->IsSelFrmMode()) + m_bFound = sal_True; + if(m_pWrtShell->IsSelFrmMode()) { - pWrtShell->UnSelectFrm(); - pWrtShell->LeaveSelFrmMode(); + m_pWrtShell->UnSelectFrm(); + m_pWrtShell->LeaveSelFrmMode(); } - pWrtShell->Pop(); - pWrtShell->EndAllAction(); + m_pWrtShell->Pop(); + m_pWrtShell->EndAllAction(); delete pWait; return sal_True; } @@ -468,53 +468,53 @@ sal_Bool SwView::SearchAndWrap(sal_Bool bApi) // Suchen in den Sonderbereichen, wenn keine // Suche in Selektionen vorliegt. Bei Suche in Selektionen // wird ohnehin in diesen Sonderbereichen gesucht - bool bHasSrchInOther = bExtra; - if (!pSrchItem->GetSelection() && !bExtra ) + bool bHasSrchInOther = m_bExtra; + if (!m_pSrchItem->GetSelection() && !m_bExtra ) { - bExtra = true; + m_bExtra = true; if( FUNC_Search( aOpts ) ) { - bFound = sal_True; - pWrtShell->Pop(); - pWrtShell->EndAllAction(); + m_bFound = sal_True; + m_pWrtShell->Pop(); + m_pWrtShell->EndAllAction(); return sal_True; } - bExtra = false; + m_bExtra = false; } else - bExtra = !bExtra; + m_bExtra = !m_bExtra; const sal_uInt16 nId = SvxSearchDialogWrapper::GetChildWindowId(); SvxSearchDialogWrapper *pWrp = (SvxSearchDialogWrapper*)GetViewFrame()->GetChildWindow(nId); - pSrchDlg = pWrp ? static_cast <SvxSearchDialog*> (pWrp->getDialog ()) : 0; + m_pSrchDlg = pWrp ? static_cast <SvxSearchDialog*> (pWrp->getDialog ()) : 0; // falls Startposition am Dokumentende / -anfang if (aOpts.bDontWrap) { - pWrtShell->EndAllAction(); + m_pWrtShell->EndAllAction(); if( !bApi ) { - ShowNotFoundInfoBox( pSrchDlg ); + ShowNotFoundInfoBox( m_pSrchDlg ); } - bFound = sal_False; - pWrtShell->Pop(); + m_bFound = sal_False; + m_pWrtShell->Pop(); return sal_False; } - pWrtShell->EndAllAction(); + m_pWrtShell->EndAllAction(); // noch mal mit WrapAround versuchen? - if( bApi || RET_NO == QueryBox( GetParentWindow( pSrchDlg ), + if( bApi || RET_NO == QueryBox( GetParentWindow( m_pSrchDlg ), SW_RES( DOCPOS_START == aOpts.eEnd ? MSG_SEARCH_START : MSG_SEARCH_END ) ).Execute() ) { - bFound = sal_False; - pWrtShell->Pop(); + m_bFound = sal_False; + m_pWrtShell->Pop(); return sal_False; } - pWrtShell->StartAllAction(); - pWrtShell->Pop(sal_False); + m_pWrtShell->StartAllAction(); + m_pWrtShell->Pop(sal_False); pWait = new SwWait( *GetDocShell(), sal_True ); bool bSrchBkwrd = DOCPOS_START == aOpts.eEnd; @@ -524,52 +524,52 @@ sal_Bool SwView::SearchAndWrap(sal_Bool bApi) if (bHasSrchInOther) { - pWrtShell->ClearMark(); + m_pWrtShell->ClearMark(); if (bSrchBkwrd) - pWrtShell->EndDoc(); + m_pWrtShell->EndDoc(); else - pWrtShell->SttDoc(); + m_pWrtShell->SttDoc(); } - bFound = 0 != FUNC_Search( aOpts ); - pWrtShell->EndAllAction(); + m_bFound = 0 != FUNC_Search( aOpts ); + m_pWrtShell->EndAllAction(); delete pWait; - if ( bFound ) - return bFound; + if ( m_bFound ) + return m_bFound; if(!bApi) { - ShowNotFoundInfoBox( pSrchDlg ); + ShowNotFoundInfoBox( m_pSrchDlg ); } - return bFound = sal_False; + return m_bFound = sal_False; } sal_Bool SwView::SearchAll(sal_uInt16* pFound) { SwWait aWait( *GetDocShell(), sal_True ); - pWrtShell->StartAllAction(); + m_pWrtShell->StartAllAction(); - SwSearchOptions aOpts( pWrtShell, pSrchItem->GetBackward() ); + SwSearchOptions aOpts( m_pWrtShell, m_pSrchItem->GetBackward() ); - if (!pSrchItem->GetSelection()) + if (!m_pSrchItem->GetSelection()) { // bestehende Selektionen aufheben, // wenn nicht in selektierten Bereichen gesucht werden soll - pWrtShell->KillSelection(0, false); + m_pWrtShell->KillSelection(0, false); if( DOCPOS_START == aOpts.eEnd ) - pWrtShell->EndDoc(); + m_pWrtShell->EndDoc(); else - pWrtShell->SttDoc(); + m_pWrtShell->SttDoc(); } - bExtra = false; + m_bExtra = false; sal_uInt16 nFound = (sal_uInt16)FUNC_Search( aOpts ); if(pFound) *pFound = nFound; - bFound = 0 != nFound; + m_bFound = 0 != nFound; - pWrtShell->EndAllAction(); - return bFound; + m_pWrtShell->EndAllAction(); + return m_bFound; } @@ -577,67 +577,67 @@ void SwView::Replace() { SwWait aWait( *GetDocShell(), sal_True ); - pWrtShell->StartAllAction(); + m_pWrtShell->StartAllAction(); - if( pSrchItem->GetPattern() ) // Vorlagen? + if( m_pSrchItem->GetPattern() ) // Vorlagen? { SwRewriter aRewriter; - aRewriter.AddRule(UndoArg1, pSrchItem->GetSearchString()); + aRewriter.AddRule(UndoArg1, m_pSrchItem->GetSearchString()); aRewriter.AddRule(UndoArg2, SW_RESSTR(STR_YIELDS)); - aRewriter.AddRule(UndoArg3, pSrchItem->GetReplaceString()); + aRewriter.AddRule(UndoArg3, m_pSrchItem->GetReplaceString()); - pWrtShell->StartUndo(UNDO_UI_REPLACE_STYLE, &aRewriter); + m_pWrtShell->StartUndo(UNDO_UI_REPLACE_STYLE, &aRewriter); - pWrtShell->SetTxtFmtColl( pWrtShell->GetParaStyle( - pSrchItem->GetReplaceString(), + m_pWrtShell->SetTxtFmtColl( m_pWrtShell->GetParaStyle( + m_pSrchItem->GetReplaceString(), SwWrtShell::GETSTYLE_CREATESOME )); - pWrtShell->EndUndo(); + m_pWrtShell->EndUndo(); } else { if (GetPostItMgr()->HasActiveSidebarWin()) - GetPostItMgr()->Replace(pSrchItem); + GetPostItMgr()->Replace(m_pSrchItem); sal_Bool bReqReplace = true; - if(pWrtShell->HasSelection()) + if(m_pWrtShell->HasSelection()) { /* check that the selection match the search string*/ //save state - SwPosition aStartPos = (* pWrtShell->GetSwCrsr()->Start()); - SwPosition aEndPos = (* pWrtShell->GetSwCrsr()->End()); - sal_Bool bHasSelection = pSrchItem->GetSelection(); - sal_uInt16 nOldCmd = pSrchItem->GetCommand(); + SwPosition aStartPos = (* m_pWrtShell->GetSwCrsr()->Start()); + SwPosition aEndPos = (* m_pWrtShell->GetSwCrsr()->End()); + sal_Bool bHasSelection = m_pSrchItem->GetSelection(); + sal_uInt16 nOldCmd = m_pSrchItem->GetCommand(); //set state for checking if current selection has a match - pSrchItem->SetCommand( SVX_SEARCHCMD_FIND ); - pSrchItem->SetSelection(true); + m_pSrchItem->SetCommand( SVX_SEARCHCMD_FIND ); + m_pSrchItem->SetSelection(true); //check if it matchs - SwSearchOptions aOpts( pWrtShell, pSrchItem->GetBackward() ); + SwSearchOptions aOpts( m_pWrtShell, m_pSrchItem->GetBackward() ); if( ! FUNC_Search(aOpts) ) { //no matching therefore should not replace selection // => remove selection - if(! pSrchItem->GetBackward() ) + if(! m_pSrchItem->GetBackward() ) { - (* pWrtShell->GetSwCrsr()->Start()) = aStartPos; - (* pWrtShell->GetSwCrsr()->End()) = aEndPos; + (* m_pWrtShell->GetSwCrsr()->Start()) = aStartPos; + (* m_pWrtShell->GetSwCrsr()->End()) = aEndPos; } else { - (* pWrtShell->GetSwCrsr()->Start()) = aEndPos; - (* pWrtShell->GetSwCrsr()->End()) = aStartPos; + (* m_pWrtShell->GetSwCrsr()->Start()) = aEndPos; + (* m_pWrtShell->GetSwCrsr()->End()) = aStartPos; } bReqReplace = false; } //set back old search state - pSrchItem->SetCommand( nOldCmd ); - pSrchItem->SetSelection(bHasSelection); + m_pSrchItem->SetCommand( nOldCmd ); + m_pSrchItem->SetSelection(bHasSelection); } /* * remove current selection @@ -649,22 +649,22 @@ void SwView::Replace() if( bReqReplace ) { - sal_Bool bReplaced = pWrtShell->SwEditShell::Replace( pSrchItem->GetReplaceString(), - pSrchItem->GetRegExp()); - if( bReplaced && pReplList && pReplList->Count() && pWrtShell->HasSelection() ) + sal_Bool bReplaced = m_pWrtShell->SwEditShell::Replace( m_pSrchItem->GetReplaceString(), + m_pSrchItem->GetRegExp()); + if( bReplaced && m_pReplList && m_pReplList->Count() && m_pWrtShell->HasSelection() ) { - SfxItemSet aReplSet( pWrtShell->GetAttrPool(), + SfxItemSet aReplSet( m_pWrtShell->GetAttrPool(), aTxtFmtCollSetRange ); - if( pReplList->Get( aReplSet ).Count() ) + if( m_pReplList->Get( aReplSet ).Count() ) { - ::SfxToSwPageDescAttr( *pWrtShell, aReplSet ); - pWrtShell->SwEditShell::SetAttr( aReplSet ); + ::SfxToSwPageDescAttr( *m_pWrtShell, aReplSet ); + m_pWrtShell->SwEditShell::SetAttr( aReplSet ); } } } } - pWrtShell->EndAllAction(); + m_pWrtShell->EndAllAction(); } @@ -686,16 +686,16 @@ SwSearchOptions::SwSearchOptions( SwWrtShell* pSh, sal_Bool bBackward ) sal_uLong SwView::FUNC_Search( const SwSearchOptions& rOptions ) { - sal_Bool bDoReplace = pSrchItem->GetCommand() == SVX_SEARCHCMD_REPLACE || - pSrchItem->GetCommand() == SVX_SEARCHCMD_REPLACE_ALL; + sal_Bool bDoReplace = m_pSrchItem->GetCommand() == SVX_SEARCHCMD_REPLACE || + m_pSrchItem->GetCommand() == SVX_SEARCHCMD_REPLACE_ALL; - int eRanges = pSrchItem->GetSelection() ? - FND_IN_SEL : bExtra ? FND_IN_OTHER : FND_IN_BODY; - if (pSrchItem->GetCommand() == SVX_SEARCHCMD_FIND_ALL || - pSrchItem->GetCommand() == SVX_SEARCHCMD_REPLACE_ALL) + int eRanges = m_pSrchItem->GetSelection() ? + FND_IN_SEL : m_bExtra ? FND_IN_OTHER : FND_IN_BODY; + if (m_pSrchItem->GetCommand() == SVX_SEARCHCMD_FIND_ALL || + m_pSrchItem->GetCommand() == SVX_SEARCHCMD_REPLACE_ALL) eRanges |= FND_IN_SELALL; - pWrtShell->SttSelect(); + m_pWrtShell->SttSelect(); static sal_uInt16 aSearchAttrRange[] = { RES_FRMATR_BEGIN, RES_FRMATR_END-1, @@ -704,24 +704,24 @@ sal_uLong SwView::FUNC_Search( const SwSearchOptions& rOptions ) SID_ATTR_PARA_MODEL, SID_ATTR_PARA_KEEP, 0 }; - SfxItemSet aSrchSet( pWrtShell->GetAttrPool(), aSearchAttrRange); - if( pSrchList && pSrchList->Count() ) + SfxItemSet aSrchSet( m_pWrtShell->GetAttrPool(), aSearchAttrRange); + if( m_pSrchList && m_pSrchList->Count() ) { - pSrchList->Get( aSrchSet ); + m_pSrchList->Get( aSrchSet ); /* -- Seitenumbruch mit Seitenvorlage */ - ::SfxToSwPageDescAttr( *pWrtShell, aSrchSet ); + ::SfxToSwPageDescAttr( *m_pWrtShell, aSrchSet ); } SfxItemSet* pReplSet = 0; - if( bDoReplace && pReplList && pReplList->Count() ) + if( bDoReplace && m_pReplList && m_pReplList->Count() ) { - pReplSet = new SfxItemSet( pWrtShell->GetAttrPool(), + pReplSet = new SfxItemSet( m_pWrtShell->GetAttrPool(), aSearchAttrRange ); - pReplList->Get( *pReplSet ); + m_pReplList->Get( *pReplSet ); /* -- Seitenumbruch mit Seitenvorlage */ - ::SfxToSwPageDescAttr( *pWrtShell, *pReplSet ); + ::SfxToSwPageDescAttr( *m_pWrtShell, *pReplSet ); if( !pReplSet->Count() ) // schade, die Attribute DELETEZ( pReplSet ); // kennen wir nicht @@ -730,7 +730,7 @@ sal_uLong SwView::FUNC_Search( const SwSearchOptions& rOptions ) // // build SearchOptions to be used // - SearchOptions aSearchOpt( pSrchItem->GetSearchOptions() ); + SearchOptions aSearchOpt( m_pSrchItem->GetSearchOptions() ); aSearchOpt.Locale = GetAppLanguageTag().getLocale(); if( !bDoReplace ) aSearchOpt.replaceString = aEmptyStr; @@ -738,20 +738,20 @@ sal_uLong SwView::FUNC_Search( const SwSearchOptions& rOptions ) sal_uLong nFound; if( aSrchSet.Count() || ( pReplSet && pReplSet->Count() )) { - nFound = pWrtShell->SearchAttr( + nFound = m_pWrtShell->SearchAttr( aSrchSet, - !pSrchItem->GetPattern(), + !m_pSrchItem->GetPattern(), rOptions.eStart, rOptions.eEnd, FindRanges(eRanges), - pSrchItem->GetSearchString().Len() ? &aSearchOpt : 0, + m_pSrchItem->GetSearchString().Len() ? &aSearchOpt : 0, pReplSet ); } - else if( pSrchItem->GetPattern() ) + else if( m_pSrchItem->GetPattern() ) { // Suchen (und ersetzen) von Vorlagen - const String sRplStr( pSrchItem->GetReplaceString() ); - nFound = pWrtShell->SearchTempl( pSrchItem->GetSearchString(), + const String sRplStr( m_pSrchItem->GetReplaceString() ); + nFound = m_pWrtShell->SearchTempl( m_pSrchItem->GetSearchString(), rOptions.eStart, rOptions.eEnd, FindRanges(eRanges), @@ -760,13 +760,13 @@ sal_uLong SwView::FUNC_Search( const SwSearchOptions& rOptions ) else { // Normale Suche - nFound = pWrtShell->SearchPattern(aSearchOpt, pSrchItem->GetNotes(), + nFound = m_pWrtShell->SearchPattern(aSearchOpt, m_pSrchItem->GetNotes(), rOptions.eStart, rOptions.eEnd, FindRanges(eRanges), bDoReplace ); } - pWrtShell->EndSelect(); + m_pWrtShell->EndSelect(); return nFound; } @@ -775,10 +775,10 @@ Dialog* SwView::GetSearchDialog() const sal_uInt16 nId = SvxSearchDialogWrapper::GetChildWindowId(); SvxSearchDialogWrapper *pWrp = (SvxSearchDialogWrapper*)SfxViewFrame::Current()->GetChildWindow(nId); if ( pWrp ) - pSrchDlg = pWrp->getDialog (); + m_pSrchDlg = pWrp->getDialog (); else - pSrchDlg = 0; - return pSrchDlg; + m_pSrchDlg = 0; + return m_pSrchDlg; } void SwView::StateSearch(SfxItemSet &rSet) @@ -801,28 +801,28 @@ void SwView::StateSearch(SfxItemSet &rSet) break; case SID_SEARCH_ITEM: { - if ( !pSrchItem ) + if ( !m_pSrchItem ) { - pSrchItem = new SvxSearchItem( SID_SEARCH_ITEM ); - pSrchItem->SetFamily(SFX_STYLE_FAMILY_PARA); - pSrchItem->SetSearchString( pWrtShell->GetSelTxt() ); + m_pSrchItem = new SvxSearchItem( SID_SEARCH_ITEM ); + m_pSrchItem->SetFamily(SFX_STYLE_FAMILY_PARA); + m_pSrchItem->SetSearchString( m_pWrtShell->GetSelTxt() ); } - if( bJustOpened && pWrtShell->IsSelection() ) + if( m_bJustOpened && m_pWrtShell->IsSelection() ) { String aTxt; - if( 1 == pWrtShell->GetCrsrCnt() && - ( aTxt = pWrtShell->SwCrsrShell::GetSelTxt() ).Len() ) + if( 1 == m_pWrtShell->GetCrsrCnt() && + ( aTxt = m_pWrtShell->SwCrsrShell::GetSelTxt() ).Len() ) { - pSrchItem->SetSearchString( aTxt ); - pSrchItem->SetSelection( sal_False ); + m_pSrchItem->SetSearchString( aTxt ); + m_pSrchItem->SetSelection( sal_False ); } else - pSrchItem->SetSelection( sal_True ); + m_pSrchItem->SetSelection( sal_True ); } - bJustOpened = false; - rSet.Put( *pSrchItem ); + m_bJustOpened = false; + rSet.Put( *m_pSrchItem ); } break; } diff --git a/sw/source/ui/uiview/viewstat.cxx b/sw/source/ui/uiview/viewstat.cxx index 0242587af180..248afd7ed559 100644 --- a/sw/source/ui/uiview/viewstat.cxx +++ b/sw/source/ui/uiview/viewstat.cxx @@ -73,10 +73,10 @@ void SwView::GetState(SfxItemSet &rSet) switch(nWhich) { case FN_EDIT_LINK_DLG: - if( pWrtShell->GetLinkManager().GetLinks().empty() ) + if( m_pWrtShell->GetLinkManager().GetLinks().empty() ) rSet.DisableItem(nWhich); - else if( pWrtShell->IsSelFrmMode() && - pWrtShell->IsSelObjProtected(FLYPROTECT_CONTENT)) + else if( m_pWrtShell->IsSelFrmMode() && + m_pWrtShell->IsSelObjProtected(FLYPROTECT_CONTENT)) rSet.DisableItem(nWhich); break; @@ -84,35 +84,35 @@ void SwView::GetState(SfxItemSet &rSet) { // Captions gibt's fuer Grafiken, OLE-Objekte, Rahmen und Tabellen if( !bGetFrmType ) - eFrmType = pWrtShell->GetFrmType(0,sal_True), bGetFrmType = sal_True; - if (! ( ((eFrmType & FRMTYPE_FLY_ANY) && nSelectionType != nsSelectionType::SEL_DRW_TXT)|| - nSelectionType & nsSelectionType::SEL_TBL || - nSelectionType & nsSelectionType::SEL_DRW) ) + eFrmType = m_pWrtShell->GetFrmType(0,sal_True), bGetFrmType = sal_True; + if (! ( ((eFrmType & FRMTYPE_FLY_ANY) && m_nSelectionType != nsSelectionType::SEL_DRW_TXT)|| + m_nSelectionType & nsSelectionType::SEL_TBL || + m_nSelectionType & nsSelectionType::SEL_DRW) ) rSet.DisableItem(nWhich); - else if((pWrtShell->IsObjSelected()||pWrtShell->IsFrmSelected()) && - (pWrtShell->IsSelObjProtected( FLYPROTECT_PARENT)|| - pWrtShell->IsSelObjProtected( FLYPROTECT_CONTENT ))) + else if((m_pWrtShell->IsObjSelected()||m_pWrtShell->IsFrmSelected()) && + (m_pWrtShell->IsSelObjProtected( FLYPROTECT_PARENT)|| + m_pWrtShell->IsSelObjProtected( FLYPROTECT_CONTENT ))) rSet.DisableItem(nWhich); - else if( pWrtShell->IsTableMode() ) + else if( m_pWrtShell->IsTableMode() ) rSet.DisableItem(nWhich); } break; case FN_EDIT_FOOTNOTE: { - if( !pWrtShell->GetCurFtn() ) + if( !m_pWrtShell->GetCurFtn() ) rSet.DisableItem(nWhich); } break; case FN_CHANGE_PAGENUM: { - sal_uInt16 nType = pWrtShell->GetFrmType(0,sal_True); + sal_uInt16 nType = m_pWrtShell->GetFrmType(0,sal_True); if( ( FRMTYPE_FLY_ANY | FRMTYPE_HEADER | FRMTYPE_FOOTER | FRMTYPE_FOOTNOTE | FRMTYPE_DRAWOBJ ) & nType ) rSet.DisableItem(nWhich); else - rSet.Put(SfxUInt16Item(nWhich, pWrtShell->GetPageOffset())); + rSet.Put(SfxUInt16Item(nWhich, m_pWrtShell->GetPageOffset())); } break; case SID_PRINTDOC: @@ -125,16 +125,16 @@ void SwView::GetState(SfxItemSet &rSet) case RES_PAPER_BIN: case FN_PARAM_FTN_INFO: { - const sal_uInt16 nCurIdx = pWrtShell->GetCurPageDesc(); - const SwPageDesc& rDesc = pWrtShell->GetPageDesc( nCurIdx ); + const sal_uInt16 nCurIdx = m_pWrtShell->GetCurPageDesc(); + const SwPageDesc& rDesc = m_pWrtShell->GetPageDesc( nCurIdx ); ::PageDescToItemSet( rDesc, rSet); } break; case RES_BACKGROUND: case SID_ATTR_BRUSH: { - const sal_uInt16 nCurIdx = pWrtShell->GetCurPageDesc(); - const SwPageDesc& rDesc = pWrtShell->GetPageDesc( nCurIdx ); + const sal_uInt16 nCurIdx = m_pWrtShell->GetCurPageDesc(); + const SwPageDesc& rDesc = m_pWrtShell->GetPageDesc( nCurIdx ); const SwFrmFmt& rMaster = rDesc.GetMaster(); const SvxBrushItem& rBrush = (const SvxBrushItem&) rMaster.GetFmtAttr(RES_BACKGROUND, sal_True); @@ -143,17 +143,17 @@ void SwView::GetState(SfxItemSet &rSet) break; case SID_CLEARHISTORY: { - rSet.Put(SfxBoolItem(nWhich, pWrtShell->GetLastUndoInfo(0, 0))); + rSet.Put(SfxBoolItem(nWhich, m_pWrtShell->GetLastUndoInfo(0, 0))); } break; case SID_UNDO: { // die muss noch nicht vorhanden sein // also lasse sie mal anlegen: - if( !pShell ) + if( !m_pShell ) SelectShell(); - const SfxPoolItem* pState = pShell->GetSlotState(SID_UNDO); + const SfxPoolItem* pState = m_pShell->GetSlotState(SID_UNDO); if(pState) rSet.Put(*pState); else @@ -162,14 +162,14 @@ void SwView::GetState(SfxItemSet &rSet) break; case FN_INSERT_CTRL: { - SfxImageItem aImgItem(nWhich, bWeb ? SwView::nWebInsertCtrlState : SwView::nInsertCtrlState); + SfxImageItem aImgItem(nWhich, bWeb ? SwView::m_nWebInsertCtrlState : SwView::m_nInsertCtrlState); SfxSlotPool& rPool = SfxSlotPool::GetSlotPool( GetViewFrame() ); const SfxSlot* pSlot = rPool.GetSlot( aImgItem.GetValue() ); if(pSlot && pSlot->IsMode( SFX_SLOT_IMAGEROTATION )) { - if(pWrtShell->IsInVerticalText()) + if(m_pWrtShell->IsInVerticalText()) aImgItem.SetRotation(2700); - if(pWrtShell->IsInRightToLeftText()) + if(m_pWrtShell->IsInRightToLeftText()) aImgItem.SetMirrored(sal_True); } rSet.Put(aImgItem); @@ -180,28 +180,28 @@ void SwView::GetState(SfxItemSet &rSet) rSet.DisableItem(nWhich); else { - SfxImageItem aImgItem(nWhich, SwView::nInsertObjectCtrlState); + SfxImageItem aImgItem(nWhich, SwView::m_nInsertObjectCtrlState); SfxSlotPool& rPool = SfxSlotPool::GetSlotPool( GetViewFrame() ); const SfxSlot* pSlot = rPool.GetSlot( aImgItem.GetValue() ); if(pSlot && pSlot->IsMode( SFX_SLOT_IMAGEROTATION )) { - if(pWrtShell->IsInVerticalText()) + if(m_pWrtShell->IsInVerticalText()) aImgItem.SetRotation(2700); - if(pWrtShell->IsInRightToLeftText()) + if(m_pWrtShell->IsInRightToLeftText()) aImgItem.SetMirrored(sal_True); } rSet.Put(aImgItem); } break; case FN_UPDATE_TOX: - if(!pWrtShell->GetTOXCount()) + if(!m_pWrtShell->GetTOXCount()) rSet.DisableItem(nWhich); break; case FN_EDIT_CURRENT_TOX: case FN_UPDATE_CUR_TOX: { const SwTOXBase* pBase = 0; - if(0 == (pBase = pWrtShell->GetCurTOX()) || + if(0 == (pBase = m_pWrtShell->GetCurTOX()) || (FN_EDIT_CURRENT_TOX == nWhich && pBase->IsTOXBaseInReadonly())) rSet.DisableItem(nWhich); } @@ -219,7 +219,7 @@ void SwView::GetState(SfxItemSet &rSet) case SID_ATTR_DEFTABSTOP: { const SvxTabStopItem& rDefTabs = - (const SvxTabStopItem&)pWrtShell-> + (const SvxTabStopItem&)m_pWrtShell-> GetDefault(RES_PARATR_TABSTOP); rSet.Put( SfxUInt16Item( nWhich, (sal_uInt16)::GetTabDist(rDefTabs))); @@ -228,16 +228,16 @@ void SwView::GetState(SfxItemSet &rSet) case SID_ATTR_LANGUAGE: { rSet.Put((const SvxLanguageItem&) - pWrtShell->GetDefault(RES_CHRATR_LANGUAGE), SID_ATTR_LANGUAGE); + m_pWrtShell->GetDefault(RES_CHRATR_LANGUAGE), SID_ATTR_LANGUAGE); } break; case RES_CHRATR_CJK_LANGUAGE: rSet.Put((const SvxLanguageItem&) - pWrtShell->GetDefault(RES_CHRATR_CJK_LANGUAGE), RES_CHRATR_CJK_LANGUAGE); + m_pWrtShell->GetDefault(RES_CHRATR_CJK_LANGUAGE), RES_CHRATR_CJK_LANGUAGE); break; case RES_CHRATR_CTL_LANGUAGE: rSet.Put((const SvxLanguageItem&) - pWrtShell->GetDefault(RES_CHRATR_CTL_LANGUAGE), RES_CHRATR_CTL_LANGUAGE); + m_pWrtShell->GetDefault(RES_CHRATR_CTL_LANGUAGE), RES_CHRATR_CTL_LANGUAGE); break; case FN_REDLINE_ON: rSet.Put( SfxBoolItem( nWhich, GetDocShell()->IsChangeRecording() ) ); @@ -249,7 +249,7 @@ void SwView::GetState(SfxItemSet &rSet) { sal_uInt16 nMask = nsRedlineMode_t::REDLINE_SHOW_INSERT | nsRedlineMode_t::REDLINE_SHOW_DELETE; rSet.Put( SfxBoolItem( nWhich, - (pWrtShell->GetRedlineMode() & nMask) == nMask )); + (m_pWrtShell->GetRedlineMode() & nMask) == nMask )); } break; case SID_GALLERY : @@ -268,8 +268,8 @@ void SwView::GetState(SfxItemSet &rSet) { // If the selection/cursor start position isn't on a redline, disable // accepting/rejecting changes. - SwDoc *pDoc = pWrtShell->GetDoc(); - SwPaM *pCursor = pWrtShell->GetCrsr(); + SwDoc *pDoc = m_pWrtShell->GetDoc(); + SwPaM *pCursor = m_pWrtShell->GetCrsr(); if (0 == pDoc->GetRedline(*pCursor->Start(), 0)) rSet.DisableItem(nWhich); } @@ -281,7 +281,7 @@ void SwView::GetState(SfxItemSet &rSet) // Enable change navigation if we have any redlines. Ideally we should disable // "Next Change" if we're at or past the last change, and similarly for // "Previous Change" - if (0 == pWrtShell->GetRedlineCount()) + if (0 == m_pWrtShell->GetRedlineCount()) rSet.DisableItem(nWhich); } break; @@ -318,7 +318,7 @@ void SwView::GetState(SfxItemSet &rSet) break; case SID_MAIL_SCROLLBODY_PAGEDOWN: { - const long nBottom = pWrtShell->GetDocSize().Height() + DOCUMENTBORDER; + const long nBottom = m_pWrtShell->GetDocSize().Height() + DOCUMENTBORDER; const long nAct = GetVisArea().Bottom(); rSet.Put(SfxBoolItem(SID_MAIL_SCROLLBODY_PAGEDOWN, nAct < nBottom )); } @@ -327,7 +327,7 @@ void SwView::GetState(SfxItemSet &rSet) case SID_DOCUMENT_COMPARE: case SID_DOCUMENT_MERGE: if( GetDocShell()->IsA( SwGlobalDocShell::StaticType() ) || - (SID_DOCUMENT_MERGE == nWhich && pWrtShell->getIDocumentRedlineAccess()->GetRedlinePassword().getLength())) + (SID_DOCUMENT_MERGE == nWhich && m_pWrtShell->getIDocumentRedlineAccess()->GetRedlinePassword().getLength())) rSet.DisableItem(nWhich); break; case SID_VIEW_DATA_SOURCE_BROWSER: @@ -338,20 +338,20 @@ void SwView::GetState(SfxItemSet &rSet) break; case SID_READONLY_MODE: rSet.Put(SfxBoolItem(nWhich, - pWrtShell->HasReadonlySel()||GetDocShell()->IsReadOnly())); + m_pWrtShell->HasReadonlySel()||GetDocShell()->IsReadOnly())); break; case SID_IMAGE_ORIENTATION: { SfxImageItem aImageItem(nWhich); - if(pWrtShell->IsInVerticalText()) + if(m_pWrtShell->IsInVerticalText()) aImageItem.SetRotation( 2700 ); - if(pWrtShell->IsInRightToLeftText()) + if(m_pWrtShell->IsInRightToLeftText()) aImageItem.SetMirrored( sal_True ); rSet.Put(aImageItem); } break; case FN_INSERT_FIELD_DATA_ONLY : - if(!bInMailMerge && !GetViewFrame()->HasChildWindow(nWhich)) + if(!m_bInMailMerge && !GetViewFrame()->HasChildWindow(nWhich)) rSet.DisableItem(nWhich); break; case FN_MAILMERGE_SENDMAIL_CHILDWINDOW: @@ -372,11 +372,11 @@ void SwView::GetState(SfxItemSet &rSet) case SID_ALIGN_ANY_HDEFAULT : case SID_ALIGN_ANY_VDEFAULT : { - if( !pShell ) + if( !m_pShell ) SelectShell(); sal_uInt16 nAlias = 0; bool bDraw = false; - if( nSelectionType & (nsSelectionType::SEL_DRW_TXT|nsSelectionType::SEL_TXT) ) + if( m_nSelectionType & (nsSelectionType::SEL_DRW_TXT|nsSelectionType::SEL_TXT) ) { switch( nWhich ) { @@ -389,7 +389,7 @@ void SwView::GetState(SfxItemSet &rSet) case SID_ALIGN_ANY_BOTTOM : nAlias = FN_TABLE_VERT_BOTTOM; break; } } - else if(nSelectionType & (nsSelectionType::SEL_DRW)) + else if(m_nSelectionType & (nsSelectionType::SEL_DRW)) { //the draw shell cannot provide a status per item - only one for SID_OBJECT_ALIGN if(nWhich != SID_ALIGN_ANY_JUSTIFIED) @@ -441,7 +441,7 @@ void SwView::GetDrawState(SfxItemSet &rSet) rSet.DisableItem( nWhich ); else { - SfxAllEnumItem aEnum(SID_INSERT_DRAW, nDrawSfxId); + SfxAllEnumItem aEnum(SID_INSERT_DRAW, m_nDrawSfxId); if ( !SvtLanguageOptions().IsVerticalTextEnabled() ) { aEnum.DisableValue( SID_DRAW_CAPTION_VERTICAL ); @@ -458,13 +458,13 @@ void SwView::GetDrawState(SfxItemSet &rSet) case SID_DRAW_TEXT_MARQUEE: if (::GetHtmlMode(GetDocShell()) & HTMLMODE_SOME_STYLES) - rSet.Put( SfxBoolItem(nWhich, nDrawSfxId == nWhich)); + rSet.Put( SfxBoolItem(nWhich, m_nDrawSfxId == nWhich)); else rSet.DisableItem(nWhich); break; case SID_OBJECT_SELECT: - rSet.Put( SfxBoolItem(nWhich, nDrawSfxId == nWhich || - nFormSfxId == nWhich)); + rSet.Put( SfxBoolItem(nWhich, m_nDrawSfxId == nWhich || + m_nFormSfxId == nWhich)); break; case SID_FONTWORK_GALLERY_FLOATER : @@ -484,7 +484,7 @@ void SwView::GetDrawState(SfxItemSet &rSet) if ( bWeb ) rSet.DisableItem( nWhich ); else - rSet.Put(SfxStringItem(nWhich, aCurrShapeEnumCommand[ nWhich - SID_DRAWTBX_CS_BASIC ] )); + rSet.Put(SfxStringItem(nWhich, m_aCurrShapeEnumCommand[ nWhich - SID_DRAWTBX_CS_BASIC ] )); } break; @@ -496,7 +496,7 @@ sal_Bool SwView::HasUIFeature( sal_uInt32 nFeature ) sal_Bool bRet = sal_False; switch(nFeature) { - case CHILDWIN_LABEL : bRet = pWrtShell->IsLabelDoc(); break; + case CHILDWIN_LABEL : bRet = m_pWrtShell->IsLabelDoc(); break; case CHILDWIN_MAILMERGE : bRet = 0 != GetMailMergeConfigItem(); break; } return bRet; diff --git a/sw/source/ui/uiview/viewtab.cxx b/sw/source/ui/uiview/viewtab.cxx index c3a71c3e20c5..b00d5ab1c1d1 100644 --- a/sw/source/ui/uiview/viewtab.cxx +++ b/sw/source/ui/uiview/viewtab.cxx @@ -577,14 +577,14 @@ void SwView::ExecTabWin( SfxRequest& rReq ) SvxLRSpaceItem aParaMargin((const SvxLRSpaceItem&)rReq. GetArgs()->Get(nSlot)); - aParaMargin.SetRight( aParaMargin.GetRight() - nRightBorderDistance ); - aParaMargin.SetTxtLeft(aParaMargin.GetTxtLeft() - nLeftBorderDistance ); + aParaMargin.SetRight( aParaMargin.GetRight() - m_nRightBorderDistance ); + aParaMargin.SetTxtLeft(aParaMargin.GetTxtLeft() - m_nLeftBorderDistance ); aParaMargin.SetWhich( RES_LR_SPACE ); SwTxtFmtColl* pColl = rSh.GetCurTxtFmtColl(); // #i23726# - if (pNumRuleNodeFromDoc) + if (m_pNumRuleNodeFromDoc) { // --> #i42922# Mouse move of numbering label // has to consider the left indent of the paragraph @@ -593,7 +593,7 @@ void SwView::ExecTabWin( SfxRequest& rReq ) const SvxLRSpaceItem& rLR = static_cast<const SvxLRSpaceItem&>(aSet.Get(RES_LR_SPACE)); - SwPosition aPos(*pNumRuleNodeFromDoc); + SwPosition aPos(*m_pNumRuleNodeFromDoc); // #i90078# rSh.SetIndent( static_cast< short >(aParaMargin.GetTxtLeft() - rLR.GetTxtLeft()), aPos); // #i42921# invalidate state of indent in order to get a ruler update. @@ -657,7 +657,7 @@ void SwView::ExecTabWin( SfxRequest& rReq ) SvxColumnItem aColItem((const SvxColumnItem&)rReq. GetArgs()->Get(nSlot)); - if( bSetTabColFromDoc || (!bSect && rSh.GetTableFmt()) ) + if( m_bSetTabColFromDoc || (!bSect && rSh.GetTableFmt()) ) { OSL_ENSURE(aColItem.Count(), "ColDesc is empty!!"); @@ -665,8 +665,8 @@ void SwView::ExecTabWin( SfxRequest& rReq ) GetArgs()->Get(SID_RULER_ACT_LINE_ONLY)).GetValue(); SwTabCols aTabCols; - if ( bSetTabColFromDoc ) - rSh.GetMouseTabCols( aTabCols, aTabColFromDocPos ); + if ( m_bSetTabColFromDoc ) + rSh.GetMouseTabCols( aTabCols, m_aTabColFromDocPos ); else rSh.GetTabCols(aTabCols); @@ -684,7 +684,7 @@ void SwView::ExecTabWin( SfxRequest& rReq ) //columns in right-to-left tables need to be mirrored sal_Bool bIsTableRTL = IsTabColFromDoc() ? - rSh.IsMouseTableRightToLeft(aTabColFromDocPos) + rSh.IsMouseTableRightToLeft(m_aTabColFromDocPos) : rSh.IsTableRightToLeft(); if(bIsTableRTL) { @@ -706,7 +706,7 @@ void SwView::ExecTabWin( SfxRequest& rReq ) } } - if ( bSetTabColFromDoc ) + if ( m_bSetTabColFromDoc ) { if( !rSh.IsViewLocked() ) { @@ -714,7 +714,7 @@ void SwView::ExecTabWin( SfxRequest& rReq ) rSh.LockView( sal_True ); } rSh.SetMouseTabCols( aTabCols, bSingleLine, - aTabColFromDocPos ); + m_aTabColFromDocPos ); } else rSh.SetTabCols(aTabCols, bSingleLine); @@ -782,13 +782,13 @@ void SwView::ExecTabWin( SfxRequest& rReq ) SvxColumnItem aColItem((const SvxColumnItem&)rReq. GetArgs()->Get(nSlot)); - if( bSetTabColFromDoc || (!bSect && rSh.GetTableFmt()) ) + if( m_bSetTabColFromDoc || (!bSect && rSh.GetTableFmt()) ) { OSL_ENSURE(aColItem.Count(), "ColDesc is empty!!"); SwTabCols aTabCols; - if ( bSetTabRowFromDoc ) - rSh.GetMouseTabRows( aTabCols, aTabColFromDocPos ); + if ( m_bSetTabRowFromDoc ) + rSh.GetMouseTabRows( aTabCols, m_aTabColFromDocPos ); else rSh.GetTabRows(aTabCols); @@ -826,14 +826,14 @@ void SwView::ExecTabWin( SfxRequest& rReq ) const SfxPoolItem* pSingleLine; if( SFX_ITEM_SET == rReq.GetArgs()->GetItemState(SID_RULER_ACT_LINE_ONLY, sal_False, &pSingleLine)) bSingleLine = ((const SfxBoolItem*)pSingleLine)->GetValue(); - if ( bSetTabRowFromDoc ) + if ( m_bSetTabRowFromDoc ) { if( !rSh.IsViewLocked() ) { bUnlockView = true; rSh.LockView( sal_True ); } - rSh.SetMouseTabRows( aTabCols, bSingleLine, aTabColFromDocPos ); + rSh.SetMouseTabRows( aTabCols, bSingleLine, m_aTabColFromDocPos ); } else rSh.SetTabRows(aTabCols, bSingleLine); @@ -849,7 +849,7 @@ void SwView::ExecTabWin( SfxRequest& rReq ) if( bUnlockView ) rSh.LockView( sal_False ); - bSetTabColFromDoc = bSetTabRowFromDoc = bTabColFromDoc = bTabRowFromDoc = sal_False; + m_bSetTabColFromDoc = m_bSetTabRowFromDoc = m_bTabColFromDoc = m_bTabRowFromDoc = sal_False; SetNumRuleNodeFromDoc(NULL); } @@ -862,7 +862,7 @@ void SwView::StateTabWin(SfxItemSet& rSet) { SwWrtShell &rSh = GetWrtShell(); - const Point* pPt = IsTabColFromDoc() || IsTabRowFromDoc() ? &aTabColFromDocPos : 0; + const Point* pPt = IsTabColFromDoc() || IsTabRowFromDoc() ? &m_aTabColFromDocPos : 0; const sal_uInt16 nFrmType = rSh.IsObjSelected() ? FRMTYPE_DRAWOBJ : rSh.GetFrmType( pPt, sal_True ); @@ -876,22 +876,22 @@ void SwView::StateTabWin(SfxItemSet& rSet) const long nPageHeight = rPageRect.Height(); const SwPageDesc& rDesc = rSh.GetPageDesc( - IsTabColFromDoc() || bTabRowFromDoc ? - rSh.GetMousePageDesc(aTabColFromDocPos) : rSh.GetCurPageDesc() ); + IsTabColFromDoc() || m_bTabRowFromDoc ? + rSh.GetMousePageDesc(m_aTabColFromDocPos) : rSh.GetCurPageDesc() ); const SvxFrameDirectionItem& rFrameDir = rDesc.GetMaster().GetFrmDir(); const bool bVerticalWriting = rSh.IsInVerticalText(); //enable tab stop display on the rulers depending on the writing direction - WinBits nRulerStyle = pHRuler->GetStyle() & ~WB_EXTRAFIELD; - pHRuler->SetStyle(bVerticalWriting||bBrowse ? nRulerStyle : nRulerStyle|WB_EXTRAFIELD); - nRulerStyle = pVRuler->GetStyle() & ~WB_EXTRAFIELD; - pVRuler->SetStyle(bVerticalWriting ? nRulerStyle|WB_EXTRAFIELD : nRulerStyle); + WinBits nRulerStyle = m_pHRuler->GetStyle() & ~WB_EXTRAFIELD; + m_pHRuler->SetStyle(bVerticalWriting||bBrowse ? nRulerStyle : nRulerStyle|WB_EXTRAFIELD); + nRulerStyle = m_pVRuler->GetStyle() & ~WB_EXTRAFIELD; + m_pVRuler->SetStyle(bVerticalWriting ? nRulerStyle|WB_EXTRAFIELD : nRulerStyle); //#i24363# tab stops relative to indent bool bRelative = rSh.getIDocumentSettingAccess()->get(IDocumentSettingAccess::TABS_RELATIVE_TO_INDENT); - pHRuler->SetTabsRelativeToIndent( bRelative ); - pVRuler->SetTabsRelativeToIndent( bRelative ); + m_pHRuler->SetTabsRelativeToIndent( bRelative ); + m_pVRuler->SetTabsRelativeToIndent( bRelative ); SvxLRSpaceItem aPageLRSpace( rDesc.GetMaster().GetLRSpace() ); SwapPageMargin( rDesc, aPageLRSpace ); @@ -1036,10 +1036,10 @@ void SwView::StateTabWin(SfxItemSet& rSet) const SvxTabStopItem& rDefTabs = (const SvxTabStopItem&) rSh.GetDefault(RES_PARATR_TABSTOP); - OSL_ENSURE(pHRuler, "why is there no ruler?"); + OSL_ENSURE(m_pHRuler, "why is there no ruler?"); long nDefTabDist = ::GetTabDist(rDefTabs); - pHRuler->SetDefTabDist( nDefTabDist ); - pVRuler->SetDefTabDist( nDefTabDist ); + m_pHRuler->SetDefTabDist( nDefTabDist ); + m_pVRuler->SetDefTabDist( nDefTabDist ); ::lcl_EraseDefTabs(aTabStops); rSet.Put(aTabStops, nWhich); } @@ -1066,15 +1066,15 @@ void SwView::StateTabWin(SfxItemSet& rSet) aLR = (const SvxLRSpaceItem&)aCoreSet.Get(RES_LR_SPACE); // #i23726# - if (pNumRuleNodeFromDoc) + if (m_pNumRuleNodeFromDoc) { short nOffset = static_cast< short >(aLR.GetTxtLeft() + // #i42922# Mouse move of numbering label // has to consider the left indent of the paragraph - pNumRuleNodeFromDoc->GetLeftMarginWithNum( sal_True ) ); + m_pNumRuleNodeFromDoc->GetLeftMarginWithNum( sal_True ) ); short nFLOffset; - pNumRuleNodeFromDoc->GetFirstLineOfsWithNum( nFLOffset ); + m_pNumRuleNodeFromDoc->GetFirstLineOfsWithNum( nFLOffset ); aLR.SetLeft( nOffset + nFLOffset ); } @@ -1086,8 +1086,8 @@ void SwView::StateTabWin(SfxItemSet& rSet) } case SID_RULER_BORDER_DISTANCE: { - nLeftBorderDistance = 0; - nRightBorderDistance = 0; + m_nLeftBorderDistance = 0; + m_nRightBorderDistance = 0; if ( nSelType & nsSelectionType::SEL_GRF || nSelType & nsSelectionType::SEL_FRM || nSelType & nsSelectionType::SEL_OLE || @@ -1126,8 +1126,8 @@ void SwView::StateTabWin(SfxItemSet& rSet) aDistLR.SetRight(aDistLR.GetRight() + (sal_uInt16)rParaBox.GetDistance(BOX_LINE_RIGHT)); } rSet.Put(aDistLR); - nLeftBorderDistance = static_cast< sal_uInt16 >(aDistLR.GetLeft()); - nRightBorderDistance = static_cast< sal_uInt16 >(aDistLR.GetRight()); + m_nLeftBorderDistance = static_cast< sal_uInt16 >(aDistLR.GetLeft()); + m_nRightBorderDistance = static_cast< sal_uInt16 >(aDistLR.GetRight()); } else if ( IsTabColFromDoc() || ( rSh.GetTableFmt() && !bFrmSelection && @@ -1152,8 +1152,8 @@ void SwView::StateTabWin(SfxItemSet& rSet) aDistLR.SetLeft(aDistLR.GetLeft() + (sal_uInt16)rParaBox.GetDistance(BOX_LINE_LEFT )); aDistLR.SetRight(aDistLR.GetRight() + (sal_uInt16)rParaBox.GetDistance(BOX_LINE_RIGHT)); rSet.Put(aDistLR); - nLeftBorderDistance = static_cast< sal_uInt16 >(aDistLR.GetLeft()); - nRightBorderDistance = static_cast< sal_uInt16 >(aDistLR.GetRight()); + m_nLeftBorderDistance = static_cast< sal_uInt16 >(aDistLR.GetLeft()); + m_nRightBorderDistance = static_cast< sal_uInt16 >(aDistLR.GetRight()); } else if ( !rSh.IsDirectlyInSection() ) { @@ -1194,8 +1194,8 @@ void SwView::StateTabWin(SfxItemSet& rSet) aDistLR.SetLeft(aDistLR.GetLeft() + (sal_uInt16)rParaBox.GetDistance(BOX_LINE_LEFT )); aDistLR.SetRight(aDistLR.GetRight() + (sal_uInt16)rParaBox.GetDistance(BOX_LINE_RIGHT)); rSet.Put(aDistLR); - nLeftBorderDistance = static_cast< sal_uInt16 >(aDistLR.GetLeft()); - nRightBorderDistance = static_cast< sal_uInt16 >(aDistLR.GetRight()); + m_nLeftBorderDistance = static_cast< sal_uInt16 >(aDistLR.GetLeft()); + m_nRightBorderDistance = static_cast< sal_uInt16 >(aDistLR.GetRight()); } } } @@ -1242,10 +1242,10 @@ void SwView::StateTabWin(SfxItemSet& rSet) { SwTabCols aTabCols; sal_uInt16 nNum; - if ( 0 != ( bSetTabColFromDoc = IsTabColFromDoc() ) ) + if ( 0 != ( m_bSetTabColFromDoc = IsTabColFromDoc() ) ) { - rSh.GetMouseTabCols( aTabCols, aTabColFromDocPos ); - nNum = rSh.GetCurMouseTabColNum( aTabColFromDocPos ); + rSh.GetMouseTabCols( aTabCols, m_aTabColFromDocPos ); + nNum = rSh.GetCurMouseTabColNum( m_aTabColFromDocPos ); } else { @@ -1272,7 +1272,7 @@ void SwView::StateTabWin(SfxItemSet& rSet) //columns in right-to-left tables need to be mirrored sal_Bool bIsTableRTL = IsTabColFromDoc() ? - rSh.IsMouseTableRightToLeft(aTabColFromDocPos) + rSh.IsMouseTableRightToLeft(m_aTabColFromDocPos) : rSh.IsTableRightToLeft(); if(bIsTableRTL) { @@ -1466,9 +1466,9 @@ void SwView::StateTabWin(SfxItemSet& rSet) SwTabCols aTabCols; //no current value necessary sal_uInt16 nNum = 0; - if ( 0 != ( bSetTabRowFromDoc = IsTabRowFromDoc() ) ) + if ( 0 != ( m_bSetTabRowFromDoc = IsTabRowFromDoc() ) ) { - rSh.GetMouseTabRows( aTabCols, aTabColFromDocPos ); + rSh.GetMouseTabRows( aTabCols, m_aTabColFromDocPos ); } else { @@ -1635,7 +1635,7 @@ void SwView::StateTabWin(SfxItemSet& rSet) { bool bColumn; if ( IsTabColFromDoc() ) - bColumn = rSh.GetCurMouseColNum( aTabColFromDocPos ) != 0; + bColumn = rSh.GetCurMouseColNum( m_aTabColFromDocPos ) != 0; else bColumn = (nFrmType & (FRMTYPE_COLUMN|FRMTYPE_FLY_ANY| FRMTYPE_COLSECTOUTTAB)); @@ -1674,7 +1674,7 @@ void SwView::StateTabWin(SfxItemSet& rSet) //ohne in der Tabelle zu stehen CurRectType eRecType = RECT_PAGE_PRT; sal_uInt16 nNum = IsTabColFromDoc() ? - rSh.GetCurMouseColNum( aTabColFromDocPos ): + rSh.GetCurMouseColNum( m_aTabColFromDocPos ): rSh.GetCurOutColNum(); const SwFrmFmt* pFmt = NULL; if( bColSct ) @@ -1764,7 +1764,7 @@ void SwView::StateTabWin(SfxItemSet& rSet) { if(bFrmSelection) { - sal_uInt8 nProtect = pWrtShell->IsSelObjProtected( FLYPROTECT_SIZE|FLYPROTECT_POS|FLYPROTECT_CONTENT ); + sal_uInt8 nProtect = m_pWrtShell->IsSelObjProtected( FLYPROTECT_SIZE|FLYPROTECT_POS|FLYPROTECT_CONTENT ); SvxProtectItem aProt(SID_RULER_PROTECT); aProt.SetCntntProtect((nProtect & FLYPROTECT_CONTENT) != 0); |