simplified CoverEventBox

This commit is contained in:
Martin Wagner 2022-12-02 18:18:39 +01:00
parent 3bd3d8d687
commit 69e9e33273

View File

@ -2525,11 +2525,9 @@ class CoverEventBox(Gtk.EventBox):
self._click_pos=(event.x, event.y)
def _on_button_release_event(self, widget, event):
if event.button != 1 or self._click_pos:
if not self._settings.get_boolean("mini-player") and self._client.connected():
if event.button == 1 and not self._settings.get_boolean("mini-player") and self._client.connected():
if (song:=self._client.currentsong()):
tags=(song["albumartist"][0], song["album"][0], song["date"][0])
if event.button == 1:
self._client.album_to_playlist(*tags, "enqueue")
self._click_pos=()