mirror of
https://github.com/th-ch/youtube-music.git
synced 2026-01-17 13:12:07 +00:00
Add snoretoast custom compile script
This commit is contained in:
30
vendor/snoretoast-patch/0001-Fix-activation-not-writing-to-pipe.patch
vendored
Normal file
30
vendor/snoretoast-patch/0001-Fix-activation-not-writing-to-pipe.patch
vendored
Normal file
@ -0,0 +1,30 @@
|
||||
From c5faeceaf36f4b9fb27e5269990b716a25ecbe43 Mon Sep 17 00:00:00 2001
|
||||
From: Jake Barnes <me@jakebarn.es>
|
||||
Date: Mon, 3 May 2021 11:58:27 +1000
|
||||
Subject: [PATCH] Fix activation not writing to pipe
|
||||
|
||||
---
|
||||
src/toasteventhandler.cpp | 7 +++++++
|
||||
1 file changed, 7 insertions(+)
|
||||
|
||||
diff --git a/src/toasteventhandler.cpp b/src/toasteventhandler.cpp
|
||||
index d45d92f..e239dde 100644
|
||||
--- a/src/toasteventhandler.cpp
|
||||
+++ b/src/toasteventhandler.cpp
|
||||
@@ -79,6 +79,13 @@ IFACEMETHODIMP ToastEventHandler::Invoke(_In_ IToastNotification * /*sender*/,
|
||||
std::wcout << dataMap.at(L"button") << std::endl;
|
||||
m_userAction = SnoreToastActions::Actions::ButtonClicked;
|
||||
}
|
||||
+ if (!m_toast.pipeName().empty()) {
|
||||
+ if (m_userAction == SnoreToastActions::Actions::ButtonClicked) {
|
||||
+ Utils::writePipe(m_toast.pipeName(), m_toast.formatAction(m_userAction, { { L"button", dataMap.at(L"button") } }));
|
||||
+ } else {
|
||||
+ Utils::writePipe(m_toast.pipeName(), m_toast.formatAction(m_userAction));
|
||||
+ }
|
||||
+ }
|
||||
}
|
||||
SetEvent(m_event);
|
||||
return S_OK;
|
||||
--
|
||||
2.35.1
|
||||
|
||||
Reference in New Issue
Block a user