diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2018-01-12 20:13:41 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2018-01-12 20:13:41 +0100 |
commit | 0ae2d98d1f6d29c80bd1ee830db4c333e4ee1e1d (patch) | |
tree | d9b77eece17b7b144a4ea50592b639b9f7c87095 /sw/source/uibase/misc/glosdoc.cxx | |
parent | 506856ca50e676520bcc80a8b498355663d0388f (diff) |
More loplugin:cstylecast: sw
auto-rewrite with <https://gerrit.libreoffice.org/#/c/47798/> "Enable
loplugin:cstylecast for some more cases" plus
solenv/clang-format/reformat-formatted-files
Change-Id: I0f49d21dfdf82742f11b27709f74294feb1e419e
Diffstat (limited to 'sw/source/uibase/misc/glosdoc.cxx')
-rw-r--r-- | sw/source/uibase/misc/glosdoc.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/sw/source/uibase/misc/glosdoc.cxx b/sw/source/uibase/misc/glosdoc.cxx index 424d54290981..ae1b4396b1ec 100644 --- a/sw/source/uibase/misc/glosdoc.cxx +++ b/sw/source/uibase/misc/glosdoc.cxx @@ -120,7 +120,7 @@ bool SwGlossaries::FindGroupName(OUString& rGroup) for(size_t i = 0; i < nCount; ++i) { const OUString sTemp( GetGroupName( i )); - sal_uInt16 nPath = (sal_uInt16)sTemp.getToken(1, GLOS_DELIM).toInt32(); + sal_uInt16 nPath = static_cast<sal_uInt16>(sTemp.getToken(1, GLOS_DELIM).toInt32()); if (!SWUnoHelper::UCB_IsCaseSensitiveFileName( m_PathArr[nPath] ) && rSCmp.isEqual( rGroup, sTemp.getToken( 0, GLOS_DELIM) ) ) @@ -180,7 +180,7 @@ SwTextBlocks* SwGlossaries::GetGroupDoc(const OUString &rName, bool SwGlossaries::NewGroupDoc(OUString& rGroupName, const OUString& rTitle) { const OUString sNewPath(rGroupName.getToken(1, GLOS_DELIM)); - sal_uInt16 nNewPath = (sal_uInt16)sNewPath.toInt32(); + sal_uInt16 nNewPath = static_cast<sal_uInt16>(sNewPath.toInt32()); if (static_cast<size_t>(nNewPath) >= m_PathArr.size()) return false; const OUString sNewFilePath(m_PathArr[nNewPath]); @@ -201,7 +201,7 @@ bool SwGlossaries::NewGroupDoc(OUString& rGroupName, const OUString& rTitle) bool SwGlossaries::RenameGroupDoc( const OUString& rOldGroup, OUString& rNewGroup, const OUString& rNewTitle ) { - sal_uInt16 nOldPath = (sal_uInt16)rOldGroup.getToken(1, GLOS_DELIM).toInt32(); + sal_uInt16 nOldPath = static_cast<sal_uInt16>(rOldGroup.getToken(1, GLOS_DELIM).toInt32()); if (static_cast<size_t>(nOldPath) >= m_PathArr.size()) return false; @@ -214,7 +214,7 @@ bool SwGlossaries::RenameGroupDoc( return false; } - sal_uInt16 nNewPath = (sal_uInt16)rNewGroup.getToken(1, GLOS_DELIM).toInt32(); + sal_uInt16 nNewPath = static_cast<sal_uInt16>(rNewGroup.getToken(1, GLOS_DELIM).toInt32()); if (static_cast<size_t>(nNewPath) >= m_PathArr.size()) return false; @@ -252,7 +252,7 @@ bool SwGlossaries::RenameGroupDoc( // Deletes a text block group bool SwGlossaries::DelGroupDoc(const OUString &rName) { - sal_uInt16 nPath = (sal_uInt16)rName.getToken(1, GLOS_DELIM).toInt32(); + sal_uInt16 nPath = static_cast<sal_uInt16>(rName.getToken(1, GLOS_DELIM).toInt32()); if (static_cast<size_t>(nPath) >= m_PathArr.size()) return false; const OUString sBaseName(rName.getToken(0, GLOS_DELIM)); @@ -275,7 +275,7 @@ SwGlossaries::~SwGlossaries() // read a block document SwTextBlocks* SwGlossaries::GetGlosDoc( const OUString &rName, bool bCreate ) const { - sal_uInt16 nPath = (sal_uInt16)rName.getToken(1, GLOS_DELIM).toInt32(); + sal_uInt16 nPath = static_cast<sal_uInt16>(rName.getToken(1, GLOS_DELIM).toInt32()); SwTextBlocks *pTmp = nullptr; if (static_cast<size_t>(nPath) < m_PathArr.size()) { |