mirror of
https://github.com/microsoft/PowerToys.git
synced 2025-12-16 19:57:57 +01:00
runner: autoupdate improvements (#2346)
This commit is contained in:
@@ -33,6 +33,11 @@ namespace
|
||||
constexpr std::wstring_view WIN32_AUMID = L"Microsoft.PowerToysWin32";
|
||||
}
|
||||
|
||||
namespace localized_strings
|
||||
{
|
||||
constexpr std::wstring_view SNOOZE_BUTTON = L"Snooze";
|
||||
}
|
||||
|
||||
static DWORD loop_thread_id()
|
||||
{
|
||||
static const DWORD thread_id = GetCurrentThreadId();
|
||||
@@ -213,7 +218,14 @@ void notifications::show_toast_with_activations(std::wstring message, std::wstri
|
||||
toast_xml += selection_id;
|
||||
toast_xml += LR"(" type="selection" defaultInput=")";
|
||||
toast_xml += std::to_wstring(b.durations[0].minutes);
|
||||
toast_xml += LR"(">)";
|
||||
toast_xml += L'"';
|
||||
if (!b.snooze_title.empty())
|
||||
{
|
||||
toast_xml += LR"( title=")";
|
||||
toast_xml += b.snooze_title;
|
||||
toast_xml += L'"';
|
||||
}
|
||||
toast_xml += L'>';
|
||||
for (const auto& duration : b.durations)
|
||||
{
|
||||
toast_xml += LR"(<selection id=")";
|
||||
@@ -269,7 +281,9 @@ void notifications::show_toast_with_activations(std::wstring message, std::wstri
|
||||
toast_xml += selection_id;
|
||||
toast_xml += '"';
|
||||
}
|
||||
toast_xml += LR"( content="" />)";
|
||||
toast_xml += LR"( content=")";
|
||||
toast_xml += localized_strings::SNOOZE_BUTTON;
|
||||
toast_xml += LR"(" />)";
|
||||
} },
|
||||
actions[i]);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user