mirror of
https://github.com/SoongNoonien/mpdevil.git
synced 2023-08-10 21:12:44 +03:00
fixed popdown of popovers
This commit is contained in:
parent
8e3aa47dc5
commit
63135b23cb
10
bin/mpdevil
10
bin/mpdevil
@ -1624,6 +1624,7 @@ class SongsView(Gtk.TreeView):
|
||||
self._client.emitter.connect("add-to-playlist", self._on_add_to_playlist)
|
||||
|
||||
def clear(self):
|
||||
self._song_popover.popdown()
|
||||
self._store.clear()
|
||||
|
||||
def count(self):
|
||||
@ -2151,6 +2152,7 @@ class ArtistWindow(SelectionList):
|
||||
self._artist_popover=ArtistPopover(self._client)
|
||||
|
||||
# connect
|
||||
self.connect("clear", lambda *args: self._artist_popover.popdown())
|
||||
self.connect("button-press-event", self._on_button_press_event)
|
||||
self._settings.connect("changed::use-album-artist", self._refresh)
|
||||
self._client.emitter.connect("disconnected", self._on_disconnected)
|
||||
@ -2217,7 +2219,6 @@ class ArtistWindow(SelectionList):
|
||||
|
||||
def _on_disconnected(self, *args):
|
||||
self.set_sensitive(False)
|
||||
self._artist_popover.popdown()
|
||||
self.clear()
|
||||
|
||||
def _on_reconnected(self, *args):
|
||||
@ -2283,6 +2284,8 @@ class AlbumWindow(FocusFrame):
|
||||
|
||||
def _clear(self, *args):
|
||||
if self._done:
|
||||
self._album_popover.popdown()
|
||||
self._artist_popover.popdown()
|
||||
self._workaround_clear()
|
||||
elif not self._clear in self._pending:
|
||||
self._stop_flag=True
|
||||
@ -2462,8 +2465,6 @@ class AlbumWindow(FocusFrame):
|
||||
|
||||
def _on_disconnected(self, *args):
|
||||
self._iconview.set_sensitive(False)
|
||||
self._album_popover.popdown()
|
||||
self._artist_popover.popdown()
|
||||
|
||||
def _on_reconnected(self, *args):
|
||||
self._iconview.set_sensitive(True)
|
||||
@ -2974,6 +2975,7 @@ class PlaylistWindow(Gtk.Box):
|
||||
self._treeview.append_column(self._columns[i])
|
||||
|
||||
def _clear(self, *args):
|
||||
self._song_popover.popdown()
|
||||
self._playlist_info.set_text("")
|
||||
self._playlist_version=None
|
||||
self._selected_path=None
|
||||
@ -3061,6 +3063,7 @@ class PlaylistWindow(Gtk.Box):
|
||||
def _on_playlist_changed(self, emitter, version):
|
||||
self._store.handler_block(self._row_inserted)
|
||||
self._store.handler_block(self._row_deleted)
|
||||
self._song_popover.popdown()
|
||||
self._unselect()
|
||||
songs=[]
|
||||
if self._playlist_version is not None:
|
||||
@ -3128,7 +3131,6 @@ class PlaylistWindow(Gtk.Box):
|
||||
def _on_disconnected(self, *args):
|
||||
self._treeview.set_sensitive(False)
|
||||
self._back_to_current_song_button.set_sensitive(False)
|
||||
self._song_popover.popdown()
|
||||
self._clear()
|
||||
|
||||
def _on_reconnected(self, *args):
|
||||
|
Loading…
Reference in New Issue
Block a user