[Libreoffice-commits] core.git: sw/source

Noel Grandin noel at peralex.com
Tue Oct 15 03:56:04 PDT 2013


 sw/source/ui/index/cnttab.cxx    |    4 ++--
 sw/source/ui/shells/annotsh.cxx  |    2 +-
 sw/source/ui/shells/drwtxtex.cxx |    2 +-
 sw/source/ui/shells/textsh.cxx   |    2 +-
 4 files changed, 5 insertions(+), 5 deletions(-)

New commits:
commit 1014cc94e86cafac31192da384bc41790130debb
Author: Noel Grandin <noel at peralex.com>
Date:   Tue Oct 15 12:54:25 2013 +0200

    more fixes for OUString conversion in Windows build
    
    More std::min pickiness, and some ternary operator pickiness.
    
    Change-Id: Ic7feed165c6bb35e08a5e44031d06a1fcb298983

diff --git a/sw/source/ui/index/cnttab.cxx b/sw/source/ui/index/cnttab.cxx
index feda8ab..4f16407 100644
--- a/sw/source/ui/index/cnttab.cxx
+++ b/sw/source/ui/index/cnttab.cxx
@@ -3947,9 +3947,9 @@ void SwEntryBrowseBox::WriteEntries(SvStream& rOutStr)
         sWrite += ";";
         sWrite += pEntry->sSecKey;
         sWrite += ";";
-        sWrite += pEntry->bCase ? "1" : "0";
+        sWrite += pEntry->bCase ? OUString("1") : OUString("0");
         sWrite += ";";
-        sWrite += pEntry->bWord ? "1" : "0";
+        sWrite += pEntry->bWord ? OUString("1") : OUString("0");
 
         if( sWrite.getLength() > 5 )
             rOutStr.WriteByteStringLine( sWrite, eTEnc );
diff --git a/sw/source/ui/shells/annotsh.cxx b/sw/source/ui/shells/annotsh.cxx
index 0eca661..d01c594 100644
--- a/sw/source/ui/shells/annotsh.cxx
+++ b/sw/source/ui/shells/annotsh.cxx
@@ -1050,7 +1050,7 @@ void SwAnnotationShell::StateInsert(SfxItemSet &rSet)
                     else
                     {
                         OUString sSel(pOLV->GetSelected());
-                        sSel = sSel.copy(0, std::min(static_cast<sal_Int32>(255), sSel.getLength()));
+                        sSel = sSel.copy(0, std::min<sal_Int32>(255, sSel.getLength()));
                         aHLinkItem.SetName(comphelper::string::stripEnd(sSel, ' '));
                     }
 
diff --git a/sw/source/ui/shells/drwtxtex.cxx b/sw/source/ui/shells/drwtxtex.cxx
index 4c5e9e7..eb8ed5e 100644
--- a/sw/source/ui/shells/drwtxtex.cxx
+++ b/sw/source/ui/shells/drwtxtex.cxx
@@ -1013,7 +1013,7 @@ void SwDrawTextShell::StateInsert(SfxItemSet &rSet)
                     else
                     {
                         OUString sSel(pOLV->GetSelected());
-                        sSel = sSel.copy(0, std::min(static_cast<sal_Int32>(255), sSel.getLength()));
+                        sSel = sSel.copy(0, std::min<sal_Int32>(255, sSel.getLength()));
                         aHLinkItem.SetName(comphelper::string::stripEnd(sSel, ' '));
                     }
 
diff --git a/sw/source/ui/shells/textsh.cxx b/sw/source/ui/shells/textsh.cxx
index 266c03b..49f248e 100644
--- a/sw/source/ui/shells/textsh.cxx
+++ b/sw/source/ui/shells/textsh.cxx
@@ -766,7 +766,7 @@ void SwTextShell::StateInsert( SfxItemSet &rSet )
                     else
                     {
                         OUString sReturn = rSh.GetSelTxt();
-                        sReturn = sReturn.copy(0, std::min(255, sReturn.getLength()));
+                        sReturn = sReturn.copy(0, std::min<sal_Int32>(255, sReturn.getLength()));
                         aHLinkItem.SetName(comphelper::string::stripEnd(sReturn, ' '));
                     }
 


More information about the Libreoffice-commits mailing list