diff options
author | chriszero <zerov83@gmail.com> | 2015-09-27 19:21:00 +0200 |
---|---|---|
committer | chriszero <zerov83@gmail.com> | 2015-09-27 19:23:14 +0200 |
commit | 392422114a66f937feaf96473cbf9e4b3404b309 (patch) | |
tree | 68334c2294a3b0e6b48ec91db485160231ebd110 | |
parent | 502854e94772d1d6e9af4bc25fc80a3284019baf (diff) | |
download | vdr-plugin-plex-392422114a66f937feaf96473cbf9e4b3404b309.tar.gz vdr-plugin-plex-392422114a66f937feaf96473cbf9e4b3404b309.tar.bz2 |
Corrections to MpvService
-rw-r--r-- | plex.cpp | 11 | ||||
-rw-r--r-- | services.h | 16 |
2 files changed, 16 insertions, 11 deletions
@@ -172,12 +172,15 @@ void cMyPlugin::PlayFile(plexclient::Video Vid) cPlugin* mpvPlugin = cPluginManager::GetPlugin("mpv"); if(Config::GetInstance().UseMpv && mpvPlugin) { - Mpv_StartPlayService_v1_0_t req; + Mpv_PlayFile req; + Mpv_SetTitle reqTitle; char* file = (char*)(Vid.m_pServer->GetUri() + Vid.m_Media.m_sPartKey).c_str(); + req.Filename = file; - req.Title = (char*)Vid.GetTitle().c_str(); - //req.Title = &Vid.GetTitle().c_str(); - mpvPlugin->Service(MPV_START_PLAY_SERVICE, &req); + mpvPlugin->Service(MPV_PLAY_FILE, &req); + + reqTitle.Title = (char*)Vid.GetTitle().c_str(); + mpvPlugin->Service(MPV_SET_TITLE, &reqTitle); return; } else if (Config::GetInstance().UseMpv) { @@ -1,14 +1,16 @@ #pragma once -#define MPV_START_PLAY_SERVICE "Mpv-StartPlayService_v1_0" -#define MPV_SET_TITLE_SERVICE "Mpv-SetTitleService_v1_0" +#define MPV_PLAY_FILE "Mpv_PlayFile" +#define MPV_SET_TITLE "Mpv_SetTitle" +// play the given Filename, this can be a media file or a playlist typedef struct { - char* Filename; - char* Title; -} Mpv_StartPlayService_v1_0_t; + char *Filename; +} Mpv_PlayFile; + +// Overrides the displayed title in replay info typedef struct { - char* Title; -} Mpv_SetTitleService_v1_0_t;
\ No newline at end of file + char *Title; +} Mpv_SetTitle; |