Commit 4250dc0f authored by Jean Felder's avatar Jean Felder Committed by Marinus Schraal

coresong: Override equality operator

parent 273bac1e
......@@ -32,6 +32,10 @@ class CoreSong(GObject.GObject):
self.props.grlid = media.get_source() + media.get_id()
self.update(media)
def __eq__(self, other):
return (isinstance(other, CoreSong)
and other.props.media.get_id() == self.props.media.get_id())
@GObject.Property(type=bool, default=False)
def favorite(self):
return self._favorite
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment