mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-08 12:18:50 +02:00
23 lines
623 B
C++
23 lines
623 B
C++
#include "pch.h"
|
|
#include "BackgroundHandler.h"
|
|
#include "BackgroundHandler.g.cpp"
|
|
|
|
#include "handler_functions.h"
|
|
|
|
namespace winrt::PowerToysNotifications::implementation
|
|
{
|
|
using Windows::ApplicationModel::Background::IBackgroundTaskInstance;
|
|
using Windows::UI::Notifications::ToastNotificationActionTriggerDetail;
|
|
|
|
void BackgroundHandler::Run(IBackgroundTaskInstance bti)
|
|
{
|
|
const auto details = bti.TriggerDetails().try_as<ToastNotificationActionTriggerDetail>();
|
|
if (!details)
|
|
{
|
|
return;
|
|
}
|
|
|
|
dispatch_to_backround_handler(details.Argument());
|
|
}
|
|
}
|