summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--desktop/source/lib/lokclipboard.cxx2
-rw-r--r--sfx2/source/view/classificationcontroller.cxx2
-rw-r--r--starmath/source/rtfexport.cxx8
-rw-r--r--starmath/source/unofilter.cxx4
-rw-r--r--starmath/source/wordexportbase.cxx2
-rw-r--r--svl/source/items/grabbagitem.cxx2
-rw-r--r--sw/source/core/doc/rdfhelper.cxx2
-rw-r--r--sw/source/core/doc/textboxhelper.cxx12
-rw-r--r--sw/source/filter/ww8/docxsdrexport.cxx4
9 files changed, 19 insertions, 19 deletions
diff --git a/desktop/source/lib/lokclipboard.cxx b/desktop/source/lib/lokclipboard.cxx
index fa74fa0513b4..deab34f47445 100644
--- a/desktop/source/lib/lokclipboard.cxx
+++ b/desktop/source/lib/lokclipboard.cxx
@@ -42,7 +42,7 @@ throw(datatransfer::UnsupportedFlavorException, io::IOException, uno::RuntimeExc
uno::Any aRet;
if (rFlavor.DataType == cppu::UnoType<OUString>::get())
{
- sal_Char* pText = reinterpret_cast<sal_Char*>(m_aSequence.getArray());
+ auto pText = reinterpret_cast<sal_Char*>(m_aSequence.getArray());
aRet <<= OUString(pText, m_aSequence.getLength(), RTL_TEXTENCODING_UTF8);
}
else
diff --git a/sfx2/source/view/classificationcontroller.cxx b/sfx2/source/view/classificationcontroller.cxx
index 1b069cc736a2..fd19278994c4 100644
--- a/sfx2/source/view/classificationcontroller.cxx
+++ b/sfx2/source/view/classificationcontroller.cxx
@@ -154,7 +154,7 @@ void ClassificationCategoriesController::dispose() throw (uno::RuntimeException,
uno::Reference<awt::XWindow> ClassificationCategoriesController::createItemWindow(const uno::Reference<awt::XWindow>& rParent) throw (uno::RuntimeException, std::exception)
{
VclPtr<vcl::Window> pParent = VCLUnoHelper::GetWindow(rParent);
- ToolBox* pToolbar = dynamic_cast<ToolBox*>(pParent.get());
+ auto pToolbar = dynamic_cast<ToolBox*>(pParent.get());
if (pToolbar)
{
m_pClassification = VclPtr<ClassificationControl>::Create(pToolbar);
diff --git a/starmath/source/rtfexport.cxx b/starmath/source/rtfexport.cxx
index b0e947d15b81..9acd9d494a1d 100644
--- a/starmath/source/rtfexport.cxx
+++ b/starmath/source/rtfexport.cxx
@@ -54,7 +54,7 @@ void SmRtfExport::HandleText(const SmNode* pNode, int /*nLevel*/)
if (pNode->GetToken().eType == TTEXT) // literal text
m_pBuffer->append(LO_STRING_SVTOOLS_RTF_MNOR " ");
- const SmTextNode* pTemp = static_cast<const SmTextNode*>(pNode);
+ auto pTemp = static_cast<const SmTextNode*>(pNode);
SAL_INFO("starmath.rtf", "Text: " << pTemp->GetText());
for (sal_Int32 i = 0; i < pTemp->GetText().getLength(); i++)
{
@@ -180,7 +180,7 @@ namespace
OString mathSymbolToString(const SmNode* node, rtl_TextEncoding nEncoding)
{
assert(node->GetType() == NMATH || node->GetType() == NMATHIDENT);
- const SmTextNode* txtnode = static_cast<const SmTextNode*>(node);
+ auto txtnode = static_cast<const SmTextNode*>(node);
if (txtnode->GetText().isEmpty())
return OString();
assert(txtnode->GetText().getLength() == 1);
@@ -405,7 +405,7 @@ void SmRtfExport::HandleBrace(const SmBraceNode* pNode, int nLevel)
std::vector< const SmNode* > subnodes;
if (pNode->Body()->GetType() == NBRACEBODY)
{
- const SmBracebodyNode* body = static_cast<const SmBracebodyNode*>(pNode->Body());
+ auto body = static_cast<const SmBracebodyNode*>(pNode->Body());
bool separatorWritten = false; // assume all separators are the same
for (int i = 0; i < body->GetNumSubNodes(); ++i)
{
@@ -413,7 +413,7 @@ void SmRtfExport::HandleBrace(const SmBraceNode* pNode, int nLevel)
if (subnode->GetType() == NMATH || subnode->GetType() == NMATHIDENT)
{
// do not write, but write what separator it is
- const SmMathSymbolNode* math = static_cast<const SmMathSymbolNode*>(subnode);
+ auto math = static_cast<const SmMathSymbolNode*>(subnode);
if (!separatorWritten)
{
m_pBuffer->append("{" LO_STRING_SVTOOLS_RTF_MSEPCHR " ");
diff --git a/starmath/source/unofilter.cxx b/starmath/source/unofilter.cxx
index 95fc3e8e0968..d24d0b2d3e93 100644
--- a/starmath/source/unofilter.cxx
+++ b/starmath/source/unofilter.cxx
@@ -67,9 +67,9 @@ sal_Bool MathTypeFilter::filter(const uno::Sequence<beans::PropertyValue>& rDesc
// Is this a MathType Storage?
if (aStorage->IsStream("Equation Native"))
{
- if (SmModel* pModel = dynamic_cast<SmModel*>(m_xDstDoc.get()))
+ if (auto pModel = dynamic_cast<SmModel*>(m_xDstDoc.get()))
{
- SmDocShell* pDocShell = static_cast<SmDocShell*>(pModel->GetObjectShell());
+ auto pDocShell = static_cast<SmDocShell*>(pModel->GetObjectShell());
OUString aText = pDocShell->GetText();
MathType aEquation(aText);
bSuccess = aEquation.Parse(aStorage.get());
diff --git a/starmath/source/wordexportbase.cxx b/starmath/source/wordexportbase.cxx
index 61c1d973fbf4..a5136a729220 100644
--- a/starmath/source/wordexportbase.cxx
+++ b/starmath/source/wordexportbase.cxx
@@ -51,7 +51,7 @@ void SmWordExportBase::HandleNode(const SmNode* pNode, int nLevel)
break;
case NSPECIAL:
{
- const SmTextNode* pText= static_cast< const SmTextNode* >(pNode);
+ auto pText= static_cast<const SmTextNode*>(pNode);
//if the token str and the result text are the same then this
//is to be seen as text, else assume it's a mathchar
if (pText->GetText() == pText->GetToken().aText)
diff --git a/svl/source/items/grabbagitem.cxx b/svl/source/items/grabbagitem.cxx
index 082c42207d9f..6d69fcd9f5ac 100644
--- a/svl/source/items/grabbagitem.cxx
+++ b/svl/source/items/grabbagitem.cxx
@@ -28,7 +28,7 @@ SfxGrabBagItem::~SfxGrabBagItem() = default;
bool SfxGrabBagItem::operator==(const SfxPoolItem& rItem) const
{
- const SfxGrabBagItem* pItem = static_cast<const SfxGrabBagItem*>(&rItem);
+ auto pItem = static_cast<const SfxGrabBagItem*>(&rItem);
return m_aMap == pItem->m_aMap;
}
diff --git a/sw/source/core/doc/rdfhelper.cxx b/sw/source/core/doc/rdfhelper.cxx
index 7f9381329ae4..a139dfc0ba57 100644
--- a/sw/source/core/doc/rdfhelper.cxx
+++ b/sw/source/core/doc/rdfhelper.cxx
@@ -28,7 +28,7 @@ std::map<OUString, OUString> SwRDFHelper::getTextNodeStatements(const OUString&
std::map<OUString, OUString> aRet;
// We only read the node, but CreateXParagraph() needs a non-cost one.
- SwTextNode& rTextNode = const_cast<SwTextNode&>(rNode);
+ auto& rTextNode = const_cast<SwTextNode&>(rNode);
uno::Reference<uno::XComponentContext> xComponentContext(comphelper::getProcessComponentContext());
uno::Reference<rdf::XURI> xType = rdf::URI::create(xComponentContext, rType);
diff --git a/sw/source/core/doc/textboxhelper.cxx b/sw/source/core/doc/textboxhelper.cxx
index bfa3d3a1836d..3bf4a6a86013 100644
--- a/sw/source/core/doc/textboxhelper.cxx
+++ b/sw/source/core/doc/textboxhelper.cxx
@@ -59,7 +59,7 @@ void SwTextBoxHelper::create(SwFrameFormat* pShape)
// Link FLY and DRAW formats, so it becomes a text box (needed for syncProperty calls).
uno::Reference<text::XTextFrame> xRealTextFrame(xTextFrame, uno::UNO_QUERY);
- SwXTextFrame* pTextFrame = dynamic_cast<SwXTextFrame*>(xRealTextFrame.get());
+ auto pTextFrame = dynamic_cast<SwXTextFrame*>(xRealTextFrame.get());
assert(nullptr != pTextFrame);
SwFrameFormat* pFormat = pTextFrame->GetFrameFormat();
@@ -151,7 +151,7 @@ bool SwTextBoxHelper::isTextBox(const SwFrameFormat* pShape, sal_uInt16 nType)
bool SwTextBoxHelper::isTextBox(const SdrObject* pObject)
{
- const SwVirtFlyDrawObj* pVirtFlyDrawObj = dynamic_cast<const SwVirtFlyDrawObj*>(pObject);
+ auto pVirtFlyDrawObj = dynamic_cast<const SwVirtFlyDrawObj*>(pObject);
if (!pVirtFlyDrawObj)
return false;
return isTextBox(pVirtFlyDrawObj->GetFormat(), RES_FLYFRMFMT);
@@ -241,7 +241,7 @@ SwFrameFormat* SwTextBoxHelper::getOtherTextBoxFormat(const SwFrameFormat* pForm
SwFrameFormat* SwTextBoxHelper::getOtherTextBoxFormat(uno::Reference<drawing::XShape> const& xShape)
{
- SwXShape* pShape = dynamic_cast<SwXShape*>(xShape.get());
+ auto pShape = dynamic_cast<SwXShape*>(xShape.get());
if (!pShape)
return nullptr;
@@ -286,7 +286,7 @@ Rectangle SwTextBoxHelper::getTextRectangle(SwFrameFormat* pShape, bool bAbsolut
{
Rectangle aRet;
aRet.SetEmpty();
- SdrObjCustomShape* pCustomShape = dynamic_cast<SdrObjCustomShape*>(pShape->FindRealSdrObject());
+ auto pCustomShape = dynamic_cast<SdrObjCustomShape*>(pShape->FindRealSdrObject());
if (pCustomShape)
{
// Need to temporarily release the lock acquired in
@@ -608,7 +608,7 @@ void SwTextBoxHelper::syncFlyFrameAttr(SwFrameFormat& rShape, SfxItemSet& rSet)
{
case RES_VERT_ORIENT:
{
- const SwFormatVertOrient& rOrient = static_cast<const SwFormatVertOrient&>(*aIter.GetCurItem());
+ auto& rOrient = static_cast<const SwFormatVertOrient&>(*aIter.GetCurItem());
SwFormatVertOrient aOrient(rOrient);
Rectangle aRect = getTextRectangle(&rShape, /*bAbsolute=*/false);
@@ -628,7 +628,7 @@ void SwTextBoxHelper::syncFlyFrameAttr(SwFrameFormat& rShape, SfxItemSet& rSet)
break;
case RES_HORI_ORIENT:
{
- const SwFormatHoriOrient& rOrient = static_cast<const SwFormatHoriOrient&>(*aIter.GetCurItem());
+ auto& rOrient = static_cast<const SwFormatHoriOrient&>(*aIter.GetCurItem());
SwFormatHoriOrient aOrient(rOrient);
Rectangle aRect = getTextRectangle(&rShape, /*bAbsolute=*/false);
diff --git a/sw/source/filter/ww8/docxsdrexport.cxx b/sw/source/filter/ww8/docxsdrexport.cxx
index 5af66a1a56d8..b407082e494f 100644
--- a/sw/source/filter/ww8/docxsdrexport.cxx
+++ b/sw/source/filter/ww8/docxsdrexport.cxx
@@ -950,7 +950,7 @@ void DocxSdrExport::writeDMLAndVMLDrawing(const SdrObject* sdrObj, const SwFrame
{
m_pImpl->m_pSerializer->startElementNS(XML_mc, XML_AlternateContent, FSEND);
- const SdrObjGroup* pObjGroup = dynamic_cast<const SdrObjGroup*>(sdrObj);
+ auto pObjGroup = dynamic_cast<const SdrObjGroup*>(sdrObj);
m_pImpl->m_pSerializer->startElementNS(XML_mc, XML_Choice,
XML_Requires, (pObjGroup ? "wpg" : "wps"),
FSEND);
@@ -1769,7 +1769,7 @@ bool DocxSdrExport::Impl::checkFrameBtlr(SwNode* pStartNode, bool bDML)
if (bItemSet)
{
- const SvxCharRotateItem& rCharRotate = static_cast<const SvxCharRotateItem&>(*pItem);
+ auto& rCharRotate = static_cast<const SvxCharRotateItem&>(*pItem);
if (rCharRotate.GetValue() == 900)
{
if (bDML)