diff options
author | Vladimir Glazounov <vg@openoffice.org> | 2005-03-23 11:42:46 +0000 |
---|---|---|
committer | Vladimir Glazounov <vg@openoffice.org> | 2005-03-23 11:42:46 +0000 |
commit | cf1aa679d25751fc5904f2ff41c211542cc46525 (patch) | |
tree | 13825a1313f929ab89e3567f1d9d827752dab1a3 /xmloff/source/text/txtsecte.cxx | |
parent | 255d38d4dde538b791d3834c129535b50a0381c6 (diff) |
INTEGRATION: CWS calcuno01 (1.13.234); FILE MERGED
2004/02/12 17:43:45 sab 1.13.234.1: #i22706#; better using of API
Diffstat (limited to 'xmloff/source/text/txtsecte.cxx')
-rw-r--r-- | xmloff/source/text/txtsecte.cxx | 36 |
1 files changed, 17 insertions, 19 deletions
diff --git a/xmloff/source/text/txtsecte.cxx b/xmloff/source/text/txtsecte.cxx index 8358523d1c08..23e6f19ccbfd 100644 --- a/xmloff/source/text/txtsecte.cxx +++ b/xmloff/source/text/txtsecte.cxx @@ -2,9 +2,9 @@ * * $RCSfile: txtsecte.cxx,v $ * - * $Revision: 1.13 $ + * $Revision: 1.14 $ * - * last change: $Author: dvo $ $Date: 2001-11-08 19:17:43 $ + * last change: $Author: vg $ $Date: 2005-03-23 12:42:46 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -183,7 +183,7 @@ Reference<XText> lcl_findXText(const Reference<XTextSection>& rSect) Reference<XTextContent> xTextContent(rSect, UNO_QUERY); if (xTextContent.is()) { - xText = xTextContent->getAnchor()->getText(); + xText.set(xTextContent->getAnchor()->getText()); } return xText; @@ -204,8 +204,7 @@ void XMLTextParagraphExport::exportListAndSectionChange( { if (xPropSet->getPropertySetInfo()->hasPropertyByName(sTextSection)) { - Any aAny = xPropSet->getPropertyValue(sTextSection); - aAny >>= xNextSection; + xPropSet->getPropertyValue(sTextSection) >>= xNextSection; } // else: no current section } @@ -233,9 +232,8 @@ void XMLTextParagraphExport::exportListAndSectionChange( rPropSetHelper.hasProperties( xPropSet->getPropertySetInfo() ); if( rPropSetHelper.hasProperty( nTextSectionId )) { - Any aAny = rPropSetHelper.getValue( nTextSectionId , xPropSet, - sal_True ); - aAny >>= xNextSection; + xNextSection.set(rPropSetHelper.getValue( nTextSectionId , xPropSet, + sal_True ), uno::UNO_QUERY); } // else: no current section } @@ -264,7 +262,7 @@ void XMLTextParagraphExport::exportListAndSectionChange( // Build stacks of old and new sections // Sections on top of mute sections should not be on the stack vector<Reference<XTextSection> > aOldStack; - Reference<XTextSection> aCurrent = rPrevSection; + Reference<XTextSection> aCurrent(rPrevSection); while(aCurrent.is()) { // if we have a mute section, ignore all its children @@ -273,11 +271,11 @@ void XMLTextParagraphExport::exportListAndSectionChange( aOldStack.clear(); aOldStack.push_back(aCurrent); - aCurrent = aCurrent->getParentSection(); + aCurrent.set(aCurrent->getParentSection()); } vector<Reference<XTextSection> > aNewStack; - aCurrent = rNextSection; + aCurrent.set(rNextSection); sal_Bool bMute = sal_False; while(aCurrent.is()) { @@ -290,7 +288,7 @@ void XMLTextParagraphExport::exportListAndSectionChange( } aNewStack.push_back(aCurrent); - aCurrent = aCurrent->getParentSection(); + aCurrent.set(aCurrent->getParentSection()); } // compare the two stacks @@ -303,16 +301,16 @@ void XMLTextParagraphExport::exportListAndSectionChange( (aNew != aNewStack.rend()) && (*aOld) == (*aNew) ) { - aOld++; - aNew++; + ++aOld; + ++aNew; } // close all elements of aOld ... // (order: newest to oldest) if (aOld != aOldStack.rend()) { - vector<Reference<XTextSection> > ::iterator aOldForward = - aOldStack.begin(); + vector<Reference<XTextSection> > ::iterator aOldForward( + aOldStack.begin()); while ((aOldForward != aOldStack.end()) && (*aOldForward != *aOld)) { @@ -320,7 +318,7 @@ void XMLTextParagraphExport::exportListAndSectionChange( pRedlineExport->ExportStartOrEndRedline(*aOldForward, sal_False); pSectionExport->ExportSectionEnd(*aOldForward, bAutoStyles); - aOldForward++; + ++aOldForward; } if (aOldForward != aOldStack.end()) { @@ -338,7 +336,7 @@ void XMLTextParagraphExport::exportListAndSectionChange( if ( !bAutoStyles && (NULL != pRedlineExport) ) pRedlineExport->ExportStartOrEndRedline(*aNew, sal_True); pSectionExport->ExportSectionStart(*aNew, bAutoStyles); - aNew++; + ++aNew; } // start new list @@ -353,6 +351,6 @@ void XMLTextParagraphExport::exportListAndSectionChange( } // save old section (old numRule gets saved in calling method) - rPrevSection = rNextSection; + rPrevSection.set(rNextSection); } |