diff options
author | Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> | 2013-03-22 14:00:19 +0100 |
---|---|---|
committer | Fridrich Strba <fridrich@documentfoundation.org> | 2013-03-22 17:11:29 +0000 |
commit | 683142294f291a77329a2d266124432aeba8522b (patch) | |
tree | 7029c1bf18421a4c1684d45a67190c425381e64c /vcl | |
parent | e8638ad5a7196ea79d90415b86a99a4c9f110a5e (diff) |
get rid of two-argument compareToAscii
As I don't see a point in comparing a mimetype with only a
substring, it probably could be a simple compareToAscii, but
play it save and use startsWith.
Change-Id: Ic33c8089283def615999ddf80cd12f6fe219ed17
Reviewed-on: https://gerrit.libreoffice.org/2907
Reviewed-by: Thomas Arnhold <thomas@arnhold.org>
Reviewed-by: Fridrich Strba <fridrich@documentfoundation.org>
Tested-by: Fridrich Strba <fridrich@documentfoundation.org>
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/aqua/source/dtrans/DataFlavorMapping.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/vcl/aqua/source/dtrans/DataFlavorMapping.cxx b/vcl/aqua/source/dtrans/DataFlavorMapping.cxx index a1a69ffe15f6..6cfc2c97f5c4 100644 --- a/vcl/aqua/source/dtrans/DataFlavorMapping.cxx +++ b/vcl/aqua/source/dtrans/DataFlavorMapping.cxx @@ -526,7 +526,7 @@ NSString* DataFlavorMapper::openOfficeToSystemFlavor(const DataFlavor& oOOFlavor for (size_t i = 0; i < SIZE_FLAVOR_MAP; i++) { - if (oOOFlavor.MimeType.compareToAscii(flavorMap[i].OOoFlavor, strlen(flavorMap[i].OOoFlavor)) == 0) + if (oOOFlavor.MimeType.startsWith(flavorMap[i].OOoFlavor)) { sysFlavor = flavorMap[i].SystemFlavor; } |