Description
Historically putting data on the Clipboard and retrieving it would go through the native OLE IDataObject interface, which would have the side effect of always making all interaction be autoConvert == true
.
The new implementation does not need to go through the serialization that would happen here but does need to follow the behavior above. We initially handled this by forcing some scenarios through the proxy, but that causes serialization. In WinForms this was handled via a derived DataObject
class, which we've just updated to just mimic the behavior from before.
dotnet/winforms#13287
DataObject
is sealed in WPF, so this behavior was done with:
private readonly bool _doNotUnwrap;
This should be changed to _forceAutoConvert
to follow the behavior change that WinForms does.
Then we'll be able to enable customer OLE scenarios that are only in process and don't set copy
to true
without needing to take the BinaryFormatter
compat package.