Commit Graph
4 Commits
Author SHA1 Message Date
Miklos Vajna d5cd62164d embeddedobj: handle getting the visible area on a thread
The Windows OLE2 implementation of the embedded object interface assumes
that the same thread is used for loading and saving the embedded
objects.

This means that in case the main thread is used for loading (e.g. from
remote UNO, but with OnMainThead=true), but a
thread is used for storing (without an explicit OnMainThead=true), then
the underlying win32 API call failed and we returned a fixed size in
EmbeddedObjectRef::GetSize().

Fix the problem by explicitly checking for RPC_E_WRONG_THREAD and adding
error handling for that case.

Change-Id: Icf1e7722d33a809fa671d1505b2a0155af040c71
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115236
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
2021-05-07 14:21:40 +02:00
Miklos Vajna bdfa6b678b embeddedobj: allow controlling if PDF documents are converted to Draw or not
This is a bit custom, since it's not a Microsoft filter.  At the moment
this affects only Insert -> Object -> OLE Object -> from file.

Change-Id: If79602742a533db1b04e11a90890f8768186046d
Reviewed-on: https://gerrit.libreoffice.org/77520
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
2019-08-15 16:45:23 +02:00
Miklos Vajna 5827e30109 embeddedobj: allow controlling if Visio documents are converted to Draw or not
At the moment this affects only Insert -> Object -> OLE Object -> from
file.

Change-Id: I8d1c6456481610491916e3be3766b0bb04dfa296
Reviewed-on: https://gerrit.libreoffice.org/77489
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
2019-08-15 11:42:55 +02:00
Miklos Vajna 85a7bc13fe embeddedobj: add initial CppunitTest_embeddedobj_general
Fails with commit 88afec7011 (embeddedobj:
respect config for Insert -> Object -> OLE Object -> from file,
2019-08-14) reverted.

Change-Id: I64f81642260f6eab5a86219d94553f09b67b3555
Reviewed-on: https://gerrit.libreoffice.org/77461
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
2019-08-14 19:38:59 +02:00