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

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Sun Feb 17 16:54:49 UTC 2019


 sd/source/ui/view/viewshel.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 1b4b828fddbb8cd9a1314e8e54641740629b206c
Author:     Matteo Casalin <matteo.casalin at yahoo.com>
AuthorDate: Sun Feb 10 16:33:39 2019 +0100
Commit:     Matteo Casalin <matteo.casalin at yahoo.com>
CommitDate: Sun Feb 17 17:54:28 2019 +0100

    Avoid string comparison if result is known
    
    Change-Id: I766c343194f81497f95108d1259b697d3ad363a5
    Reviewed-on: https://gerrit.libreoffice.org/67642
    Tested-by: Jenkins
    Reviewed-by: Matteo Casalin <matteo.casalin at yahoo.com>

diff --git a/sd/source/ui/view/viewshel.cxx b/sd/source/ui/view/viewshel.cxx
index 09af5e774e4a..9163d2142dd2 100644
--- a/sd/source/ui/view/viewshel.cxx
+++ b/sd/source/ui/view/viewshel.cxx
@@ -541,7 +541,7 @@ OString ViewShell::GetTextSelection(const OString& _aMimeType, OString& rUsedMim
 
     datatransfer::DataFlavor aFlavor;
     aFlavor.MimeType = OUString::fromUtf8(aMimeType.getStr());
-    if (aMimeType == "text/plain;charset=utf-16")
+    if (bConvert || aMimeType == "text/plain;charset=utf-16")
         aFlavor.DataType = cppu::UnoType<OUString>::get();
     else
         aFlavor.DataType = cppu::UnoType< uno::Sequence<sal_Int8> >::get();


More information about the Libreoffice-commits mailing list