diff options
author | Frank Schoenheit [fs] <frank.schoenheit@oracle.com> | 2011-02-14 22:22:46 +0100 |
---|---|---|
committer | Frank Schoenheit [fs] <frank.schoenheit@oracle.com> | 2011-02-14 22:22:46 +0100 |
commit | ac6e971d8a5f715f716b6bdcaf6cb535104df32c (patch) | |
tree | 940128ed8521d861e77603621700cae8104e6ac3 /reportdesign/source/ui/report/dlgedfunc.cxx | |
parent | 68c3462b2638fd9c4b6bca818213be797a2cf1f5 (diff) | |
parent | b1708ffb49872b51c2b7d82380efeb1282d73b1c (diff) |
dba34c: pulled and merged DEV300.m100
Diffstat (limited to 'reportdesign/source/ui/report/dlgedfunc.cxx')
-rw-r--r-- | reportdesign/source/ui/report/dlgedfunc.cxx | 116 |
1 files changed, 58 insertions, 58 deletions
diff --git a/reportdesign/source/ui/report/dlgedfunc.cxx b/reportdesign/source/ui/report/dlgedfunc.cxx index 13badddbb079..e4b317c1a5f4 100644 --- a/reportdesign/source/ui/report/dlgedfunc.cxx +++ b/reportdesign/source/ui/report/dlgedfunc.cxx @@ -185,11 +185,11 @@ DlgEdFunc::~DlgEdFunc() //---------------------------------------------------------------------------- -BOOL DlgEdFunc::MouseButtonDown( const MouseEvent& rMEvt ) +sal_Bool DlgEdFunc::MouseButtonDown( const MouseEvent& rMEvt ) { m_aMDPos = m_pParent->PixelToLogic( rMEvt.GetPosPixel() ); m_pParent->GrabFocus(); - BOOL bHandled = FALSE; + sal_Bool bHandled = sal_False; if ( rMEvt.IsLeft() ) { if ( rMEvt.GetClicks() > 1 ) @@ -206,8 +206,8 @@ BOOL DlgEdFunc::MouseButtonDown( const MouseEvent& rMEvt ) // SdrViewEvent aVEvt; // m_rView.PickAnything(rMEvt, SDRMOUSEBUTTONDOWN, aVEvt); // if ( aVEvt.pRootObj && aVEvt.pRootObj->ISA(SdrTextObj) ) - // SetInEditMode(static_cast<SdrTextObj *>(aVEvt.pRootObj),rMEvt, FALSE); - bHandled = TRUE; + // SetInEditMode(static_cast<SdrTextObj *>(aVEvt.pRootObj),rMEvt, sal_False); + bHandled = sal_True; } } else @@ -218,7 +218,7 @@ BOOL DlgEdFunc::MouseButtonDown( const MouseEvent& rMEvt ) // if selected object was hit, drag object if ( pHdl!=NULL || m_rView.IsMarkedHit(m_aMDPos) ) { - bHandled = TRUE; + bHandled = sal_True; m_pParent->CaptureMouse(); m_pParent->getSectionWindow()->getViewsWindow()->BegDragObj(m_aMDPos, pHdl,&m_rView); } @@ -235,10 +235,10 @@ BOOL DlgEdFunc::MouseButtonDown( const MouseEvent& rMEvt ) else m_pParent->getSectionWindow()->getViewsWindow()->unmarkAllObjects(NULL); - bHandled = TRUE; + bHandled = sal_True; } else if( !rMEvt.IsLeft() ) - bHandled = TRUE; + bHandled = sal_True; if ( !bHandled ) m_pParent->CaptureMouse(); return bHandled; @@ -246,9 +246,9 @@ BOOL DlgEdFunc::MouseButtonDown( const MouseEvent& rMEvt ) //---------------------------------------------------------------------------- -BOOL DlgEdFunc::MouseButtonUp( const MouseEvent& /*rMEvt*/ ) +sal_Bool DlgEdFunc::MouseButtonUp( const MouseEvent& /*rMEvt*/ ) { - BOOL bHandled = FALSE; + sal_Bool bHandled = sal_False; m_pParent->getSectionWindow()->getViewsWindow()->stopScrollTimer(); return bHandled; } @@ -257,7 +257,7 @@ void DlgEdFunc::checkTwoCklicks(const MouseEvent& rMEvt) { deactivateOle(); - const USHORT nClicks = rMEvt.GetClicks(); + const sal_uInt16 nClicks = rMEvt.GetClicks(); if ( nClicks == 2 && rMEvt.IsLeft() ) { if ( m_rView.AreObjectsMarked() ) @@ -282,19 +282,19 @@ void DlgEdFunc::stopScrollTimer() } //---------------------------------------------------------------------------- -BOOL DlgEdFunc::MouseMove( const MouseEvent& /*rMEvt*/ ) +sal_Bool DlgEdFunc::MouseMove( const MouseEvent& /*rMEvt*/ ) { - return FALSE; + return sal_False; } //------------------------------------------------------------------------------ sal_Bool DlgEdFunc::handleKeyEvent(const KeyEvent& _rEvent) { - BOOL bReturn = FALSE; + sal_Bool bReturn = sal_False; if ( !m_bUiActive ) { const KeyCode& rCode = _rEvent.GetKeyCode(); - USHORT nCode = rCode.GetCode(); + sal_uInt16 nCode = rCode.GetCode(); switch ( nCode ) { @@ -303,12 +303,12 @@ sal_Bool DlgEdFunc::handleKeyEvent(const KeyEvent& _rEvent) if ( m_pParent->getSectionWindow()->getViewsWindow()->IsAction() ) { m_pParent->getSectionWindow()->getViewsWindow()->BrkAction(); - bReturn = TRUE; + bReturn = sal_True; } else if ( m_rView.IsTextEdit() ) { m_rView.SdrEndTextEdit(); - bReturn = TRUE; + bReturn = sal_True; } else if ( m_rView.AreObjectsMarked() ) { @@ -321,7 +321,7 @@ sal_Bool DlgEdFunc::handleKeyEvent(const KeyEvent& _rEvent) //m_rView.UnmarkAll(); deactivateOle(true); - bReturn = FALSE; + bReturn = sal_False; } else { @@ -344,7 +344,7 @@ sal_Bool DlgEdFunc::handleKeyEvent(const KeyEvent& _rEvent) if ( m_rView.AreObjectsMarked() ) m_rView.MakeVisible( m_rView.GetAllMarkedRect(), *m_pParent); - bReturn = TRUE; + bReturn = sal_True; } else if ( rCode.IsMod1() && rCode.IsMod2()) { @@ -361,7 +361,7 @@ sal_Bool DlgEdFunc::handleKeyEvent(const KeyEvent& _rEvent) m_rView.MakeVisible( aVisRect, *m_pParent); } - bReturn = TRUE; + bReturn = sal_True; } } break; @@ -371,7 +371,7 @@ sal_Bool DlgEdFunc::handleKeyEvent(const KeyEvent& _rEvent) case KEY_RIGHT: { m_pParent->getSectionWindow()->getViewsWindow()->handleKey(rCode); - bReturn = TRUE; + bReturn = sal_True; } break; case KEY_RETURN: @@ -388,7 +388,7 @@ sal_Bool DlgEdFunc::handleKeyEvent(const KeyEvent& _rEvent) case KEY_DELETE: if ( !rCode.IsMod1() && !rCode.IsMod2() ) { - bReturn = TRUE; + bReturn = sal_True; break; } // if ( !rCode.IsMod1() && !rCode.IsMod2() ) // run through @@ -410,7 +410,7 @@ void DlgEdFunc::activateOle(SdrObject* _pObj) { if ( _pObj ) { - const UINT16 nSdrObjKind = _pObj->GetObjIdentifier(); + const sal_uInt16 nSdrObjKind = _pObj->GetObjIdentifier(); // // OLE: activate // @@ -452,8 +452,8 @@ void DlgEdFunc::deactivateOle(bool _bSelect) { OLEObjCache& rObjCache = GetSdrGlobalData().GetOLEObjCache(); OReportController& rController = m_pParent->getSectionWindow()->getViewsWindow()->getView()->getReportView()->getController(); - const ULONG nCount = rObjCache.Count(); - for(ULONG i = 0 ; i< nCount;++i) + const sal_uLong nCount = rObjCache.Count(); + for(sal_uLong i = 0 ; i< nCount;++i) { SdrOle2Obj* pObj = reinterpret_cast<SdrOle2Obj*>(rObjCache.GetObject(i)); if ( m_pParent->getPage() == pObj->GetPage() ) @@ -475,7 +475,7 @@ void DlgEdFunc::deactivateOle(bool _bSelect) } } // if ( xObj.is() && xObj->getCurrentState() == embed::EmbedStates::UI_ACTIVE ) } - } // for(ULONG i = 0 ; i< nCount;++i) + } // for(sal_uLong i = 0 ; i< nCount;++i) } // ----------------------------------------------------------------------------- void DlgEdFunc::colorizeOverlappedObject(SdrObject* _pOverlappedObj) @@ -675,22 +675,22 @@ bool DlgEdFunc::setMovementPointer(const MouseEvent& rMEvt) DlgEdFuncInsert::DlgEdFuncInsert( OReportSection* _pParent ) : DlgEdFunc( _pParent ) { - m_rView.SetCreateMode( TRUE ); + m_rView.SetCreateMode( sal_True ); } //---------------------------------------------------------------------------- DlgEdFuncInsert::~DlgEdFuncInsert() { - m_rView.SetEditMode( TRUE ); + m_rView.SetEditMode( sal_True ); } //---------------------------------------------------------------------------- -BOOL DlgEdFuncInsert::MouseButtonDown( const MouseEvent& rMEvt ) +sal_Bool DlgEdFuncInsert::MouseButtonDown( const MouseEvent& rMEvt ) { if ( DlgEdFunc::MouseButtonDown(rMEvt) ) - return TRUE; + return sal_True; SdrViewEvent aVEvt; sal_Int16 nId = m_rView.GetCurrentObjIdentifier(); @@ -707,7 +707,7 @@ BOOL DlgEdFuncInsert::MouseButtonDown( const MouseEvent& rMEvt ) // rtl::OUString suWasN2 = m_pParent->getSectionWindow()->getViewsWindow()->GetInsertObjString(); m_pParent->getSectionWindow()->getViewsWindow()->BrkAction(); - return FALSE; + return sal_False; } if( eHit != SDRHIT_UNMARKEDOBJECT || nId == OBJ_CUSTOMSHAPE) @@ -732,19 +732,19 @@ BOOL DlgEdFuncInsert::MouseButtonDown( const MouseEvent& rMEvt ) m_pParent->getSectionWindow()->getViewsWindow()->BegMarkObj( m_aMDPos,&m_rView ); } - return TRUE; + return sal_True; } //---------------------------------------------------------------------------- -BOOL DlgEdFuncInsert::MouseButtonUp( const MouseEvent& rMEvt ) +sal_Bool DlgEdFuncInsert::MouseButtonUp( const MouseEvent& rMEvt ) { if ( DlgEdFunc::MouseButtonUp( rMEvt ) ) - return TRUE; + return sal_True; const Point aPos( m_pParent->PixelToLogic( rMEvt.GetPosPixel() ) ); - const USHORT nHitLog = USHORT ( m_pParent->PixelToLogic(Size(3,0)).Width() ); + const sal_uInt16 nHitLog = sal_uInt16 ( m_pParent->PixelToLogic(Size(3,0)).Width() ); - BOOL bReturn = TRUE; + sal_Bool bReturn = sal_True; // object creation active? if ( m_rView.IsCreateObj() ) { @@ -752,8 +752,8 @@ BOOL DlgEdFuncInsert::MouseButtonUp( const MouseEvent& rMEvt ) { m_pParent->getSectionWindow()->getViewsWindow()->BrkAction(); // BrkAction disables the create mode - m_rView.SetCreateMode( TRUE ); - return TRUE; + m_rView.SetCreateMode( sal_True ); + return sal_True; } m_rView.EndCreateObj(SDRCREATE_FORCEEND); @@ -800,10 +800,10 @@ BOOL DlgEdFuncInsert::MouseButtonUp( const MouseEvent& rMEvt ) //---------------------------------------------------------------------------- -BOOL DlgEdFuncInsert::MouseMove( const MouseEvent& rMEvt ) +sal_Bool DlgEdFuncInsert::MouseMove( const MouseEvent& rMEvt ) { if ( DlgEdFunc::MouseMove(rMEvt ) ) - return TRUE; + return sal_True; Point aPos( m_pParent->PixelToLogic( rMEvt.GetPosPixel() ) ); if ( m_rView.IsCreateObj() ) @@ -834,7 +834,7 @@ BOOL DlgEdFuncInsert::MouseMove( const MouseEvent& rMEvt ) if ( !bIsSetPoint ) m_pParent->SetPointer( m_rView.GetPreferedPointer( aPos, m_pParent) ); - return TRUE; + return sal_True; } //---------------------------------------------------------------------------- @@ -852,11 +852,11 @@ DlgEdFuncSelect::~DlgEdFuncSelect() //---------------------------------------------------------------------------- -BOOL DlgEdFuncSelect::MouseButtonDown( const MouseEvent& rMEvt ) +sal_Bool DlgEdFuncSelect::MouseButtonDown( const MouseEvent& rMEvt ) { m_bSelectionMode = false; if ( DlgEdFunc::MouseButtonDown(rMEvt) ) - return TRUE; + return sal_True; SdrViewEvent aVEvt; const SdrHitKind eHit = m_rView.PickAnything(rMEvt, SDRMOUSEBUTTONDOWN, aVEvt); @@ -894,15 +894,15 @@ BOOL DlgEdFuncSelect::MouseButtonDown( const MouseEvent& rMEvt ) } } - return TRUE; + return sal_True; } //---------------------------------------------------------------------------- -BOOL DlgEdFuncSelect::MouseButtonUp( const MouseEvent& rMEvt ) +sal_Bool DlgEdFuncSelect::MouseButtonUp( const MouseEvent& rMEvt ) { if ( DlgEdFunc::MouseButtonUp( rMEvt ) ) - return TRUE; + return sal_True; // get view from parent const Point aPnt( m_pParent->PixelToLogic( rMEvt.GetPosPixel() ) ); @@ -918,15 +918,15 @@ BOOL DlgEdFuncSelect::MouseButtonUp( const MouseEvent& rMEvt ) if ( !m_bUiActive ) m_pParent->getSectionWindow()->getViewsWindow()->getView()->getReportView()->UpdatePropertyBrowserDelayed(m_rView); m_bSelectionMode = false; - return TRUE; + return sal_True; } //---------------------------------------------------------------------------- -BOOL DlgEdFuncSelect::MouseMove( const MouseEvent& rMEvt ) +sal_Bool DlgEdFuncSelect::MouseMove( const MouseEvent& rMEvt ) { if ( DlgEdFunc::MouseMove(rMEvt ) ) - return TRUE; + return sal_True; Point aPnt( m_pParent->PixelToLogic( rMEvt.GetPosPixel() ) ); bool bIsSetPoint = false; @@ -973,10 +973,10 @@ BOOL DlgEdFuncSelect::MouseMove( const MouseEvent& rMEvt ) unColorizeOverlappedObj(); } - return TRUE; + return sal_True; } // ----------------------------------------------------------------------------- -//void DlgEdFuncSelect::SetInEditMode(SdrTextObj* _pTextObj,const MouseEvent& rMEvt, BOOL bQuickDrag) +//void DlgEdFuncSelect::SetInEditMode(SdrTextObj* _pTextObj,const MouseEvent& rMEvt, sal_Bool bQuickDrag) //{ // // SdrPageView* pPV = m_rView.GetSdrPageView(); @@ -985,12 +985,12 @@ BOOL DlgEdFuncSelect::MouseMove( const MouseEvent& rMEvt ) // m_rView.SetCurrentObj(OBJ_TEXT); // m_rView.SetEditMode(SDREDITMODE_EDIT); // -// BOOL bEmptyOutliner = FALSE; +// sal_Bool bEmptyOutliner = sal_False; // // if (!_pTextObj->GetOutlinerParaObject() && m_rView.GetTextEditOutliner()) // { // ::SdrOutliner* pOutl = m_rView.GetTextEditOutliner(); -// ULONG nParaAnz = pOutl->GetParagraphCount(); +// sal_uLong nParaAnz = pOutl->GetParagraphCount(); // Paragraph* p1stPara = pOutl->GetParagraph( 0 ); // // if (nParaAnz==1 && p1stPara) @@ -998,15 +998,15 @@ BOOL DlgEdFuncSelect::MouseMove( const MouseEvent& rMEvt ) // // Bei nur einem Pararaph // if (pOutl->GetText(p1stPara).Len() == 0) // { -// bEmptyOutliner = TRUE; +// bEmptyOutliner = sal_True; // } // } // } // // if (_pTextObj != m_rView.GetTextEditObject() || bEmptyOutliner) // { -// UINT32 nInv = _pTextObj->GetObjInventor(); -// UINT16 nSdrObjKind = _pTextObj->GetObjIdentifier(); +// sal_uInt32 nInv = _pTextObj->GetObjInventor(); +// sal_uInt16 nSdrObjKind = _pTextObj->GetObjIdentifier(); // // if (nInv == SdrInventor && _pTextObj->HasTextEdit() && // (nSdrObjKind == OBJ_TEXT || @@ -1020,7 +1020,7 @@ BOOL DlgEdFuncSelect::MouseMove( const MouseEvent& rMEvt ) // pOutl->SetMinDepth(0); // pOutl->SetStyleSheetPool((SfxStyleSheetPool*) pModel->GetStyleSheetPool()); // //pOutl->SetCalcFieldValueHdl(LINK(SD_MOD(), SdModule, CalcFieldValueHdl)); -// ULONG nCntrl = pOutl->GetControlWord(); +// sal_uLong nCntrl = pOutl->GetControlWord(); // nCntrl |= EE_CNTRL_ALLOWBIGOBJS; // nCntrl |= EE_CNTRL_URLSFXEXECUTE; // nCntrl |= EE_CNTRL_MARKFIELDS; @@ -1063,12 +1063,12 @@ BOOL DlgEdFuncSelect::MouseMove( const MouseEvent& rMEvt ) // if( ( pOPO && pOPO->IsVertical() ) /*|| // nSlotId == SID_ATTR_CHAR_VERTICAL || // nSlotId == SID_TEXT_FITTOSIZE_VERTICAL */) -// pOutl->SetVertical( TRUE ); +// pOutl->SetVertical( sal_True ); // // // if (m_rView.SdrBeginTextEdit(_pTextObj, pPV, pParent, sal_True, pOutl) && _pTextObj->GetObjInventor() == SdrInventor) // { -// //bFirstObjCreated = TRUE; +// //bFirstObjCreated = sal_True; // //DeleteDefaultText(); // // OutlinerView* pOLV = m_rView.GetTextEditOutlinerView(); |