[gnome-music] window: Check if visible child is ArtistsAlbumsWidget on search toggle
- From: Felipe Borges <felipeborges src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-music] window: Check if visible child is ArtistsAlbumsWidget on search toggle
- Date: Fri, 4 Mar 2016 12:20:54 +0000 (UTC)
commit fa689fd914dae50f7ff5cf0a670aeac430f68236
Author: Gaurav Narula <gnarula94 gmail com>
Date: Sun Feb 28 05:54:08 2016 +0530
window: Check if visible child is ArtistsAlbumsWidget on search toggle
If a search is made from the Albums view, clicking on the artist
result reverts back to the Albums view again. This patch adds a
condition to check if the visible child of the current view is a
ArtistsAlbumsWidget and does not switch to the Albums view if so.
https://bugzilla.gnome.org/show_bug.cgi?id=761890
gnomemusic/window.py | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/gnomemusic/window.py b/gnomemusic/window.py
index e6bc69d..a41d974 100644
--- a/gnomemusic/window.py
+++ b/gnomemusic/window.py
@@ -461,7 +461,8 @@ class Window(Gtk.ApplicationWindow):
# We should get back to the view before the search
self._stack.set_visible_child(self.views[4].previous_view)
elif (self.views[4].previous_view == self.views[0] and
- self.curr_view.get_visible_child() != self.curr_view._albumWidget):
+ self.curr_view.get_visible_child() != self.curr_view._albumWidget and
+ self.curr_view.get_visible_child() != self.curr_view._artistAlbumsWidget):
self._stack.set_visible_child(self.views[0])
if self.toolbar._selectionMode:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]