diff options
-rw-r--r-- | sw/source/core/unocore/unocrsrhelper.cxx | 78 | ||||
-rw-r--r-- | sw/source/core/unocore/unofield.cxx | 8 | ||||
-rw-r--r-- | sw/source/core/unocore/unoidx.cxx | 15 | ||||
-rw-r--r-- | sw/source/core/unocore/unosect.cxx | 30 | ||||
-rw-r--r-- | sw/source/core/unocore/unosett.cxx | 28 |
5 files changed, 37 insertions, 122 deletions
diff --git a/sw/source/core/unocore/unocrsrhelper.cxx b/sw/source/core/unocore/unocrsrhelper.cxx index e23268e6e125..b6349ee6f1fd 100644 --- a/sw/source/core/unocore/unocrsrhelper.cxx +++ b/sw/source/core/unocore/unocrsrhelper.cxx @@ -86,9 +86,7 @@ #include <comphelper/sequenceashashmap.hxx> #include <com/sun/star/embed/ElementModes.hpp> #include <com/sun/star/embed/XStorage.hpp> -// --> OD 2008-11-26 #158694# #include <SwNodeNum.hxx> -// <-- #include <fmtmeta.hxx> @@ -135,7 +133,7 @@ GetNestedTextContent(SwTxtNode & rTextNode, xub_StrLen const nIndex, } /* -------------------------------------------------- -* Lesen spezieller Properties am Cursor + * Read the special properties of the cursor * --------------------------------------------------*/ sal_Bool getCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry , SwPaM& rPam @@ -149,7 +147,6 @@ sal_Bool getCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry sal_Bool bDone = sal_True; switch(rEntry.nWID) { - // --> OD 2008-11-26 #158694# case FN_UNO_PARA_CONT_PREV_SUBTREE: if (pAny) { @@ -187,24 +184,7 @@ sal_Bool getCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry *pAny <<= OUString(sRet); } break; - // <-- - // --> OD 2008-05-20 #outlinelevel# - no longer needed -// case FN_UNO_PARA_CHAPTER_NUMBERING_LEVEL: -// if (pAny) -// { -// const SwTxtNode * pTmpNode = pNode; - -// if (!pTmpNode) -// pTmpNode = rPam.GetNode()->GetTxtNode(); - -// sal_Int8 nRet = -1; -// if (pTmpNode && pTmpNode->GetOutlineLevel() != NO_NUMBERING) -// nRet = sal::static_int_cast< sal_Int8 >(pTmpNode->GetOutlineLevel()); -// *pAny <<= nRet; -// } -// break; - // <-- - case RES_PARATR_OUTLINELEVEL: //#outlinelevel added by zhaojianwei + case RES_PARATR_OUTLINELEVEL: if (pAny) { const SwTxtNode * pTmpNode = pNode; @@ -218,7 +198,7 @@ sal_Bool getCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry *pAny <<= nRet; } - break; //<-end,zhaojianwei + break; case FN_UNO_PARA_CONDITIONAL_STYLE_NAME: case FN_UNO_PARA_STYLE : { @@ -263,16 +243,13 @@ sal_Bool getCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry break; case FN_UNO_NUM_LEVEL : case FN_UNO_IS_NUMBER : - // --> OD 2008-07-14 #i91601# + // #i91601# case FN_UNO_LIST_ID: - // <-- case FN_NUMBER_NEWSTART: { // a multi selection is not considered const SwTxtNode* pTxtNd = rPam.GetNode()->GetTxtNode(); - // --> OD 2010-01-13 #b6912256# if ( pTxtNd && pTxtNd->IsInList() ) - // <-- { if( pAny ) { @@ -283,13 +260,12 @@ sal_Bool getCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry BOOL bIsNumber = pTxtNd->IsCountedInList(); pAny->setValue(&bIsNumber, ::getBooleanCppuType()); } - // --> OD 2008-07-14 #i91601# + // #i91601# else if ( rEntry.nWID == FN_UNO_LIST_ID ) { const String sListId = pTxtNd->GetListId(); *pAny <<= OUString(sListId); } - // <-- else /*if(rEntry.nWID == UNO_NAME_PARA_IS_NUMBERING_RESTART)*/ { BOOL bIsRestart = pTxtNd->IsListRestart(); @@ -308,7 +284,7 @@ sal_Bool getCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry *pAny <<= static_cast<sal_Int16>( 0 ); else if(rEntry.nWID == FN_UNO_IS_NUMBER) *pAny <<= false; - // --> OD 2008-07-14 #i91601# + // #i91601# else if ( rEntry.nWID == FN_UNO_LIST_ID ) { *pAny <<= OUString(); @@ -349,7 +325,7 @@ sal_Bool getCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry } } else - //auch hier - nicht zu unterscheiden + //also here - indistinguishable eNewState = PropertyState_DEFAULT_VALUE; } break; @@ -393,16 +369,6 @@ sal_Bool getCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry eNewState = PropertyState_DEFAULT_VALUE; } break; -/* laesst sich nicht feststellen -* case FN_UNO_BOOKMARK: - { - if() - { - uno::Reference< XBookmark > xBkm = SwXBookmarks::GetObject(rBkm); - rAny.set(&xBkm, ::getCppuType((const XBookmark*)0)()); - } - } - break;*/ case FN_UNO_TEXT_TABLE: case FN_UNO_CELL: { @@ -589,7 +555,7 @@ sal_Bool getCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry } break; case RES_TXTATR_CHARFMT: - // kein break hier! + // no break here! default: bDone = sal_False; } if( bDone ) @@ -647,7 +613,7 @@ void setNumberingProperty(const Any& rValue, SwPaM& rPam) else { - // CharStyle besorgen und an der Rule setzen + // get CharStyle and set the rule sal_uInt16 nChCount = pDoc->GetCharFmts()->Count(); SwCharFmt* pCharFmt = 0; for(sal_uInt16 nCharFmt = 0; nCharFmt < nChCount; nCharFmt++) @@ -665,7 +631,7 @@ void setNumberingProperty(const Any& rValue, SwPaM& rPam) SfxStyleSheetBasePool* pPool = pDoc->GetDocShell()->GetStyleSheetPool(); SfxStyleSheetBase* pBase; pBase = pPool->Find(pNewCharStyles[i], SFX_STYLE_FAMILY_CHAR); - // soll das wirklich erzeugt werden? + // shall it really be created? if(!pBase) pBase = &pPool->Make(pNewCharStyles[i], SFX_STYLE_FAMILY_PAGE); pCharFmt = ((SwDocStyleSheet*)pBase)->GetCharFmt(); @@ -674,7 +640,7 @@ void setNumberingProperty(const Any& rValue, SwPaM& rPam) aFmt.SetCharFmt(pCharFmt); } } - //jetzt nochmal fuer Fonts + //Now again for fonts if( pBulletFontNames[i] != SwXNumberingRules::GetInvalidStyle() && ( @@ -698,7 +664,7 @@ void setNumberingProperty(const Any& rValue, SwPaM& rPam) } UnoActionContext aAction(pDoc); - if( rPam.GetNext() != &rPam ) // Mehrfachselektion ? + if( rPam.GetNext() != &rPam ) // Multiple selection? { pDoc->StartUndo( UNDO_START, NULL ); SwPamRanges aRangeArr( rPam ); @@ -727,7 +693,7 @@ void setNumberingProperty(const Any& rValue, SwPaM& rPam) // no start of a new list pDoc->SetNumRule( rPam, *pRule, false ); } - // --> OD 2009-08-18 #i103817# + // #i103817# // outline numbering else { @@ -737,7 +703,6 @@ void setNumberingProperty(const Any& rValue, SwPaM& rPam) throw RuntimeException(); pDoc->SetNumRule( rPam, *pRule, false ); } - // <-- } } else if(rValue.getValueType() == ::getVoidCppuType()) @@ -768,7 +733,7 @@ void GetCurPageStyle(SwPaM& rPaM, String &rString) } /* -------------------------------------------------- - * spezielle Properties am Cursor zuruecksetzen + * reset special properties of the cursor * --------------------------------------------------*/ void resetCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry, SwPaM& rPam) { @@ -784,7 +749,7 @@ void resetCrsrPropertyValue(const SfxItemPropertySimpleEntry& rEntry, SwPaM& rPa { UnoActionContext aAction(pDoc); - if( rPam.GetNext() != &rPam ) // Mehrfachselektion ? + if( rPam.GetNext() != &rPam ) // Multiple selection? { pDoc->StartUndo( UNDO_START, NULL ); SwPamRanges aRangeArr( rPam ); @@ -917,8 +882,8 @@ void InsertFile(SwUnoCrsr* pUnoCrsr, SfxObjectShellRef aRef( pDocSh ); pDocSh->RegisterTransfer( *pMed ); - pMed->DownLoad(); // ggfs. den DownLoad anstossen - if( aRef.Is() && 1 < aRef->GetRefCount() ) // noch gueltige Ref? + pMed->DownLoad(); // if necessary: start the download + if( aRef.Is() && 1 < aRef->GetRefCount() ) // Ref still valid? { SwReader* pRdr; SfxItemSet* pSet = pMed->GetItemSet(); @@ -937,7 +902,7 @@ void InsertFile(SwUnoCrsr* pUnoCrsr, SwNodeIndex aSave( pUnoCrsr->GetPoint()->nNode, -1 ); xub_StrLen nCntnt = pUnoCrsr->GetPoint()->nContent.GetIndex(); - sal_uInt32 nErrno = pRdr->Read( *pRead ); // und Dokument einfuegen + sal_uInt32 nErrno = pRdr->Read( *pRead ); // and paste the document if(!nErrno) { @@ -953,13 +918,6 @@ void InsertFile(SwUnoCrsr* pUnoCrsr, delete pRdr; - // ggfs. alle Verzeichnisse updaten: -/* if( pWrtShell->IsUpdateTOX() ) - { - SfxRequest aReq( *this, FN_UPDATE_TOX ); - Execute( aReq ); - pWrtShell->SetUpdateTOX( sal_False ); // wieder zurueck setzen - }*/ } } diff --git a/sw/source/core/unocore/unofield.cxx b/sw/source/core/unocore/unofield.cxx index d0b665edd211..172457c1fde7 100644 --- a/sw/source/core/unocore/unofield.cxx +++ b/sw/source/core/unocore/unofield.cxx @@ -1542,7 +1542,7 @@ void SwXTextField::attachToRange( SwFieldType* pFldType = pDoc->GetFldType(RES_SETEXPFLD, m_sTypeName, sal_True); if(!pFldType) throw uno::RuntimeException(); - //#93192# detect the field type's sub type and set an appropriate number format + // detect the field type's sub type and set an appropriate number format if(m_pProps->bFormatIsDefault && nsSwGetSetExpType::GSE_STRING == ((SwSetExpFieldType*)pFldType)->GetType()) m_pProps->nFormat = -1; @@ -1879,7 +1879,6 @@ void SwXTextField::setPropertyValue(const OUString& rPropertyName, const uno::An } else { - // -> #111840# SwDoc * pDoc = GetDoc(); if (NULL != pDoc) @@ -1891,7 +1890,6 @@ void SwXTextField::setPropertyValue(const OUString& rPropertyName, const uno::An aPosition.nContent = *pTxtFld->GetStart(); pDoc->PutValueToField( aPosition, rValue, pEntry->nWID); } - // <- #111840# } pField->PutValue( rValue, pEntry->nWID ); @@ -1901,7 +1899,7 @@ void SwXTextField::setPropertyValue(const OUString& rPropertyName, const uno::An const_cast<SwFmtFld*>(pFmtFld)->Broadcast(SwFmtFldHint( 0, SWFMTFLD_CHANGED )); } - //#114571# changes of the expanded string have to be notified + // changes of the expanded string have to be notified //#to the SwTxtFld if(RES_DBFLD == nWhich && pFmtFld->GetTxtFld()) { @@ -2263,10 +2261,8 @@ void SwXTextField::update( ) throw (uno::RuntimeException) } break; } - // --> FME 2004-10-06 #116480# // Text formatting has to be triggered. const_cast<SwFmtFld*>(pFmtFld)->Modify( 0, 0 ); - // <-- } else m_bCallUpdate = sal_True; diff --git a/sw/source/core/unocore/unoidx.cxx b/sw/source/core/unocore/unoidx.cxx index d428b0beacce..b59fdb0a680e 100644 --- a/sw/source/core/unocore/unoidx.cxx +++ b/sw/source/core/unocore/unoidx.cxx @@ -1851,7 +1851,7 @@ throw (lang::IllegalArgumentException, uno::RuntimeException) } SwUnoInternalPaM aPam(*pDoc); - //das muss jetzt sal_True liefern + //which must now return sal_True ::sw::XTextRangeToSwPaM(aPam, xTextRange); SwTOXMark aMark (pTOXType); if (m_pImpl->m_sAltText.getLength()) @@ -2897,7 +2897,7 @@ throw (lang::IllegalArgumentException, lang::IndexOutOfBoundsException, } aToken.nChapterFormat = nFormat; } -//--->i53420 +// #i53420# else if (pProperties[j].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("ChapterLevel"))) { @@ -2908,7 +2908,6 @@ throw (lang::IllegalArgumentException, lang::IndexOutOfBoundsException, } aToken.nOutlineLevel = nLevel; } -//<--- else if (pProperties[j].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("BibliographyDataField"))) { @@ -2943,7 +2942,7 @@ throw (lang::IllegalArgumentException, lang::IndexOutOfBoundsException, { aToken.eTokenType = TOKEN_ENTRY; } -//---> i53420 +// #i53420# // check for chapter format allowed values if it was TOKEN_ENTRY_NO type // only allowed value are CF_NUMBER and CF_NUM_NOPREPST_TITLE // reading from file @@ -2958,7 +2957,6 @@ throw (lang::IllegalArgumentException, lang::IndexOutOfBoundsException, throw lang::IllegalArgumentException(); } } -//<--- sPattern += aToken.GetString(); } SwForm aForm(rTOXBase.GetTOXForm()); @@ -3016,7 +3014,7 @@ throw (lang::IndexOutOfBoundsException, lang::WrappedTargetException, { case TOKEN_ENTRY_NO: { -//--->i53420 +// #i53420# // writing to file (from doc to properties) sal_Int32 nElements = 2; sal_Int32 nCurrentElement = 0; @@ -3067,7 +3065,6 @@ throw (lang::IndexOutOfBoundsException, lang::WrappedTargetException, pArr[nCurrentElement].Name = C2U("ChapterLevel"); pArr[nCurrentElement].Value <<= aToken.nOutlineLevel; } -//<--- } break; case TOKEN_ENTRY: // no difference between Entry and Entry Text @@ -3173,11 +3170,9 @@ throw (lang::IndexOutOfBoundsException, lang::WrappedTargetException, break; } pArr[2].Value <<= nVal; -//--->i53420 +// #i53420# pArr[3].Name = C2U("ChapterLevel"); - // pArr[3].Value <<= aToken.nOutlineLevel; -//<--- } break; case TOKEN_LINK_START: diff --git a/sw/source/core/unocore/unosect.cxx b/sw/source/core/unocore/unosect.cxx index a81f29c3edb3..eff988c98f19 100644 --- a/sw/source/core/unocore/unosect.cxx +++ b/sw/source/core/unocore/unosect.cxx @@ -63,7 +63,6 @@ #include <fmtclbl.hxx> #include <editeng/frmdiritem.hxx> #include <fmtcntnt.hxx> -/* #109700# */ #include <editeng/lrspitem.hxx> @@ -85,15 +84,13 @@ struct SwTextSectionProperties_Impl ::std::auto_ptr<SvXMLAttrContainerItem> m_pXMLAttr; ::std::auto_ptr<SwFmtNoBalancedColumns> m_pNoBalanceItem; ::std::auto_ptr<SvxFrameDirectionItem> m_pFrameDirItem; - ::std::auto_ptr<SvxLRSpaceItem> m_pLRSpaceItem; // #109700# + ::std::auto_ptr<SvxLRSpaceItem> m_pLRSpaceItem; bool m_bDDE; bool m_bHidden; bool m_bCondHidden; bool m_bProtect; - // --> FME 2004-06-22 #114856# edit in readonly sections bool m_bEditInReadonly; - // <-- bool m_bUpdateType; SwTextSectionProperties_Impl() @@ -101,9 +98,7 @@ struct SwTextSectionProperties_Impl , m_bHidden(false) , m_bCondHidden(false) , m_bProtect(false) - // --> FME 2004-06-22 #114856# edit in readonly sections , m_bEditInReadonly(false) - // <-- , m_bUpdateType(true) { } @@ -347,15 +342,13 @@ throw (lang::IllegalArgumentException, uno::RuntimeException) aSect.SetHidden(m_pImpl->m_pProps->m_bHidden); aSect.SetProtectFlag(m_pImpl->m_pProps->m_bProtect); - // --> FME 2004-06-22 #114856# edit in readonly sections aSect.SetEditInReadonlyFlag(m_pImpl->m_pProps->m_bEditInReadonly); - // <-- SfxItemSet aSet(pDoc->GetAttrPool(), RES_COL, RES_COL, RES_BACKGROUND, RES_BACKGROUND, RES_FTN_AT_TXTEND, RES_FRAMEDIR, - RES_LR_SPACE, RES_LR_SPACE, // #109700# + RES_LR_SPACE, RES_LR_SPACE, RES_UNKNOWNATR_CONTAINER,RES_UNKNOWNATR_CONTAINER, 0); if (m_pImpl->m_pProps->m_pBrushItem.get()) @@ -386,7 +379,6 @@ throw (lang::IllegalArgumentException, uno::RuntimeException) { aSet.Put(*m_pImpl->m_pProps->m_pFrameDirItem); } - /* #109700# */ if (m_pImpl->m_pProps->m_pLRSpaceItem.get()) { aSet.Put(*m_pImpl->m_pProps->m_pLRSpaceItem); @@ -402,7 +394,7 @@ throw (lang::IllegalArgumentException, uno::RuntimeException) pRet->GetFmt()->Add(m_pImpl.get()); pRet->GetFmt()->SetXObject(static_cast< ::cppu::OWeakObject*>(this)); - // #97450# XML import must hide sections depending on their old + // XML import must hide sections depending on their old // condition status if (m_pImpl->m_pProps->m_sCondition.getLength() != 0) { @@ -795,7 +787,6 @@ throw (beans::UnknownPropertyException, beans::PropertyVetoException, } } break; - // --> FME 2004-06-22 #114856# edit in readonly sections case WID_SECT_EDIT_IN_READONLY: { sal_Bool bVal(sal_False); @@ -812,7 +803,6 @@ throw (beans::UnknownPropertyException, beans::PropertyVetoException, pSectionData->SetEditInReadonlyFlag(bVal); } } - // <-- break; case WID_SECT_PASSWORD: { @@ -906,7 +896,6 @@ throw (beans::UnknownPropertyException, beans::PropertyVetoException, } else if (RES_LR_SPACE == pEntry->nWID) { - // #109700# if (!m_pProps->m_pLRSpaceItem.get()) { m_pProps->m_pLRSpaceItem.reset( @@ -1031,7 +1020,7 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException, case WID_SECT_DDE_AUTOUPDATE: { // GetUpdateType() returns .._ALWAYS or .._ONCALL - if (pSect && pSect->IsLinkType() && pSect->IsConnected()) // lijian i73247 + if (pSect && pSect->IsLinkType() && pSect->IsConnected()) // #i73247# { const sal_Bool bTemp = (pSect->GetUpdateType() == sfx2::LINKUPDATE_ALWAYS); @@ -1098,7 +1087,6 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException, pRet[nProperty] <<= bTemp; } break; - // --> FME 2004-06-22 #114856# edit in readonly sections case WID_SECT_EDIT_IN_READONLY: { const sal_Bool bTemp = (m_bIsDescriptor) @@ -1106,7 +1094,6 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException, pRet[nProperty] <<= bTemp; } break; - // <-- case FN_PARAM_LINK_DISPLAY_NAME: { if (pFmt) @@ -1155,7 +1142,7 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException, case FN_UNO_REDLINE_NODE_END: { if (!pFmt) - break; // lijian i73247 + break; // #i73247# SwNode* pSectNode = pFmt->GetSectionNode(); if (FN_UNO_REDLINE_NODE_END == pEntry->nWID) { @@ -1261,7 +1248,6 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException, } pQueryItem = m_pProps->m_pFrameDirItem.get(); } - /* -> #109700# */ else if (RES_LR_SPACE == pEntry->nWID) { if (!m_pProps->m_pLRSpaceItem.get()) @@ -1271,7 +1257,6 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException, } pQueryItem = m_pProps->m_pLRSpaceItem.get(); } - /* <- #109700# */ if (pQueryItem) { pQueryItem->QueryValue(pRet[nProperty], @@ -1444,9 +1429,7 @@ throw (beans::UnknownPropertyException, uno::RuntimeException) case WID_SECT_REGION : case WID_SECT_VISIBLE: case WID_SECT_PROTECTED: - // --> FME 2004-06-22 #114856# edit in readonly sections case WID_SECT_EDIT_IN_READONLY: - // <-- case FN_PARAM_LINK_DISPLAY_NAME: case FN_UNO_ANCHOR_TYPES: case FN_UNO_TEXT_WRAP: @@ -1590,7 +1573,6 @@ throw (beans::UnknownPropertyException, uno::RuntimeException) } } break; - // --> FME 2004-06-22 #114856# edit in readonly sections case WID_SECT_EDIT_IN_READONLY: { if (m_pImpl->m_bIsDescriptor) @@ -1678,9 +1660,7 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException, } break; case WID_SECT_PROTECTED: - // --> FME 2004-06-22 #114856# edit in readonly sections case WID_SECT_EDIT_IN_READONLY: - // <-- { sal_Bool bTemp = sal_False; aRet.setValue( &bTemp, ::getCppuBooleanType()); diff --git a/sw/source/core/unocore/unosett.cxx b/sw/source/core/unocore/unosett.cxx index 4f6da58b6f9f..e177d14c6029 100644 --- a/sw/source/core/unocore/unosett.cxx +++ b/sw/source/core/unocore/unosett.cxx @@ -181,7 +181,6 @@ const SfxItemPropertySet* GetNumberingRulesSet() #define WID_DISTANCE 4 #define WID_INTERVAL 5 #define WID_SEPARATOR_TEXT 6 -//#define WID_CHARACTER_STYLE 7 #define WID_COUNT_EMPTY_LINES 8 #define WID_COUNT_LINES_IN_FRAMES 9 #define WID_RESTART_AT_EACH_PAGE 10 @@ -1251,12 +1250,8 @@ void SwXNumberingRules::replaceByIndex(sal_Int32 nIndex, const uno::Any& rElemen rProperties, nIndex); else if(pDocShell) { - // --> OD 2008-04-21 #i87650# - correction of cws swwarnings: - // Do not set member <pNumRule> -// pNumRule = pDocShell->GetDoc()->GetOutlineNumRule(); -// SwNumRule aNumRule(*pNumRule); + // #i87650# - correction of cws swwarnings: SwNumRule aNumRule( *(pDocShell->GetDoc()->GetOutlineNumRule()) ); - // <-- SwXNumberingRules::SetNumberingRuleByIndex( aNumRule, rProperties, nIndex); //hier noch die Zeichenformate bei Bedarf setzen @@ -1543,11 +1538,8 @@ uno::Sequence<beans::PropertyValue> SwXNumberingRules::GetNumberingRuleByIndex( aPropertyValues.Insert(pData, aPropertyValues.Count()); } Size aSize = rFmt.GetGraphicSize(); - // --> OD 2010-05-04 #i101131# - applying patch from CMC + // #i101131# // adjust conversion due to type mismatch between <Size> and <awt::Size> -// aSize.Width() = TWIP_TO_MM100( aSize.Width() ); -// aSize.Height() = TWIP_TO_MM100( aSize.Height() ); -// pData = new PropValData((void*)&aSize, SW_PROP_NAME_STR(UNO_NAME_GRAPHIC_SIZE), ::getCppuType((const awt::Size*)0)); awt::Size aAwtSize(TWIP_TO_MM100(aSize.Width()), TWIP_TO_MM100(aSize.Height())); pData = new PropValData((void*)&aAwtSize, SW_PROP_NAME_STR(UNO_NAME_GRAPHIC_SIZE), ::getCppuType((const awt::Size*)0)); // <-- @@ -1786,10 +1778,9 @@ void SwXNumberingRules::SetNumberingRuleByIndex( } } aFmt.SetCharFmt( pCharFmt ); - // os 2005-08-22 #i51842# + // #i51842# // If the character format has been found it's name should not be in the // char style names array - //sNewCharStyleNames[(sal_uInt16)nIndex] = sCharFmtName; sNewCharStyleNames[(sal_uInt16)nIndex].Erase(); } else @@ -1925,7 +1916,7 @@ void SwXNumberingRules::SetNumberingRuleByIndex( awt::FontDescriptor* pDesc = (awt::FontDescriptor*)pData->aVal.getValue(); if(pDesc) { - // --> OD 2008-09-11 #i93725# + // #i93725# // do not accept "empty" font if ( pDesc->Name.getLength() > 0 ) { @@ -2054,12 +2045,7 @@ void SwXNumberingRules::SetNumberingRuleByIndex( SwTxtFmtColl &rTxtColl = *((*pColls)[k]); if(rTxtColl.IsDefault()) continue; - //if(rTxtColl.GetOutlineLevel() == nIndex && //#outline level,removed by zhaojianwei - // rTxtColl.GetName() != sStyleName) - // rTxtColl..SetOutlineLevel(NO_NUMBERING); - //else if(rTxtColl.GetName() == sStyleName) - // rTxtColl.SetOutlineLevel(sal_Int8(nIndex)); - if ( rTxtColl.IsAssignedToListLevelOfOutlineStyle() && //add by zhaojianwei + if ( rTxtColl.IsAssignedToListLevelOfOutlineStyle() && rTxtColl.GetAssignedOutlineStyleLevel() == nIndex && rTxtColl.GetName() != sStyleName ) { @@ -2068,7 +2054,7 @@ void SwXNumberingRules::SetNumberingRuleByIndex( else if ( rTxtColl.GetName() == sStyleName ) { rTxtColl.AssignToListLevelOfOutlineStyle( nIndex ); - } //<-end,,zhaojianwei, + } } } break; @@ -2277,7 +2263,7 @@ OUString SwXNumberingRules::getName() throw( RuntimeException ) SwStyleNameMapper::FillProgName(pNumRule->GetName(), aString, nsSwGetPoolIdFromName::GET_POOLID_NUMRULE, sal_True ); return OUString ( aString ); } - // --> OD 2005-10-25 #126347# - consider chapter numbering <SwXNumberingRules> + // consider chapter numbering <SwXNumberingRules> else if ( pDocShell ) { SwStyleNameMapper::FillProgName( pDocShell->GetDoc()->GetOutlineNumRule()->GetName(), |