aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/mpris2-controller.vala7
-rw-r--r--src/mpris2-interfaces.vala2
-rw-r--r--src/player-item.vala2
3 files changed, 5 insertions, 6 deletions
diff --git a/src/mpris2-controller.vala b/src/mpris2-controller.vala
index 58a1906..4990b38 100644
--- a/src/mpris2-controller.vala
+++ b/src/mpris2-controller.vala
@@ -102,9 +102,10 @@ public class Mpris2Controller : GLib.Object
public bool playlist_support()
{
- // awaiting spec updates
- // return this.mpris2_root.HasPlaylists;
- return true;
+ if (this.playlists == null) return false;
+ uint32? count = this.playlists.PlaylistCount;
+ if ( count == null || count <= 0 ) return false;
+ return true;
}
private bool ensure_correct_playback_status(){
diff --git a/src/mpris2-interfaces.vala b/src/mpris2-interfaces.vala
index 4f01c4c..a731de8 100644
--- a/src/mpris2-interfaces.vala
+++ b/src/mpris2-interfaces.vala
@@ -21,8 +21,6 @@ with this program. If not, see <http://www.gnu.org/licenses/>.
public interface MprisRoot : Object {
// properties
public abstract bool HasTracklist{owned get; set;}
- //waiting for MPRIS approval
- //public abstract bool HasPlaylist{owned get; set;}
public abstract bool CanQuit{owned get; set;}
public abstract bool CanRaise{owned get; set;}
public abstract string Identity{owned get; set;}
diff --git a/src/player-item.vala b/src/player-item.vala
index 75f673b..f883a1e 100644
--- a/src/player-item.vala
+++ b/src/player-item.vala
@@ -28,7 +28,7 @@ public class PlayerItem : Dbusmenu.Menuitem
public PlayerItem(string type)
{
- Object(item_type: type);
+ Object(item_type: type);
}
construct {