From 78c398c0a23f734aa2e865c6832e1667dfe95929 Mon Sep 17 00:00:00 2001 From: Florian Zeitz Date: Thu, 5 Jul 2012 21:53:50 +0200 Subject: [PATCH] Fetch track information using comand lists --- src/PEPThread.m | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/PEPThread.m b/src/PEPThread.m index 91976ae..4daaefc 100644 --- a/src/PEPThread.m +++ b/src/PEPThread.m @@ -77,12 +77,15 @@ tune = [OFXMLElement elementWithName: @"tune" namespace: NS_TUNE]; [item addChild: tune]; + + [conn send: @"command_list_begin"]; [conn send: @"status"]; + [conn send: @"currentsong"]; + [conn send: @"command_list_end"]; response = [conn response]; + if ([[response objectForKey: @"state"] isEqual: @"play"]) { - [conn send: @"currentsong"]; - response = [conn response]; if ((answer = [response objectForKey: @"Artist"])) [tune addChild: [OFXMLElement -- 2.39.5