Kaydet (Commit) 2f01d679 authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Improved loplugin:redundantcast, static_cast on arithmetic types: xmloff

Change-Id: I67a7f0643b4773c991e780c9a715636bb3e6e6cb
üst f79c4664
......@@ -1114,9 +1114,9 @@ void SchXMLStatisticsObjectContext::StartElement( const uno::Reference< xml::sax
uno::UNO_QUERY );
xBarProp->setPropertyValue("ErrorBarStyle",uno::makeAny(css::chart::ErrorBarStyle::NONE));
xBarProp->setPropertyValue("PositiveError",uno::makeAny(static_cast<double>(0.0)));
xBarProp->setPropertyValue("NegativeError",uno::makeAny(static_cast<double>(0.0)));
xBarProp->setPropertyValue("Weight",uno::makeAny(static_cast<double>(1.0)));
xBarProp->setPropertyValue("PositiveError",uno::makeAny(0.0));
xBarProp->setPropertyValue("NegativeError",uno::makeAny(0.0));
xBarProp->setPropertyValue("Weight",uno::makeAny(1.0));
xBarProp->setPropertyValue("ShowPositiveError",uno::makeAny(true));
xBarProp->setPropertyValue("ShowNegativeError",uno::makeAny(true));
......
......@@ -369,7 +369,7 @@ Reference< chart2::data::XDataSequence > CreateDataSequence(
bool bVal = false;
uno::Any any = xPropSet->getPropertyValue("UseInternalDataProvider");
if (any >>= bVal)
bUseInternal = static_cast<bool>(bVal);
bUseInternal = bVal;
}
catch (const beans::UnknownPropertyException&)
{
......
......@@ -185,7 +185,7 @@ bool XMLStyleExport::exportStyle(
if( nOutlineLevel > 0 )
{
OUStringBuffer sTmp;
sTmp.append( static_cast<sal_Int32>(nOutlineLevel));
sTmp.append(nOutlineLevel);
GetExport().AddAttribute( XML_NAMESPACE_STYLE,
XML_DEFAULT_OUTLINE_LEVEL,
sTmp.makeStringAndClear() );
......
......@@ -247,8 +247,7 @@ void XMLTextMarkImportContext::EndElement()
{
std::shared_ptr< ::xmloff::ParsedRDFaAttributes >
xRDFaAttributes;
if (m_bHaveAbout && (TypeBookmarkStart
== static_cast<lcl_MarkType>(nTmp)))
if (m_bHaveAbout && TypeBookmarkStart == nTmp)
{
xRDFaAttributes =
GetImport().GetRDFaImportHelper().ParseRDFa(
......
......@@ -1850,9 +1850,8 @@ OUString XMLTextImportHelper::SetStyleAndAttrs(
{
if ( nCurrentOutlineLevelInheritedFromParagraphStyle != 0 )
{
sal_Int16 nZero = 0;
xPropSet->setPropertyValue(s_OutlineLevel,
makeAny( static_cast<sal_Int16>(nZero) ));
makeAny( sal_Int16(0) ));
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment