/
githubmirror
/
PowerToys
Обзор
Документация
Войти
/
githubmirror
/
PowerToys
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
src/common/interop/TwoWayPipeMessageIPCManaged.h
28 строк
978 B
Jaime Bernardo
[Refactor]Port C++/CX to C++/WinRT (#34198)
08 авг 2024, 17:26
Не верифицирован
08 авг 2024, 17:26
fb5ed13
Код
Авторство
О чём код?
#pragma once #include "TwoWayPipeMessageIPCManaged.g.h" #include "two_way_pipe_message_ipc.h" namespace winrt::PowerToys::Interop::implementation { struct TwoWayPipeMessageIPCManaged : TwoWayPipeMessageIPCManagedT<TwoWayPipeMessageIPCManaged> { TwoWayPipeMessageIPCManaged() = default; TwoWayPipeMessageIPCManaged(hstring const& inputPipeName, hstring const& outputPipeName, winrt::PowerToys::Interop::TwoWayPipeIPCReadCallback const& _callback); void Send(hstring const& msg); void Start(); void End(); void Close(); private: TwoWayPipeMessageIPC* _pipe; TwoWayPipeIPCReadCallback _callback; std::function<void(const std::wstring& msg)> _internalReadCallback; }; } namespace winrt::PowerToys::Interop::factory_implementation { struct TwoWayPipeMessageIPCManaged : TwoWayPipeMessageIPCManagedT<TwoWayPipeMessageIPCManaged, implementation::TwoWayPipeMessageIPCManaged> { }; }