Commit Graph

143 Commits

Author SHA1 Message Date
Alexandre Julliard 0f47bb66a6 ole32: Build with msvcrt.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-17 09:41:13 +02:00
Michael Stefaniuc 59fc5cfc3e ole32: Remove useless casts to self.
Signed-off-by: Michael Stefaniuc <mstefani@winehq.org>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-03-01 09:37:58 +01:00
Michael Stefaniuc d93954bd93 ole32: Use the ARRAY_SIZE() macro.
Signed-off-by: Michael Stefaniuc <mstefani@winehq.org>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-07-17 22:35:50 +02:00
Sergio Gómez Del Real 33fd878728 ole32: Reset CLSID of datacache so that automatic entry is re-created on load.
Signed-off-by: Sergio Gómez Del Real <sdelreal@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-04-12 13:21:00 +02:00
Sergio Gómez Del Real 0792209187 ole32: Add support for loading wmf from contents streams to data cache.
Signed-off-by: Sergio Gómez Del Real <sdelreal@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-04-12 13:20:58 +02:00
Sergio Gómez Del Real a1a99f014c ole32: Add support for loading dibs from presentation streams to data cache.
Signed-off-by: Sergio Gómez Del Real <sdelreal@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-04-12 13:20:56 +02:00
Sergio Gómez Del Real 3350cf2320 ole32: Add support for loading enhmetafiles from presentation and contents streams to data cache.
Signed-off-by: Sergio Gómez Del Real <sdelreal@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-04-12 13:20:54 +02:00
Huw Davies c140cf115b ole32: Allow caching of icon aspects for static class caches.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-01-25 12:26:23 +01:00
Huw Davies d5be8f57a1 ole32: There's no need to recreate the static entry when parsing the CONTENTS stream.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-01-24 16:02:19 +01:00
Huw Davies 57a5ab21f9 ole32: Don't keep the streams open.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-01-24 16:02:16 +01:00
Sergio Gómez Del Real 3bf32809b0 ole32: Prevent adding additional cache entries to static class caches.
Signed-off-by: Sergio Gómez Del Real <sdelreal@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-01-23 11:33:38 +01:00
Huw Davies c4a595e316 ole32: Explicitly enumerate the presentation streams rather than using EnumElements.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-01-23 11:33:36 +01:00
Huw Davies ce66c8d147 ole32: Only load the contents stream for the static clsids.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-01-23 11:33:34 +01:00
Huw Davies 47967b7c08 ole32: Implement saving of view cache entries.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-01-22 10:27:15 +01:00
Francois Gouget 5fd5618e3d ole32: Rename entry_updatable() to its more common spelling.
Signed-off-by: Francois Gouget <fgouget@free.fr>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-01-05 16:12:13 +01:00
Huw Davies 33be9fc78f ole32: Correctly save the remaining formats if their data has not been set.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-14 17:23:45 +01:00
Sergio Gómez Del Real 179daf67a8 ole32: Correctly save the dib format if its data has not been set.
Signed-off-by: Sergio Gómez Del Real <sdelreal@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-14 17:23:37 +01:00
Huw Davies 2a4bbb8864 ole32: Don't clear the dirty flag when saving to another storage.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-08 16:45:57 +01:00
Huw Davies a343607909 ole32: Remove unused variable.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-08 16:45:57 +01:00
Sergio Gómez Del Real edc2b347f2 ole32: Add support for saving enhmetafiles to CONTENTS and Presentation streams.
Signed-off-by: Sergio Gómez Del Real <sdelreal@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-08 16:45:56 +01:00
Sergio Gómez Del Real 8dd207a219 ole32: Add support for saving metafiles to CONTENTS streams.
Signed-off-by: Sergio Gómez Del Real <sdelreal@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-08 16:45:56 +01:00
Sergio Gómez Del Real 65b3d01fae ole32: Add support for saving DIBs to CONTENTS streams.
Signed-off-by: Sergio Gómez Del Real <sdelreal@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-08 16:45:56 +01:00
Sergio Gómez Del Real 07af05fa80 ole32: Refactor OLE's data cache Save implementation.
Signed-off-by: Sergio Gómez Del Real <sdelreal@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-08 16:45:56 +01:00
Huw Davies 251e6edae5 ole32: Make the synthesize helpers return a STGMEDIUM.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-29 20:15:31 +01:00
Sergio Gómez Del Real 51c8fa6574 ole32: Add DIB saving in data cache, and relevant tests.
Signed-off-by: Sergio Gómez Del Real <sdelreal@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-28 20:39:29 +01:00
Huw Davies 32766b5253 ole32: Rename structure member to target device size.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-22 10:25:51 +01:00
Marcus Meissner d382b8e91a ole32: Clipboard format in the datacache is with trailing \0.
GetClipboardFormatName returns length without terminating 0,
but we need to store it with \0.

Signed-off-by: Marcus Meissner <marcus@jet.franken.de>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-06 19:36:41 +01:00
Huw Davies 525a7ab1df ole32: Implement IOleCache_InitCache().
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-10-31 17:00:49 +01:00
Huw Davies ca2607db32 ole32: Implement IOleCache2_UpdateCache().
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-10-31 17:00:49 +01:00
Huw Davies 9cf2bd9d91 ole32: There's no need to store a separate clip format for the data.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-10-31 17:00:49 +01:00
Huw Davies c3fe4b87d6 ole32: TYMED_NULL is not valid.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-10-31 17:00:49 +01:00
Huw Davies 12718fe021 ole32: A presentation cache for DVASPECT_ICON must have format CF_METAFILEPICT.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-10-31 17:00:49 +01:00
Huw Davies 8d0a53e60d ole32: Adding a view cache for DVASPECT_ICON produces a CF_METAFILEPICT cache entry.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-10-31 17:00:49 +01:00
Dmitry Timoshkov f7eabdf3a8 ole32: Remove an optimization from DataCache_Save() that copies whole original storage.
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-10-20 18:59:35 +02:00
Huw Davies 87ccecbfa2 ole32: In the non-aggregated case a request for IUnknown actually returns IOleCache2.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-10-05 19:33:09 +02:00
Dmitry Timoshkov 7ce77b464c ole32: Add a trace to IDataObject::GetData.
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-09-20 16:22:29 +02:00
Huw Davies 33a720b7d7 ole32: InitNew() should fail if there is a current storage.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-06 13:47:14 +02:00
Huw Davies 966e8a2c24 ole32: Create initial cache entries for the CLSID_Picture_ classes.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-06 13:47:14 +02:00
Huw Davies 111b72fc85 ole32: Add the ability to create an entry without returning it.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-06 13:47:14 +02:00
Huw Davies 705ccd7488 ole32: Start allocating regular cache entries with id of 2.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-06 13:47:13 +02:00
Huw Davies 026756482a ole32: Fix incorrectly assigned member in the presentation stream.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-06 13:47:13 +02:00
Francois Gouget 85a130958c ole32: Make bitmap_info_size() static.
Signed-off-by: Francois Gouget <fgouget@free.fr>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-06-06 13:08:46 +02:00
Huw Davies 2e363267eb ole32: Synthesize dibs or bitmaps as appropriate.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-23 16:29:46 +02:00
Huw Davies e27708f2fd ole32: Create CF_DIB and CF_BITMAP entries when either is cached.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-23 16:29:33 +02:00
Huw Davies 20a8f1adf4 ole32: Implement IOleCache_EnumCache().
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-23 16:29:12 +02:00
Huw Davies f9b0f60ae3 ole32: Check the cache entry's stgmedium for the unloaded state.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-23 16:29:09 +02:00
Huw Davies 1d2860e54c ole32: Fix up the dib's resolution on loading.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-18 13:37:46 +02:00
Huw Davies e7bb4ba269 ole32: Don't cache the BITMAPFILEHEADER.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-18 13:37:38 +02:00
Huw Davies fc49d98f6a ole32: Set the advise flags in CreateEntry().
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-18 13:37:22 +02:00
Huw Davies 9ee30d7915 ole32: Use the helper function to copy the datacache's FORMATETC.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-18 13:37:14 +02:00