[PATCH] more work on comments in sw/source/core/doc
Philipp Riemer (via Code Review)
gerrit at gerrit.libreoffice.org
Sun Apr 7 12:37:33 PDT 2013
Hi,
I have submitted a patch for review:
https://gerrit.libreoffice.org/3263
To pull it, you can do:
git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/63/3263/1
more work on comments in sw/source/core/doc
Change-Id: I4fbf683da081ad04dfd1b9ea830aa94c38f33d43
---
M sw/source/core/doc/doc.cxx
M sw/source/core/doc/docbm.cxx
M sw/source/core/doc/docdraw.cxx
M sw/source/core/doc/docedt.cxx
M sw/source/core/doc/docfld.cxx
M sw/source/core/doc/docfmt.cxx
M sw/source/core/doc/docnew.cxx
M sw/source/core/doc/docnum.cxx
M sw/source/core/doc/docruby.cxx
M sw/source/core/doc/fmtcol.cxx
M sw/source/core/doc/number.cxx
11 files changed, 21 insertions(+), 43 deletions(-)
diff --git a/sw/source/core/doc/doc.cxx b/sw/source/core/doc/doc.cxx
index a337f57..084289f 100644
--- a/sw/source/core/doc/doc.cxx
+++ b/sw/source/core/doc/doc.cxx
@@ -1356,13 +1356,10 @@
pStPage = (SwPageFrm*)pStPage->GetNext();
}
-
- //
// now that we have identified the valid pages for printing according
// to the print settings we need to get the PageRange to use and
// use both results to get the actual pages to be printed
// (post-it settings need to be taken into account later on!)
- //
// get PageRange value to use
OUString aPageRange;
@@ -1802,7 +1799,6 @@
}
}
-// Document - info
void SwDoc::DocInfoChgd( )
{
GetSysFldType( RES_DOCINFOFLD )->UpdateFlds();
@@ -2215,9 +2211,7 @@
}
}
- //
// Remove any hidden paragraph (hidden text attribute)
- //
for( sal_uLong n = GetNodes().Count(); n; )
{
SwTxtNode* pTxtNd = GetNodes()[ --n ]->GetTxtNode();
@@ -2355,9 +2349,7 @@
if( aIter.First( TYPE( SwFmtFld ) ) )
bRet = true;
- //
// Search for any hidden paragraph (hidden text attribute)
- //
if( ! bRet )
{
for( sal_uLong n = GetNodes().Count(); !bRet && (n > 0); )
diff --git a/sw/source/core/doc/docbm.cxx b/sw/source/core/doc/docbm.cxx
index 7d6f59c..4454659 100644
--- a/sw/source/core/doc/docbm.cxx
+++ b/sw/source/core/doc/docbm.cxx
@@ -1037,7 +1037,7 @@
const IDocumentMarkAccess* SwDoc::getIDocumentMarkAccess() const
{ return static_cast< IDocumentMarkAccess* >(mpMarkManager.get()); }
-// SaveBookmark
+// SaveBookmark methods
SaveBookmark::SaveBookmark(
bool bSavePos,
diff --git a/sw/source/core/doc/docdraw.cxx b/sw/source/core/doc/docdraw.cxx
index 80cedc9..a147595 100644
--- a/sw/source/core/doc/docdraw.cxx
+++ b/sw/source/core/doc/docdraw.cxx
@@ -512,12 +512,11 @@
}
}
+#include <svx/sxenditm.hxx>
+
// Is also called by the Sw3 Reader, if there was an error when reading the
// drawing layer. If it is called by the Sw3 Reader the layer is rebuilt
// from scratch.
-
-#include <svx/sxenditm.hxx>
-
void SwDoc::InitDrawModel()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLog, "SW", "JP93722", "SwDoc::InitDrawModel" );
diff --git a/sw/source/core/doc/docedt.cxx b/sw/source/core/doc/docedt.cxx
index 39d895d..e397077 100644
--- a/sw/source/core/doc/docedt.cxx
+++ b/sw/source/core/doc/docedt.cxx
@@ -1473,6 +1473,7 @@
return bRet;
}
+///@todo fix implementation
bool SwDoc::DeleteAndJoinWithRedlineImpl( SwPaM & rPam, const bool )
{
OSL_ENSURE( IsRedlineOn(), "DeleteAndJoinWithRedline: redline off" );
diff --git a/sw/source/core/doc/docfld.cxx b/sw/source/core/doc/docfld.cxx
index c27319c..48bec3c4 100644
--- a/sw/source/core/doc/docfld.cxx
+++ b/sw/source/core/doc/docfld.cxx
@@ -298,9 +298,7 @@
return pRet;
}
-/*
- * All have to be re-evaluated.
- */
+// All have to be re-evaluated.
void SwDoc::UpdateFlds( SfxPoolItem *pNewHt, bool bCloseDB )
{
// Call Modify() for every field type,
@@ -2209,18 +2207,18 @@
delete pFldSortLst;
pFldSortLst = new _SetGetExpFlds;
- /// consider and unhide sections
- /// with hide condition, only in mode GETFLD_ALL (<eGetMode == GETFLD_ALL>)
- /// notes by OD:
- /// eGetMode == GETFLD_CALC in call from methods SwDoc::FldsToCalc
- /// eGetMode == GETFLD_EXPAND in call from method SwDoc::FldsToExpand
- /// eGetMode == GETFLD_ALL in call from method SwDoc::UpdateExpFlds
- /// I figured out that hidden section only have to be shown,
- /// if fields have updated (call by SwDoc::UpdateExpFlds) and thus
- /// the hide conditions of section have to be updated.
- /// For correct updating the hide condition of a section, its position
- /// have to be known in order to insert the hide condition as a new
- /// expression field into the sorted field list (<pFldSortLst>).
+ // consider and unhide sections
+ // with hide condition, only in mode GETFLD_ALL (<eGetMode == GETFLD_ALL>)
+ // notes by OD:
+ // eGetMode == GETFLD_CALC in call from methods SwDoc::FldsToCalc
+ // eGetMode == GETFLD_EXPAND in call from method SwDoc::FldsToExpand
+ // eGetMode == GETFLD_ALL in call from method SwDoc::UpdateExpFlds
+ // I figured out that hidden section only have to be shown,
+ // if fields have updated (call by SwDoc::UpdateExpFlds) and thus
+ // the hide conditions of section have to be updated.
+ // For correct updating the hide condition of a section, its position
+ // have to be known in order to insert the hide condition as a new
+ // expression field into the sorted field list (<pFldSortLst>).
if ( eGetMode == GETFLD_ALL )
// Collect the sections first. Supply sections that are hidden by condition
// with frames so that the contained fields are sorted properly.
diff --git a/sw/source/core/doc/docfmt.cxx b/sw/source/core/doc/docfmt.cxx
index 719fb5a..0eeee94 100644
--- a/sw/source/core/doc/docfmt.cxx
+++ b/sw/source/core/doc/docfmt.cxx
@@ -1981,8 +1981,7 @@
rDestArr, pSrcColl->GetNextTxtFmtColl().GetName() ) );
if(pSrcColl->IsAssignedToListLevelOfOutlineStyle())
- pDstColl->AssignToListLevelOfOutlineStyle(pSrcColl->GetAssignedOutlineStyleLevel());//<-end,zhaojianwei
- //<-end
+ pDstColl->AssignToListLevelOfOutlineStyle(pSrcColl->GetAssignedOutlineStyleLevel());
//FEATURE::CONDCOLL
if( RES_CONDTXTFMTCOLL == pSrc->Which() )
diff --git a/sw/source/core/doc/docnew.cxx b/sw/source/core/doc/docnew.cxx
index 463037d..ea7c899 100644
--- a/sw/source/core/doc/docnew.cxx
+++ b/sw/source/core/doc/docnew.cxx
@@ -325,9 +325,7 @@
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLog, "SW", "JP93722", "SwDoc::SwDoc" );
- //
// COMPATIBILITY FLAGS START
- //
// Note: Any non-hidden compatibility flag should obtain its default
// by asking SvtCompatibilityOptions, see below.
@@ -346,9 +344,7 @@
mbDoNotJustifyLinesWithManualBreak = !aOptions.IsExpandWordSpace();
- //
// COMPATIBILITY FLAGS END
- //
/*
* DefaultFormats and DefaultFormatCollections (FmtColl)
diff --git a/sw/source/core/doc/docnum.cxx b/sw/source/core/doc/docnum.cxx
index 32cf8e3..13be89d 100644
--- a/sw/source/core/doc/docnum.cxx
+++ b/sw/source/core/doc/docnum.cxx
@@ -684,7 +684,7 @@
return nPos;
}
-// Ad this bullet point:
+// Add this bullet point:
// A Name can contain a Number and/or the Text.
//
diff --git a/sw/source/core/doc/docruby.cxx b/sw/source/core/doc/docruby.cxx
index 25b11ee..0a5e703 100644
--- a/sw/source/core/doc/docruby.cxx
+++ b/sw/source/core/doc/docruby.cxx
@@ -45,8 +45,6 @@
* Members in the list:
* - String - the orig text
* - SwFmtRuby - the ruby attribut
- *
- *
*/
sal_uInt16 SwDoc::FillRubyList( const SwPaM& rPam, SwRubyList& rList,
sal_uInt16 nMode )
diff --git a/sw/source/core/doc/fmtcol.cxx b/sw/source/core/doc/fmtcol.cxx
index fc71b66..ccf7b2b 100644
--- a/sw/source/core/doc/fmtcol.cxx
+++ b/sw/source/core/doc/fmtcol.cxx
@@ -125,7 +125,7 @@
SvxLRSpaceItem *pNewLRSpace = 0, *pOldLRSpace = 0;
SvxFontHeightItem* aFontSizeArr[3] = {0,0,0};
// #i70223#
- const bool bAssignedToListLevelOfOutlineStyle(IsAssignedToListLevelOfOutlineStyle());//#outline level ,zhaojianwei
+ const bool bAssignedToListLevelOfOutlineStyle(IsAssignedToListLevelOfOutlineStyle());
const SwNumRuleItem* pNewNumRuleItem( 0L );
SwAttrSetChg *pNewChgSet = 0, *pOldChgSet = 0;
@@ -618,7 +618,7 @@
aCondColls.push_back( pNew );
}
}
-//#outline level, zhaojianwei
+
void SwTxtFmtColl::SetAttrOutlineLevel( int nLevel)
{
OSL_ENSURE( 0 <= nLevel && nLevel <= MAXLEVEL ,"SwTxtFmtColl: Level Out Of Range" );
@@ -670,8 +670,5 @@
mbAssignedToOutlineStyle = false;
ResetFmtAttr(RES_PARATR_OUTLINELEVEL);
}
-//<-end,zhaojianwei
-
-//FEATURE::CONDCOLL
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/core/doc/number.cxx b/sw/source/core/doc/number.cxx
index c85ec41..e028eb2 100644
--- a/sw/source/core/doc/number.cxx
+++ b/sw/source/core/doc/number.cxx
@@ -377,8 +377,6 @@
}
}
-
-// handle new parameter <eDefaultNumberFormatPositionAndSpaceMode>
SwNumRule::SwNumRule( const String& rNm,
const SvxNumberFormat::SvxNumPositionAndSpaceMode eDefaultNumberFormatPositionAndSpaceMode,
SwNumRuleType eType,
--
To view, visit https://gerrit.libreoffice.org/3263
To unsubscribe, visit https://gerrit.libreoffice.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I4fbf683da081ad04dfd1b9ea830aa94c38f33d43
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Philipp Riemer <ruderphilipp at gmail.com>
More information about the LibreOffice
mailing list