[gnome-music/wip/mschraal/gtk4-v2: 50/55] albumsview: Misc fixes: events & deprecated props
- From: Marinus Schraal <mschraal src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-music/wip/mschraal/gtk4-v2: 50/55] albumsview: Misc fixes: events & deprecated props
- Date: Sat, 22 May 2021 21:02:09 +0000 (UTC)
commit e0a01eeadb2751bad686026bc859822c45109d1c
Author: Marinus Schraal <mschraal gnome org>
Date: Wed Apr 14 08:49:32 2021 +0200
albumsview: Misc fixes: events & deprecated props
gnomemusic/views/albumsview.py | 11 +++++------
1 file changed, 5 insertions(+), 6 deletions(-)
---
diff --git a/gnomemusic/views/albumsview.py b/gnomemusic/views/albumsview.py
index 5be7629cc..97bc00b2c 100644
--- a/gnomemusic/views/albumsview.py
+++ b/gnomemusic/views/albumsview.py
@@ -137,7 +137,7 @@ class AlbumsView(Gtk.Stack):
covers_col = math.ceil(viewport_w / cover_w)
covers_row = math.ceil(viewport_h / cover_h)
- children = self._flowbox.get_children()
+ children = [child for child in self._flowbox]
retrieve_list = []
for i, albumcover in enumerate(children):
if top_left_cover == albumcover:
@@ -207,14 +207,13 @@ class AlbumsView(Gtk.Stack):
def _set_album_headerbar(self, corealbum):
self._headerbar.props.state = HeaderBar.State.CHILD
- self._headerbar.props.title = corealbum.props.title
- self._headerbar.props.subtitle = corealbum.props.artist
+ # self._headerbar.props.title = corealbum.props.title
+ # self._headerbar.props.subtitle = corealbum.props.artist
@Gtk.Template.Callback()
def _on_flowbox_press_begin(self, gesture, sequence):
- event = gesture.get_last_event(sequence)
- ok, state = event.get_state()
- if ((ok is True
+ state = gesture.get_current_event_state()
+ if ((state
and state == Gdk.ModifierType.CONTROL_MASK)
or self.props.selection_mode is True):
self._flowbox.props.selection_mode = Gtk.SelectionMode.MULTIPLE
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]