Skip to content

Support winrt consumption using CsWinRT reference#1243

Merged
ujjwalchadha merged 6 commits intomainfrom
uwp/support-winrt-components
Aug 12, 2022
Merged

Support winrt consumption using CsWinRT reference#1243
ujjwalchadha merged 6 commits intomainfrom
uwp/support-winrt-components

Conversation

@ujjwalchadha
Copy link
Contributor

This PR adds support for CsWinRT consumption in UWP converted projects containing any reference to "vcxproj" projects. We add a CsWinRT reference and CsWinRTIncludes property for each vcxproj reference.

@ujjwalchadha ujjwalchadha requested a review from a team as a code owner August 1, 2022 18:43
@ujjwalchadha ujjwalchadha marked this pull request as draft August 1, 2022 18:44
@ujjwalchadha
Copy link
Contributor Author

Waiting for try-convert PR to get merged.

@ujjwalchadha ujjwalchadha requested a review from manodasanW August 1, 2022 18:46
brandonh-msft
brandonh-msft previously approved these changes Aug 1, 2022
Copy link
Contributor

@brandonh-msft brandonh-msft left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall LGTM just added a few suggestions

@brandonh-msft brandonh-msft requested review from a team and brandonh-msft and removed request for manodasanW August 1, 2022 19:30
@ujjwalchadha ujjwalchadha requested a review from manodasanW August 1, 2022 21:57
@brandonh-msft
Copy link
Contributor

Just merged t-c into main via PR #1248
Fix up the conflicts in this one (the change to subrepo SHA) and make the changes you needed in t-c as part of this PR then let's 🚀

@ujjwalchadha ujjwalchadha marked this pull request as ready for review August 8, 2022 20:27
Copy link
Contributor

@brandonh-msft brandonh-msft left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Just blocking until another UWP SME gives it the 👍🏻👍🏻

manodasanW
manodasanW previously approved these changes Aug 11, 2022
public const string RuleID = "UA302";

private const string CsWinRTLogMessageFormat = "A CsWinRTIncludes property with value {0} has been added.\n" +
"If your project assembly name differs from {0}, update this value with the assembly name.\n" +

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this message printed for the component scenario where the project assembly name comes into play or is it printed for the vcxproj references scenario?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is printed for all the vcxproj scenarios (There seems to be no good way to parse the assembly name as we are unable to load cpp projects). So, whenever we add a CsWinRTIncludes property with the name same as the vcxproj file name, we show this message on the console.

@ujjwalchadha ujjwalchadha merged commit bc7266f into main Aug 12, 2022
@ujjwalchadha ujjwalchadha deleted the uwp/support-winrt-components branch August 12, 2022 17:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants