[gnome-music/wip/mschraal/albumview-covers-on-demand: 2/3] albumsview: Clarify widget naming
- From: Marinus Schraal <mschraal src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-music/wip/mschraal/albumview-covers-on-demand: 2/3] albumsview: Clarify widget naming
- Date: Mon, 4 Nov 2019 16:58:39 +0000 (UTC)
commit 4f5aacd75e4503cd3e3257486cb7b60b8e5e9526
Author: Marinus Schraal <mschraal gnome org>
Date: Fri Oct 18 17:20:01 2019 +0200
albumsview: Clarify widget naming
data/ui/AlbumsView.ui | 2 +-
gnomemusic/views/albumsview.py | 10 +++++-----
2 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/data/ui/AlbumsView.ui b/data/ui/AlbumsView.ui
index 116231fe..cb7828fc 100644
--- a/data/ui/AlbumsView.ui
+++ b/data/ui/AlbumsView.ui
@@ -3,7 +3,7 @@
<requires lib="gtk+" version="3.18"/>
<template class="AlbumsView" parent="GtkStack">
<child>
- <object class="GtkScrolledWindow" id="_all_albums">
+ <object class="GtkScrolledWindow" id="_scrolled_window">
<property name="visible">True</property>
<child>
<object class="GtkFlowBox" id="_flowbox">
diff --git a/gnomemusic/views/albumsview.py b/gnomemusic/views/albumsview.py
index 900f32b2..6fb3eda6 100644
--- a/gnomemusic/views/albumsview.py
+++ b/gnomemusic/views/albumsview.py
@@ -45,7 +45,7 @@ class AlbumsView(Gtk.Stack):
selected_items_count = GObject.Property(type=int, default=0, minimum=0)
selection_mode = GObject.Property(type=bool, default=False)
- _all_albums = Gtk.Template.Child()
+ _scrolled_window = Gtk.Template.Child()
_flowbox = Gtk.Template.Child()
def __repr__(self):
@@ -87,9 +87,9 @@ class AlbumsView(Gtk.Stack):
self.connect(
"notify::search-mode-active", self._on_search_mode_changed)
- self._all_albums.props.vadjustment.connect(
+ self._scrolled_window.props.vadjustment.connect(
"value-changed", self._on_vadjustment_changed)
- self._all_albums.props.vadjustment.connect(
+ self._scrolled_window.props.vadjustment.connect(
"changed", self._on_vadjustment_changed)
self.show_all()
@@ -104,7 +104,7 @@ class AlbumsView(Gtk.Stack):
priority=GLib.PRIORITY_LOW)
def _retrieve_covers(self, old_adjustment):
- adjustment = self._all_albums.props.vadjustment.props.value
+ adjustment = self._scrolled_window.props.vadjustment.props.value
if old_adjustment != adjustment:
return GLib.SOURCE_CONTINUE
@@ -168,7 +168,7 @@ class AlbumsView(Gtk.Stack):
def _back_button_clicked(self, widget, data=None):
self._headerbar.state = HeaderBar.State.MAIN
- self.props.visible_child = self._all_albums
+ self.props.visible_child = self._scrolled_window
def _on_child_activated(self, widget, child, user_data=None):
corealbum = child.props.corealbum
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]