diff options
Diffstat (limited to 'support/hololens/ServoApp/ServoControl/ServoControl.cpp')
-rw-r--r-- | support/hololens/ServoApp/ServoControl/ServoControl.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/support/hololens/ServoApp/ServoControl/ServoControl.cpp b/support/hololens/ServoApp/ServoControl/ServoControl.cpp index 38cc4f284f4..d1d19118a29 100644 --- a/support/hololens/ServoApp/ServoControl/ServoControl.cpp +++ b/support/hololens/ServoApp/ServoControl/ServoControl.cpp @@ -432,6 +432,15 @@ void ServoControl::OnServoIMEStateChanged(bool aShow) { // https://docs.microsoft.com/en-us/windows/win32/winauto/uiauto-implementingtextandtextrange } +void ServoControl::OnServoMediaSessionMetadata(hstring title, hstring artist, + hstring album) { + RunOnUIThread([=] { mOnMediaSessionMetadataEvent(title, artist, album); }); +} + +void ServoControl::OnServoMediaSessionPlaybackStateChange(int state) { + RunOnUIThread([=] { mOnMediaSessionPlaybackStateChangeEvent(*this, state); }); +} + template <typename Callable> void ServoControl::RunOnUIThread(Callable cb) { Dispatcher().RunAsync(CoreDispatcherPriority::High, cb); } |