forked from trav/lintunes
v0.24.0: click the blank cover
Clicking the gray sidebar art square (playing track has no embedded art) now opens Download Album Art for that track, same as the right-click menu. Once art is embedded the square refreshes and a click opens the big view again.
This commit is contained in:
@@ -206,6 +206,8 @@ class MainWindow(QMainWindow):
|
||||
self._sidebar.library_selected.connect(self._show_library)
|
||||
self._sidebar.playlist_selected.connect(self._show_playlist)
|
||||
self._sidebar.tree.export_requested.connect(self._export_playlist)
|
||||
self._sidebar.art.download_art_requested.connect(
|
||||
lambda tid: self._download_album_art([tid]))
|
||||
self._content.currentChanged.connect(self._update_totals)
|
||||
for view in (self._library_view, self._playlist_view):
|
||||
view.play_requested.connect(
|
||||
@@ -1399,7 +1401,11 @@ class MainWindow(QMainWindow):
|
||||
self, "Download Album Art",
|
||||
"Couldn't embed artwork in some files:\n\n"
|
||||
+ "\n".join(failures[:10]))
|
||||
elif done:
|
||||
if done:
|
||||
# Normally track_updated already did this, but only when the
|
||||
# file's size changed.
|
||||
self._sidebar.art.refresh()
|
||||
if done and not failures:
|
||||
noun = "track" if done == 1 else "tracks"
|
||||
self.statusBar().showMessage(
|
||||
f"Artwork embedded in {done} {noun}", 5000)
|
||||
|
||||
Reference in New Issue
Block a user