[Libreoffice-commits] core.git: vcl/ios
Tor Lillqvist (via logerrit)
logerrit at kemper.freedesktop.org
Mon Dec 21 22:48:35 UTC 2020
vcl/ios/DataFlavorMapping.cxx | 5 ++++-
vcl/ios/clipboard.cxx | 1 +
vcl/ios/iOSTransferable.cxx | 13 +++----------
3 files changed, 8 insertions(+), 11 deletions(-)
New commits:
commit 21e96548719b77310da5e2bae91de52cc468960b
Author: Tor Lillqvist <tml at collabora.com>
AuthorDate: Mon Dec 21 15:18:21 2020 +0200
Commit: Tor Lillqvist <tml at collabora.com>
CommitDate: Mon Dec 21 23:47:53 2020 +0100
Improve SAL_INFO output for clipboard operations on iOS
Change-Id: Id9ed115067655c62346f765ddc3ed9bdce05ab9f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108101
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
Reviewed-by: Tor Lillqvist <tml at collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108103
Tested-by: Tor Lillqvist <tml at collabora.com>
diff --git a/vcl/ios/DataFlavorMapping.cxx b/vcl/ios/DataFlavorMapping.cxx
index 88b0e6199818..037939b2c57c 100644
--- a/vcl/ios/DataFlavorMapping.cxx
+++ b/vcl/ios/DataFlavorMapping.cxx
@@ -560,8 +560,11 @@ DataFlavorMapper::typesArrayToFlavorSequence(NSArray* types) const
{
flavors.realloc(flavors.getLength() + 1);
flavors[flavors.getLength() - 1] = oOOFlavor;
+ }
+ else
+ {
SAL_INFO("vcl.ios.clipboard",
- "Mapped " << [sysFormat UTF8String] << " to " << oOOFlavor.MimeType);
+ "Was not able to map " << [sysFormat UTF8String] << " to an internal flavour");
}
}
diff --git a/vcl/ios/clipboard.cxx b/vcl/ios/clipboard.cxx
index b60cda1bef4d..ad0af57e3995 100644
--- a/vcl/ios/clipboard.cxx
+++ b/vcl/ios/clipboard.cxx
@@ -74,6 +74,7 @@ void SAL_CALL iOSClipboard::setContents(
dict[types[i]] = pBoardData;
}
}
+ SAL_INFO("vcl.ios.clipboard", "Setting pasteboard items: " << NSDictionaryKeysToOUString(dict));
[mPasteboard setItems:array options:@{}];
// We don't keep a copy of the clipboard contents around in-process, so fire the lost clipboard
diff --git a/vcl/ios/iOSTransferable.cxx b/vcl/ios/iOSTransferable.cxx
index 9ec27867fb0b..1ae2277014b6 100644
--- a/vcl/ios/iOSTransferable.cxx
+++ b/vcl/ios/iOSTransferable.cxx
@@ -25,6 +25,8 @@
#include <sal/types.h>
#include <osl/diagnose.h>
+#include <quartz/utils.h>
+
#include "iOSTransferable.hxx"
#include "DataFlavorMapping.hxx"
@@ -143,16 +145,7 @@ void iOSTransferable::initClipboardItemList()
throw RuntimeException("Cannot get clipboard data", static_cast<XTransferable*>(this));
}
-#ifdef SAL_LOG_INFO
- NSString* types = @"";
- for (unsigned i = 0; i < [pboardFormats count]; i++)
- {
- if ([types length] > 0)
- types = [types stringByAppendingString:@", "];
- types = [types stringByAppendingString:[pboardFormats objectAtIndex:i]];
- }
- SAL_INFO("vcl.ios.clipboard", "Types on clipboard: " << [types UTF8String]);
-#endif
+ SAL_INFO("vcl.ios.clipboard", "Types on clipboard: " << NSStringArrayToOUString(pboardFormats));
mFlavorList = mDataFlavorMapper->typesArrayToFlavorSequence(pboardFormats);
}
More information about the Libreoffice-commits
mailing list