diff options
author | Robert Roth <robert.roth.off@gmail.com> | 2010-11-04 01:06:10 +0200 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2010-11-08 12:56:35 +0000 |
commit | a3eaf5d08b5a0a0a2caa2df0f0f44e7235dc6f7e (patch) | |
tree | a282697d5da2542832fd5b24dd5977a4b7759ed0 /sw/source/ui/docvw | |
parent | f1851b84abe2316e50d4f135e4a169c852821bfa (diff) |
Commented code fragments, meaningless and bogus comments removed.
Diffstat (limited to 'sw/source/ui/docvw')
-rw-r--r-- | sw/source/ui/docvw/edtdd.cxx | 8 | ||||
-rw-r--r-- | sw/source/ui/docvw/edtwin2.cxx | 49 | ||||
-rw-r--r-- | sw/source/ui/docvw/edtwin3.cxx | 7 | ||||
-rw-r--r-- | sw/source/ui/docvw/srcedtw.cxx | 61 |
4 files changed, 12 insertions, 113 deletions
diff --git a/sw/source/ui/docvw/edtdd.cxx b/sw/source/ui/docvw/edtdd.cxx index 688a4e3ae50c..91c2c29b5c37 100644 --- a/sw/source/ui/docvw/edtdd.cxx +++ b/sw/source/ui/docvw/edtdd.cxx @@ -233,7 +233,7 @@ sal_Int8 SwEditWin::ExecuteDrop( const ExecuteDropEvent& rEvt ) } - // dvo 2002-05-27, #99027#: There's a special treatment for file lists with a single + // There's a special treatment for file lists with a single // element, that depends on the actual content of the // Transferable to be accessible. Since the transferable // may only be accessed after the drop has been accepted @@ -247,7 +247,6 @@ sal_Int8 SwEditWin::ExecuteDrop( const ExecuteDropEvent& rEvt ) GetDataFlavorExVector(), m_nDropDestination, rEvt.mnAction, -//!! rEvt.GetSourceOptions(), nUserOpt, m_nDropFormat, nEventAction, 0, &rEvt.maDropEvent.Transferable ); @@ -256,7 +255,6 @@ sal_Int8 SwEditWin::ExecuteDrop( const ExecuteDropEvent& rEvt ) nRet = rEvt.mnAction; if( !SwTransferable::PasteData( aData, rSh, m_nDropAction, m_nDropFormat, m_nDropDestination, FALSE, rEvt.mbDefault, &aDocPt, nRet)) -//!! nRet = SFX_APP()->ExecuteDrop( rEvt ); nRet = DND_ACTION_NONE; else if ( SW_MOD()->pDragDrop ) //Bei internem D&D nicht mehr aufraeumen! @@ -404,7 +402,6 @@ sal_Int8 SwEditWin::AcceptDrop( const AcceptDropEvent& rEvt ) GetDataFlavorExVector(), m_nDropDestination, rEvt.mnAction, -//!! rEvt.GetSourceOptions(), nUserOpt, m_nDropFormat, nEventAction ); if( EXCHG_INOUT_ACTION_NONE != m_nDropAction ) @@ -433,7 +430,7 @@ sal_Int8 SwEditWin::AcceptDrop( const AcceptDropEvent& rEvt ) } else if( rEvt.mbDefault ) { - // JP 13.08.98: internes Drag&Drop: bei gleichem Doc ein Move + // internes Drag&Drop: bei gleichem Doc ein Move // ansonten ein Copy - Task 54974 nEventAction = pSrcSh->GetDoc() == rSh.GetDoc() ? DND_ACTION_MOVE @@ -495,7 +492,6 @@ sal_Int8 SwEditWin::AcceptDrop( const AcceptDropEvent& rEvt ) CleanupDropUserMarker(); rSh.UnSetVisCrsr(); -//!! return SFX_APP()->AcceptDrop( rEvt ); return DND_ACTION_NONE; } diff --git a/sw/source/ui/docvw/edtwin2.cxx b/sw/source/ui/docvw/edtwin2.cxx index a78fc7d113f4..11fa8eb8b2d9 100644 --- a/sw/source/ui/docvw/edtwin2.cxx +++ b/sw/source/ui/docvw/edtwin2.cxx @@ -192,7 +192,7 @@ void SwEditWin::RequestHelp(const HelpEvent &rEvt) sSuffix.EqualsAscii( pMarkToOLE )) sTxt = sTxt.Copy( 0, nFound - 1); } - // --> OD 2009-08-18 #i104300# + // #i104300# // special handling if target is a cross-reference bookmark { String sTmpSearchStr = sTxt.Copy( 1, sTxt.Len() ); @@ -223,8 +223,7 @@ void SwEditWin::RequestHelp(const HelpEvent &rEvt) } } } - // <-- - // --> OD 2007-07-26 #i80029# + // #i80029# BOOL bExecHyperlinks = rView.GetDocShell()->IsReadOnly(); if ( !bExecHyperlinks ) { @@ -237,7 +236,6 @@ void SwEditWin::RequestHelp(const HelpEvent &rEvt) sTxt.Insert( ViewShell::GetShellRes()->aHyperlinkClick, 0 ); } } - // <-- break; } case SwContentAtPos::SW_SMARTTAG: @@ -313,24 +311,6 @@ void SwEditWin::RequestHelp(const HelpEvent &rEvt) case RES_POSTITFLD: { - /* - SwPostItMgr* pMgr = rView.GetPostItMgr(); - if (pMgr->ShowNotes()) - { - SwFmtFld* pSwFmtFld = 0; - if (pMgr->ShowPreview(pFld,pSwFmtFld)) - { - SwPostIt* pPostIt = new SwPostIt(static_cast<Window*>(this),0,pSwFmtFld,pMgr,PB_Preview); - pPostIt->InitControls(); - pPostIt->SetReadonly(true); - pMgr->SetColors(pPostIt,static_cast<SwPostItField*>(pSwFmtFld->GetFld())); - pPostIt->SetVirtualPosSize(rEvt.GetMousePosPixel(),Size(180,70)); - pPostIt->ShowNote(); - SetPointerPosPixel(pPostIt->GetPosPixel() + Point(20,20)); - } - return; - } - */ break; } case RES_INPUTFLD: // BubbleHelp, da der Hinweis ggf ziemlich lang sein kann @@ -358,7 +338,7 @@ void SwEditWin::RequestHelp(const HelpEvent &rEvt) case RES_GETREFFLD: { - // --> OD 2008-01-09 #i85090# + // #i85090# const SwGetRefField* pRefFld( dynamic_cast<const SwGetRefField*>(pFld) ); OSL_ENSURE( pRefFld, "<SwEditWin::RequestHelp(..)> - unexpected type of <pFld>" ); @@ -381,7 +361,6 @@ void SwEditWin::RequestHelp(const HelpEvent &rEvt) sTxt = ((SwGetRefField*)pFld)->GetSetRefName(); } } - // <-- } break; } @@ -430,7 +409,7 @@ void SwEditWin::RequestHelp(const HelpEvent &rEvt) case SW_TABROW_VERT: nTabRes = STR_TABLE_ROW_ADJUST; break; - // --> FME 2004-07-30 #i32329# Enhanced table selection + // #i32329# Enhanced table selection case SW_TABSEL_HORI: case SW_TABSEL_HORI_RTL: case SW_TABSEL_VERT: @@ -445,7 +424,6 @@ void SwEditWin::RequestHelp(const HelpEvent &rEvt) case SW_TABCOLSEL_VERT: nTabRes = STR_TABLE_SELECT_COL; break; - // <-- } if(nTabRes) { @@ -458,14 +436,6 @@ void SwEditWin::RequestHelp(const HelpEvent &rEvt) } } -/* -aktuelle Zeichenvorlage anzeigen? - if( bWeiter && rEvt.GetMode() & ( HELPMODE_QUICK | HELPMODE_BALLOON )) - { - SwCharFmt* pChrFmt = rSh.GetCurCharFmt(); - - } -*/ if( bWeiter && pSdrView && bQuickBalloon) { SdrViewEvent aVEvt; @@ -571,16 +541,7 @@ void SwEditWin::Paint(const Rectangle& rRect) bPaintShadowCrsr = TRUE; } } -/* - //TODO/LATER: what's the replacement for this? Do we need it? - SwDocShell* pDocShell = GetView().GetDocShell(); - - SvInPlaceEnvironment *pIpEnv = pDocShell ? - pDocShell->GetIPEnv() : 0; - if ( pIpEnv && pIpEnv->GetRectsChangedLockCount() ) - //Wir stehen in Groessenverhandlungen (MM), Paint verzoegern - Invalidate( rRect ); - else */ + if ( GetView().GetVisArea().GetWidth() <= 0 || GetView().GetVisArea().GetHeight() <= 0 ) Invalidate( rRect ); diff --git a/sw/source/ui/docvw/edtwin3.cxx b/sw/source/ui/docvw/edtwin3.cxx index 8af8e702aeb4..34d7e9a196cc 100644 --- a/sw/source/ui/docvw/edtwin3.cxx +++ b/sw/source/ui/docvw/edtwin3.cxx @@ -138,7 +138,7 @@ BOOL SwEditWin::RulerColumnDrag( const MouseEvent& rMEvt, BOOL bVerticalMode) } // #i23726# -// --> OD 2005-02-18 #i42921# - add 3rd parameter <bVerticalMode> in order +// #i42921# - add 3rd parameter <bVerticalMode> in order // to consider vertical layout BOOL SwEditWin::RulerMarginDrag( const MouseEvent& rMEvt, const bool bVerticalMode ) @@ -146,7 +146,6 @@ BOOL SwEditWin::RulerMarginDrag( const MouseEvent& rMEvt, SvxRuler& rRuler = bVerticalMode ? rView.GetVLineal() : rView.GetHLineal(); return !rRuler.StartDocDrag( rMEvt, RULER_TYPE_INDENT); } -// <-- LAYOUT_NS Dialog* GetSearchDialog() { @@ -179,8 +178,8 @@ void SwEditWin::DataChanged( const DataChangedEvent& rDCEvt ) Window::DataChanged( rDCEvt ); SwWrtShell* pSh = GetView().GetWrtShellPtr(); - //#99906# DataChanged() is sometimes called prior to creating - // the SwWrtShell + // DataChanged() is sometimes called prior to creating + // the SwWrtShell if(!pSh) return; BOOL bViewWasLocked = pSh->IsViewLocked(), bUnlockPaint = FALSE; diff --git a/sw/source/ui/docvw/srcedtw.cxx b/sw/source/ui/docvw/srcedtw.cxx index 9b414a528464..816c0933d7a9 100644 --- a/sw/source/ui/docvw/srcedtw.cxx +++ b/sw/source/ui/docvw/srcedtw.cxx @@ -66,16 +66,8 @@ struct SwTextPortion SV_DECL_VARARR(SwTextPortions, SwTextPortion,16,16) -/* -----------------15.01.97 12.07------------------- - ---------------------------------------------------*/ - SV_IMPL_VARARR(SwTextPortions, SwTextPortion) -/*-----------------15.01.97 12.08------------------- - ---------------------------------------------------*/ - static void lcl_Highlight(const String& rSource, SwTextPortions& aPortionList) { const sal_Unicode cOpenBracket = '<'; @@ -502,12 +494,12 @@ void SwSrcEditWindow::CreateTextEngine() //Scrollbars anlegen pHScrollbar = new ScrollBar(this, WB_3DLOOK |WB_HSCROLL|WB_DRAG); - pHScrollbar->EnableRTL( false ); // #107300# --- RTL --- no mirroring for scrollbars + pHScrollbar->EnableRTL( false ); // --- RTL --- no mirroring for scrollbars pHScrollbar->SetScrollHdl(LINK(this, SwSrcEditWindow, ScrollHdl)); pHScrollbar->Show(); pVScrollbar = new ScrollBar(this, WB_3DLOOK |WB_VSCROLL|WB_DRAG); - pVScrollbar->EnableRTL( false ); // #107300# --- RTL --- no mirroring for scrollbars + pVScrollbar->EnableRTL( false ); // --- RTL --- no mirroring for scrollbars pVScrollbar->SetScrollHdl(LINK(this, SwSrcEditWindow, ScrollHdl)); pHScrollbar->EnableDrag(); pVScrollbar->Show(); @@ -541,7 +533,6 @@ void SwSrcEditWindow::CreateTextEngine() SfxBindings& rBind = GetSrcView()->GetViewFrame()->GetBindings(); rBind.Invalidate( SID_TABLE_CELL ); -// rBind.Invalidate( SID_ATTR_CHAR_FONTHEIGHT ); } /*-------------------------------------------------------------------- @@ -607,15 +598,10 @@ IMPL_LINK(SwSrcEditWindow, ScrollHdl, ScrollBar*, pScroll) return 0; } -/*-----------------15.01.97 09.22------------------- - ---------------------------------------------------*/ - IMPL_LINK( SwSrcEditWindow, SyntaxTimerHdl, Timer *, pTimer ) { Time aSyntaxCheckStart; OSL_ENSURE( pTextView, "Noch keine View, aber Syntax-Highlight ?!" ); - // pTextEngine->SetUpdateMode( FALSE ); bHighlighting = TRUE; USHORT nLine; @@ -662,16 +648,6 @@ IMPL_LINK( SwSrcEditWindow, SyntaxTimerHdl, Timer *, pTimer ) break; } } - // os: #43050# hier wird ein TextView-Problem umpopelt: - // waehrend des Highlightings funktionierte das Scrolling nicht - /* MT: Shouldn't be a oproblem any more, using IdeFormatter in Insert/RemoveAttrib now. - - TextView* pTmp = pTextEngine->GetActiveView(); - pTextEngine->SetActiveView(0); - // pTextEngine->SetUpdateMode( TRUE ); - pTextEngine->SetActiveView(pTmp); - pTextView->ShowCursor(FALSE, FALSE); - */ if(aSyntaxLineTable.Count() && !pTimer->IsActive()) pTimer->Start(); @@ -685,9 +661,6 @@ IMPL_LINK( SwSrcEditWindow, SyntaxTimerHdl, Timer *, pTimer ) return 0; } -/*-----------------15.01.97 10.01------------------- - ---------------------------------------------------*/ void SwSrcEditWindow::DoSyntaxHighlight( USHORT nPara ) { @@ -700,14 +673,11 @@ void SwSrcEditWindow::DoSyntaxHighlight( USHORT nPara ) String aSource( pTextEngine->GetText( nPara ) ); pTextEngine->SetUpdateMode( FALSE ); ImpDoHighlight( aSource, nPara ); - // os: #43050# hier wird ein TextView-Problem umpopelt: - // waehrend des Highlightings funktionierte das Scrolling nicht TextView* pTmp = pTextEngine->GetActiveView(); pTmp->SetAutoScroll(FALSE); pTextEngine->SetActiveView(0); pTextEngine->SetUpdateMode( TRUE ); pTextEngine->SetActiveView(pTmp); - // Bug 72887 show the cursor pTmp->SetAutoScroll(TRUE); pTmp->ShowCursor( FALSE/*pTmp->IsAutoScroll()*/ ); @@ -716,10 +686,6 @@ void SwSrcEditWindow::DoSyntaxHighlight( USHORT nPara ) } } -/*-----------------15.01.97 09.49------------------- - ---------------------------------------------------*/ - void SwSrcEditWindow::DoDelayedSyntaxHighlight( USHORT nPara ) { if ( !bHighlighting && bDoSyntaxHighlight ) @@ -729,10 +695,6 @@ void SwSrcEditWindow::DoDelayedSyntaxHighlight( USHORT nPara ) } } -/*-----------------15.01.97 11.32------------------- - ---------------------------------------------------*/ - void SwSrcEditWindow::ImpDoHighlight( const String& rSource, USHORT nLineOff ) { SwTextPortions aPortionList; @@ -801,10 +763,6 @@ void SwSrcEditWindow::ImpDoHighlight( const String& rSource, USHORT nLineOff ) } } -/*-----------------30.06.97 09:12------------------- - ---------------------------------------------------*/ - void SwSrcEditWindow::Notify( SfxBroadcaster& /*rBC*/, const SfxHint& rHint ) { if ( rHint.ISA( TextHint ) ) @@ -836,10 +794,6 @@ void SwSrcEditWindow::ConfigurationChanged( utl::ConfigurationBroadcaster* pBrdC SetFont(); } -/*-----------------30.06.97 13:22------------------- - ---------------------------------------------------*/ - void SwSrcEditWindow::Invalidate(USHORT ) { pOutWin->Invalidate(); @@ -876,15 +830,6 @@ void SwSrcEditWindow::GetFocus() pOutWin->GrabFocus(); } -/*void SwSrcEditWindow::LoseFocus() -{ - Window::LoseFocus(); -// pOutWin->LoseFocus(); -// rView.LostFocus(); -} */ -/* -----------------------------29.08.2002 13:21------------------------------ - - ---------------------------------------------------------------------------*/ BOOL lcl_GetLanguagesForEncoding(rtl_TextEncoding eEnc, LanguageType aLanguages[]) { switch(eEnc) @@ -1081,9 +1026,7 @@ void SwSrcEditWindow::SetFont() GetTextEngine()->SetFont( aFont ); pOutWin->SetFont(aFont); } -/* -----------------------------29.08.2002 13:47------------------------------ - ---------------------------------------------------------------------------*/ void SwSrcEditWindow::SetTextEncoding(rtl_TextEncoding eEncoding) { eSourceEncoding = eEncoding; |