diff options
Diffstat (limited to 'xmloff/source/text')
-rw-r--r-- | xmloff/source/text/XMLAutoTextEventExport.cxx | 3 | ||||
-rw-r--r-- | xmloff/source/text/XMLTextShapeImportHelper.cxx | 2 | ||||
-rw-r--r-- | xmloff/source/text/txtflde.cxx | 4 | ||||
-rw-r--r-- | xmloff/source/text/txtfldi.cxx | 7 | ||||
-rw-r--r-- | xmloff/source/text/txtimp.cxx | 2 | ||||
-rw-r--r-- | xmloff/source/text/txtparae.cxx | 6 | ||||
-rw-r--r-- | xmloff/source/text/txtparai.cxx | 6 | ||||
-rw-r--r-- | xmloff/source/text/txtvfldi.cxx | 4 |
8 files changed, 15 insertions, 19 deletions
diff --git a/xmloff/source/text/XMLAutoTextEventExport.cxx b/xmloff/source/text/XMLAutoTextEventExport.cxx index ddd42571607f..68735eabde38 100644 --- a/xmloff/source/text/XMLAutoTextEventExport.cxx +++ b/xmloff/source/text/XMLAutoTextEventExport.cxx @@ -78,8 +78,7 @@ void XMLAutoTextEventExport::initialize( rArguments[1] >>= xSupplier; if (xSupplier.is()) { - Reference<XNameAccess> xAccess(xSupplier->getEvents(), UNO_QUERY); - xEvents = xAccess; + xEvents = xSupplier->getEvents(); } else { diff --git a/xmloff/source/text/XMLTextShapeImportHelper.cxx b/xmloff/source/text/XMLTextShapeImportHelper.cxx index f724fb8faf96..cbac12006d95 100644 --- a/xmloff/source/text/XMLTextShapeImportHelper.cxx +++ b/xmloff/source/text/XMLTextShapeImportHelper.cxx @@ -53,7 +53,7 @@ XMLTextShapeImportHelper::XMLTextShapeImportHelper( Reference < XDrawPageSupplier > xDPS( rImp.GetModel(), UNO_QUERY ); if( xDPS.is() ) { - Reference < XShapes > xShapes( xDPS->getDrawPage(), UNO_QUERY ); + Reference < XShapes > xShapes = xDPS->getDrawPage(); pushGroupForSorting( xShapes ); } diff --git a/xmloff/source/text/txtflde.cxx b/xmloff/source/text/txtflde.cxx index 8202d44e995d..dd71ec72d3ba 100644 --- a/xmloff/source/text/txtflde.cxx +++ b/xmloff/source/text/txtflde.cxx @@ -1918,8 +1918,8 @@ void XMLTextFieldExport::ExportFieldDeclarations( if( !xTextFieldsSupp.is() ) return; - Reference<container::XNameAccess> xFieldMasterNameAccess( - xTextFieldsSupp->getTextFieldMasters(), UNO_QUERY); + Reference<container::XNameAccess> xFieldMasterNameAccess = + xTextFieldsSupp->getTextFieldMasters(); // where to get the text field masters from? // a) we get a specific XText: then use pUsedMasters diff --git a/xmloff/source/text/txtfldi.cxx b/xmloff/source/text/txtfldi.cxx index ca2324471958..7bba48a20444 100644 --- a/xmloff/source/text/txtfldi.cxx +++ b/xmloff/source/text/txtfldi.cxx @@ -2881,8 +2881,8 @@ void XMLDdeFieldImportContext::EndElement() Reference<XTextFieldsSupplier> xTextFieldsSupp(GetImport().GetModel(), UNO_QUERY); - Reference<container::XNameAccess> xFieldMasterNameAccess( - xTextFieldsSupp->getTextFieldMasters(), UNO_QUERY); + Reference<container::XNameAccess> xFieldMasterNameAccess = + xTextFieldsSupp->getTextFieldMasters(); if (xFieldMasterNameAccess->hasByName(sMasterName)) { @@ -3427,9 +3427,8 @@ void XMLAnnotationImportContext::EndElement() uno::Reference<text::XTextCursor> xCursor = xText->createTextCursorByRange(GetImportHelper().GetCursorAsRange()); xCursor->gotoRange(xPrevField->getAnchor(), true); - uno::Reference<text::XTextRange> xTextRange(xCursor, uno::UNO_QUERY); - xText->insertTextContent(xTextRange, xPrevField, !xCursor->isCollapsed()); + xText->insertTextContent(xCursor, xPrevField, !xCursor->isCollapsed()); } } else diff --git a/xmloff/source/text/txtimp.cxx b/xmloff/source/text/txtimp.cxx index a100616f6e74..9f57ac3ac08a 100644 --- a/xmloff/source/text/txtimp.cxx +++ b/xmloff/source/text/txtimp.cxx @@ -1100,7 +1100,7 @@ void XMLTextImportHelper::SetCursor( const Reference < XTextCursor > & rCursor ) { m_xImpl->m_xCursor.set(rCursor); m_xImpl->m_xText.set(rCursor->getText()); - m_xImpl->m_xCursorAsRange.set( rCursor, UNO_QUERY ); + m_xImpl->m_xCursorAsRange = rCursor; } void XMLTextImportHelper::ResetCursor() diff --git a/xmloff/source/text/txtparae.cxx b/xmloff/source/text/txtparae.cxx index 3f774ae1a521..1cbc325f604d 100644 --- a/xmloff/source/text/txtparae.cxx +++ b/xmloff/source/text/txtparae.cxx @@ -2272,7 +2272,7 @@ void XMLTextParagraphExport::exportTextRangeEnumeration( if (xFormField.is()) { OUString sName; - Reference< css::container::XNameAccess > xParameters(xFormField->getParameters(), UNO_QUERY); + Reference< css::container::XNameAccess > xParameters = xFormField->getParameters(); if (xParameters.is() && xParameters->hasByName("Name")) { const Any aValue = xParameters->getByName("Name"); @@ -2323,7 +2323,7 @@ void XMLTextParagraphExport::exportTextRangeEnumeration( if (xFormField.is()) { OUString sName; - Reference< css::container::XNameAccess > xParameters(xFormField->getParameters(), UNO_QUERY); + Reference< css::container::XNameAccess > xParameters = xFormField->getParameters(); if (xParameters.is() && xParameters->hasByName("Name")) { const Any aValue = xParameters->getByName("Name"); @@ -2503,7 +2503,7 @@ void XMLTextParagraphExport::exportTextMark( if (nElement == 1) { Reference<XPropertySet> bkmkProps(rPropSet->getPropertyValue(rProperty), UNO_QUERY); - Reference<XPropertySetInfo> bkmkPropInfo(bkmkProps->getPropertySetInfo(), UNO_QUERY); + Reference<XPropertySetInfo> bkmkPropInfo = bkmkProps->getPropertySetInfo(); OUString sHidden("BookmarkHidden"); if (bkmkPropInfo->hasPropertyByName(sHidden)) { diff --git a/xmloff/source/text/txtparai.cxx b/xmloff/source/text/txtparai.cxx index 8676390dabe6..287b26722781 100644 --- a/xmloff/source/text/txtparai.cxx +++ b/xmloff/source/text/txtparai.cxx @@ -2120,8 +2120,7 @@ void XMLParaContext::EndElement() if ( TextContentAnchorType_AT_CHARACTER == eAnchorType ) { // set anchor position for at-character anchored objects - Reference<XTextRange> xRange(xAttrCursor, UNO_QUERY); - xPropSet->setPropertyValue("TextRange", Any(xRange)); + xPropSet->setPropertyValue("TextRange", Any(xAttrCursor)); } } } @@ -2148,8 +2147,7 @@ void XMLParaContext::EndElement() if ( TextContentAnchorType_AT_CHARACTER == eAnchorType ) { // set anchor position for at-character anchored objects - Reference<XTextRange> xRange(xAttrCursor, UNO_QUERY); - xPropSet->setPropertyValue("TextRange", Any(xRange)); + xPropSet->setPropertyValue("TextRange", Any(xAttrCursor)); } } } diff --git a/xmloff/source/text/txtvfldi.cxx b/xmloff/source/text/txtvfldi.cxx index c6d6ba0f6e73..058fe41ab022 100644 --- a/xmloff/source/text/txtvfldi.cxx +++ b/xmloff/source/text/txtvfldi.cxx @@ -826,8 +826,8 @@ bool XMLVariableDeclImportContext::FindFieldMaster( // get text fields supplier and field masters Reference<XTextFieldsSupplier> xTextFieldsSupp(rImport.GetModel(), UNO_QUERY); - Reference<container::XNameAccess> xFieldMasterNameAccess( - xTextFieldsSupp->getTextFieldMasters(), UNO_QUERY); + Reference<container::XNameAccess> xFieldMasterNameAccess = + xTextFieldsSupp->getTextFieldMasters(); OUStringBuffer sBuffer; sBuffer.append(sAPI_fieldmaster_prefix); |