[gnome-music/wip/jfelder/gtk4-v3: 81/200] window: Use AdwViewStack instead of GtkStack
- From: Jean Felder <jfelder src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-music/wip/jfelder/gtk4-v3: 81/200] window: Use AdwViewStack instead of GtkStack
- Date: Fri, 11 Feb 2022 15:44:49 +0000 (UTC)
commit af9444220e2d077c269f636e9af223a9e508fd6d
Author: Jean Felder <jfelder src gnome org>
Date: Wed Feb 2 13:57:54 2022 +0100
window: Use AdwViewStack instead of GtkStack
data/ui/Window.ui | 6 ++----
gnomemusic/widgets/headerbar.py | 2 +-
gnomemusic/widgets/searchheaderbar.py | 2 +-
3 files changed, 4 insertions(+), 6 deletions(-)
---
diff --git a/data/ui/Window.ui b/data/ui/Window.ui
index 1292d639d..ca227de33 100644
--- a/data/ui/Window.ui
+++ b/data/ui/Window.ui
@@ -24,12 +24,10 @@
<property name="vexpand">True</property>
<property name="visible">True</property>
<child>
- <object class="GtkStack" id="_stack">
- <property name="can-focus">False</property>
+ <object class="AdwViewStack" id="_stack">
+ <property name="focusable">False</property>
<property name="hhomogeneous">False</property>
<property name="vhomogeneous">False</property>
- <property name="transition-duration">100</property>
- <property name="transition-type">crossfade</property>
<property name="visible">True</property>
</object>
</child>
diff --git a/gnomemusic/widgets/headerbar.py b/gnomemusic/widgets/headerbar.py
index 8fb912938..137115abc 100644
--- a/gnomemusic/widgets/headerbar.py
+++ b/gnomemusic/widgets/headerbar.py
@@ -101,7 +101,7 @@ class HeaderBar(Adw.Bin):
search_mode_active = GObject.Property(type=bool, default=False)
selected_songs_count = GObject.Property(type=int, default=0, minimum=0)
selection_mode_allowed = GObject.Property(type=bool, default=True)
- stack = GObject.Property(type=Gtk.Stack)
+ stack = GObject.Property(type=Adw.ViewStack)
def __init__(self, application):
"""Initialize Headerbar
diff --git a/gnomemusic/widgets/searchheaderbar.py b/gnomemusic/widgets/searchheaderbar.py
index d437997f1..46f6b6f09 100644
--- a/gnomemusic/widgets/searchheaderbar.py
+++ b/gnomemusic/widgets/searchheaderbar.py
@@ -52,7 +52,7 @@ class SearchHeaderBar(Adw.Bin):
search_state = GObject.Property(type=int, default=Search.State.NONE)
selected_songs_count = GObject.Property(type=int, default=0, minimum=0)
selection_mode_allowed = GObject.Property(type=bool, default=True)
- stack = GObject.Property(type=Gtk.Stack)
+ stack = GObject.Property(type=Adw.ViewStack)
def __init__(self, application):
super().__init__()
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]