[gnome-music/wip/mschraal/artistsview-selection-through-coreobjects] artistsview: Fix conditional logic
- From: Marinus Schraal <mschraal src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-music/wip/mschraal/artistsview-selection-through-coreobjects] artistsview: Fix conditional logic
- Date: Wed, 2 Feb 2022 22:55:13 +0000 (UTC)
commit 27b4388eaad5c2de4ba179fdc35ebd7155dc9dd5
Author: Marinus Schraal <mschraal gnome org>
Date: Wed Feb 2 23:49:06 2022 +0100
artistsview: Fix conditional logic
* Use 'is' operator for object comparison
* Use active_view property instead of object parent/child call
gnomemusic/views/artistsview.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/gnomemusic/views/artistsview.py b/gnomemusic/views/artistsview.py
index 9c451be3b..b967f3d87 100644
--- a/gnomemusic/views/artistsview.py
+++ b/gnomemusic/views/artistsview.py
@@ -185,7 +185,7 @@ class ArtistsView(Gtk.Paned):
:param bool value: Activate selection mode
"""
if (value == self._selection_mode
- or self.get_parent().get_visible_child() != self):
+ or self._window.props.active_view is not self):
return
self._selection_mode = value
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]