More trimming friendly DragDrop
See original GitHub issueCurrently DragDrop process starts with DragDropEffects DoDragDrop(object data, DragDropEffects allowedEffects)
which inside perform dispatcherization of the supported interfaces and objects. Sometimes this may means that we rely on Built-in COM support for cast of the interfaces.
Built-in COM support maybe disabled in modern .NET and do not supported in NativeAOT flavor of CoreCLR. I propose provide API which put responsibility of AOT supported casting on the consumer side by introducing typed version of the method.
public class Control
{
+ [BuiltInComDragonsHere]
public DragDropEffects DoDragDrop(object data, DragDropEffects allowedEffects)
+ public DragDropEffects DoDragDrop(System.Runtime.InteropServices.ComTypes.IDataObject data, DragDropEffects allowedEffects)
+ public DragDropEffects DoDragDrop(System.Windows.Forms.IDataObject data, DragDropEffects allowedEffects)
}
public class ToolStripItem
{
+ [BuiltInComDragonsHere]
public DragDropEffects DoDragDrop(object data, DragDropEffects allowedEffects)
+ public DragDropEffects DoDragDrop(System.Runtime.InteropServices.ComTypes.IDataObject data, DragDropEffects allowedEffects)
+ public DragDropEffects DoDragDrop(System.Windows.Forms.IDataObject data, DragDropEffects allowedEffects)
}
This would be considered source breaking change.
/cc @weltkante since you maybe interested in giving feedback on this.
Issue Analytics
- State:
- Created 2 years ago
- Comments:16 (16 by maintainers)
Top Results From Across the Web
How to implement drag and drop in React with React DnD
The most common use cases for drag and drop in React include uploading files, moving items between multiple lists, and rearranging images ...
Read more >Tips for minimizing the email clipping using the drag-drop ...
Open the email in your Gmail inbox. In the top-right of the email, click the 3 vertical dots to open the More menu....
Read more >How can I make a jQuery UI 'draggable()' div ...
After wasting many hours, I came across this! jquery-ui-touch-punch. It translates tap events as click events. Remember to load the script ...
Read more >Drag and Drop one pager PDF from Apple Ma…
When I drag and drop from Apple Mail a one-pager PDF (that is displayed as an image in the email) to the Finder...
Read more >Learn how to trim a video in minutes
In this tutorial video, you'll learn how to trim videos using Animoto's user-friendly video trimmer. Discover step-by-step instructions to precisely cut ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@kant2002 sorry, I’m not clear on how that helps. @AaronRobinsonMSFT are there resources on built-in COM and trimming? All I really know at this point is that we should be moving away from ComImport where possible, but I don’t even really know why. 😃
The team will discuss in one of the upcoming triages.