summaryrefslogtreecommitdiffstats
path: root/sw
diff options
context:
space:
mode:
Diffstat (limited to 'sw')
-rw-r--r--sw/qa/core/macros-test.cxx2
-rw-r--r--sw/source/core/crsr/crsrsh.cxx24
-rw-r--r--sw/source/core/layout/dbg_lay.cxx3
-rw-r--r--sw/source/filter/ww8/rtfattributeoutput.cxx4
-rw-r--r--sw/source/ui/dbui/dbinsdlg.cxx2
-rw-r--r--sw/source/ui/dbui/mmaddressblockpage.cxx2
6 files changed, 19 insertions, 18 deletions
diff --git a/sw/qa/core/macros-test.cxx b/sw/qa/core/macros-test.cxx
index 8ac5c15946ea..fa27beca817d 100644
--- a/sw/qa/core/macros-test.cxx
+++ b/sw/qa/core/macros-test.cxx
@@ -183,7 +183,7 @@ void SwMacrosTest::testVba()
SfxObjectShell::CallXScript(xComponent, sUrl, aParams, aRet, aOutParamIndex,aOutParam);
OUString aStringRes;
aRet >>= aStringRes;
- std::cout << "value of Ret " << OUStringToOString( aStringRes, RTL_TEXTENCODING_UTF8 ).getStr() << std::endl;
+ std::cout << "value of Ret " << aStringRes << std::endl;
//CPPUNIT_ASSERT_MESSAGE( "script reported failure",aStringRes == "OK" );
pFoundShell->DoClose();
}
diff --git a/sw/source/core/crsr/crsrsh.cxx b/sw/source/core/crsr/crsrsh.cxx
index d88d76272a56..90a5c310d48a 100644
--- a/sw/source/core/crsr/crsrsh.cxx
+++ b/sw/source/core/crsr/crsrsh.cxx
@@ -1161,19 +1161,21 @@ OUString SwCursorShell::getPageRectangles()
{
CurrShell aCurr(this);
SwRootFrame* pLayout = GetLayout();
- std::vector<OString> v;
+ OUStringBuffer aBuf;
for (const SwFrame* pFrame = pLayout->GetLower(); pFrame; pFrame = pFrame->GetNext())
{
- std::vector<OString> aRectangle
- {
- OString::number(pFrame->Frame().Left()),
- OString::number(pFrame->Frame().Top()),
- OString::number(pFrame->Frame().Width()),
- OString::number(pFrame->Frame().Height())
- };
- v.push_back(comphelper::string::join(", ", aRectangle));
- }
- return OUString::fromUtf8(comphelper::string::join("; ", v).getStr());
+ aBuf.append(pFrame->Frame().Left());
+ aBuf.append(", ");
+ aBuf.append(pFrame->Frame().Top());
+ aBuf.append(", ");
+ aBuf.append(pFrame->Frame().Width());
+ aBuf.append(", ");
+ aBuf.append(pFrame->Frame().Height());
+ aBuf.append("; ");
+ }
+ if (!aBuf.isEmpty())
+ aBuf.setLength( aBuf.getLength() - 2); // remove the last "; "
+ return aBuf.makeStringAndClear();
}
void SwCursorShell::NotifyCursor(SfxViewShell* pOtherShell) const
diff --git a/sw/source/core/layout/dbg_lay.cxx b/sw/source/core/layout/dbg_lay.cxx
index 718048d383ba..16b5776c1d7b 100644
--- a/sw/source/core/layout/dbg_lay.cxx
+++ b/sw/source/core/layout/dbg_lay.cxx
@@ -346,8 +346,7 @@ void SwImplProtocol::CheckLine( OString& rLine )
}
if( !aTok.isEmpty() )
{
- long nVal;
- sscanf( aTok.getStr(), "%li", &nVal );
+ sal_Int64 nVal = aTok.toInt64();
switch ( nInitFile )
{
case 1: InsertFrame( sal_uInt16( nVal ) ); // add FrameId
diff --git a/sw/source/filter/ww8/rtfattributeoutput.cxx b/sw/source/filter/ww8/rtfattributeoutput.cxx
index 891216a84183..82ab2d2509ac 100644
--- a/sw/source/filter/ww8/rtfattributeoutput.cxx
+++ b/sw/source/filter/ww8/rtfattributeoutput.cxx
@@ -2956,7 +2956,7 @@ void RtfAttributeOutput::FormatLRSpace(const SvxLRSpaceItem& rLRSpace)
m_aSectionBreaks.append((sal_Int32)rLRSpace.GetRight());
}
if (!m_bBufferSectionBreaks)
- m_rExport.Strm(). WriteCharPtr(m_aSectionBreaks.makeStringAndClear().getStr());
+ m_rExport.Strm().WriteCharPtr(m_aSectionBreaks.makeStringAndClear().getStr());
}
else
{
@@ -3014,7 +3014,7 @@ void RtfAttributeOutput::FormatULSpace(const SvxULSpaceItem& rULSpace)
m_aSectionBreaks.append((sal_Int32)aDistances.dyaHdrBottom);
}
if (!m_bBufferSectionBreaks)
- m_rExport.Strm(). WriteCharPtr(m_aSectionBreaks.makeStringAndClear().getStr());
+ m_rExport.Strm().WriteCharPtr(m_aSectionBreaks.makeStringAndClear().getStr());
}
else
{
diff --git a/sw/source/ui/dbui/dbinsdlg.cxx b/sw/source/ui/dbui/dbinsdlg.cxx
index 7d40cd07d598..232b62d13d18 100644
--- a/sw/source/ui/dbui/dbinsdlg.cxx
+++ b/sw/source/ui/dbui/dbinsdlg.cxx
@@ -1174,7 +1174,7 @@ void SwInsertDBColAutoPilot::DataToDoc( const Sequence<Any>& rSelection,
}
catch (const Exception& rExcept)
{
- OSL_FAIL(OUStringToOString(rExcept.Message, osl_getThreadTextEncoding()).getStr());
+ SAL_WARN("sw", rExcept.Message);
(void)rExcept;
}
}
diff --git a/sw/source/ui/dbui/mmaddressblockpage.cxx b/sw/source/ui/dbui/mmaddressblockpage.cxx
index 6c9c69e81774..4f80954808a2 100644
--- a/sw/source/ui/dbui/mmaddressblockpage.cxx
+++ b/sw/source/ui/dbui/mmaddressblockpage.cxx
@@ -180,7 +180,7 @@ IMPL_LINK_NOARG(SwMailMergeAddressBlockPage, AddressListHdl_Impl, Button*, void)
}
catch (const uno::Exception& e)
{
- OSL_FAIL(OUStringToOString(e.Message, osl_getThreadTextEncoding()).getStr());
+ SAL_WARN("sw", e.Message);
ScopedVclPtrInstance<MessageDialog>(this, e.Message)->Execute();
}
}