-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Use shared DataFormats code #10391
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use shared DataFormats code #10391
Conversation
This uses the shared DataFormats code from System.Private.Windows.Core. Note that locking is handled by the shared code so there is no need to do so when adding the WPF specific types. The only reason they need added is that casing will stick with whatever the first request is. That is, if you ask for "XAML" that will be the string Windows gives back, not "Xaml".
src/Microsoft.DotNet.Wpf/src/PresentationCore/System/Windows/DataFormats.cs
Show resolved
Hide resolved
Where can I see the value of |
@miloush You have to go to def in VS, this is all source generated. It comes indirectly from the Windows headers. In this particular case it isn't in the docs that I can find (very unusual), just the headers. The value is "Ink Serialized Format". |
src/Microsoft.DotNet.Wpf/src/PresentationCore/System/Windows/dataobject.cs
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changes looks good to me. Can you please add the reference to the PR which is handling the new common code for dataformats?
The primary refactoring was dotnet/winforms#12802. The shared code had a number of other edits past that. |
This uses the shared DataFormats code from System.Private.Windows.Core.
Note that locking is handled by the shared code so there is no need to do so when adding the WPF specific types. The only reason they need added is that casing will stick with whatever the first request is. That is, if you ask for "XAML" that will be the string Windows gives back, not "Xaml".
Microsoft Reviewers: Open in CodeFlow