Skip to content

Change EventArgs to Argument#2182

Merged
hulumane merged 1 commit intofeature/WNP_ToastNotifications_L1from
user/pavanh/fix-argument
Feb 26, 2022
Merged

Change EventArgs to Argument#2182
hulumane merged 1 commit intofeature/WNP_ToastNotifications_L1from
user/pavanh/fix-argument

Conversation

@hulumane
Copy link
Copy Markdown
Member

One more final API change

@hulumane
Copy link
Copy Markdown
Member Author

/azp run

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

@hulumane hulumane enabled auto-merge (squash) February 26, 2022 01:21
@pmpurifoy pmpurifoy added the area-Notifications Toast notification, badges, Live Tiles, push notifications label Feb 26, 2022

AppNotificationActivatedEventArgs(winrt::hstring const& arguments, winrt::Windows::Foundation::Collections::IMap<winrt::hstring, winrt::hstring> const& userInput) : m_arguments(arguments), m_userInput(userInput) {};
winrt::hstring ActivationArgs() { return m_arguments; };
winrt::hstring Argument() { return m_arguments; };
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Why Argument() singular and not Arguments() plural?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Because Arguments imply its a vector. Argument implies a singleton.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

API Review feedback ;)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Also aligns with what we have in Windows SDK today:
[marshaling_behavior(standard)]
[contract(Windows.Foundation.UniversalApiContract, 1)]
runtimeclass ToastNotificationActionTriggerDetail
{
[contract(Windows.Foundation.UniversalApiContract, 1)]
[interface_name("Windows.UI.Notifications.IToastNotificationActionTriggerDetail", 9445135a-38f3-42f6-96aa-7955b0f03da2)]
{
String Argument{ get; };
Windows.Foundation.Collections.ValueSet UserInput{ get; };
}
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

cool, thanks

@hulumane hulumane merged commit 4d009b4 into feature/WNP_ToastNotifications_L1 Feb 26, 2022
@hulumane hulumane deleted the user/pavanh/fix-argument branch February 26, 2022 02:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-Notifications Toast notification, badges, Live Tiles, push notifications needs-triage

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants