Add automation name to graph control (#1032)

* fix bugs

* Update src/Calculator/Resources/en-US/Resources.resw

Co-Authored-By: Rudy Huyn <rudyhuyn@gmail.com>

Co-authored-by: Rudy Huyn <rudyhuyn@gmail.com>
This commit is contained in:
Pepe Rivera 2020-03-06 16:25:50 -08:00 committed by GitHub
parent de3a1cdff7
commit 1b1eb4c7e7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 89 additions and 0 deletions

View file

@ -24,6 +24,7 @@ namespace CalculatorApp::Common::Automation
StringReference OpenParenthesisCountChanged(L"OpenParenthesisCountChanged");
StringReference NoParenthesisAdded(L"NoParenthesisAdded");
StringReference GraphModeChanged(L"GraphModeChanged");
StringReference GraphViewChanged(L"GraphViewChanged");
}
}
@ -150,3 +151,12 @@ NarratorAnnouncement ^ CalculatorAnnouncement::GetGraphModeChangedAnnouncement(P
AutomationNotificationKind::ActionCompleted,
AutomationNotificationProcessing::ImportantMostRecent);
}
NarratorAnnouncement ^ CalculatorAnnouncement::GetGraphViewChangedAnnouncement(Platform::String ^ announcement)
{
return ref new NarratorAnnouncement(
announcement,
CalculatorActivityIds::GraphViewChanged,
AutomationNotificationKind::ActionCompleted,
AutomationNotificationProcessing::MostRecent);
}

View file

@ -68,6 +68,7 @@ public
static NarratorAnnouncement ^ GetNoRightParenthesisAddedAnnouncement(Platform::String ^ announcement);
static NarratorAnnouncement ^ GetGraphModeChangedAnnouncement(Platform::String ^ announcement);
static NarratorAnnouncement ^ GetGraphViewChangedAnnouncement(Platform::String ^ announcement);
};
}

View file

@ -81,6 +81,18 @@ namespace CalculatorApp
{
return LocalizationStringUtilInternal::GetLocalizedString(pMessage, param1->Data(), param2->Data(), param3->Data(), param4->Data());
}
static Platform::String
^ GetLocalizedString(
Platform::String ^ pMessage,
Platform::String ^ param1,
Platform::String ^ param2,
Platform::String ^ param3,
Platform::String ^ param4,
Platform::String ^ param5)
{
return LocalizationStringUtilInternal::GetLocalizedString(pMessage, param1->Data(), param2->Data(), param3->Data(), param4->Data(), param5->Data());
}
};
}
}