[gnome-music/wip/mschraal/gtk4: 20/73] smoothscale: StyleContext getter does not need state



commit 8e99fd26870e29d9ca9882d36c5929830ca74073
Author: Marinus Schraal <mschraal gnome org>
Date:   Thu Oct 31 16:37:09 2019 +0100

    smoothscale: StyleContext getter does not need state

 gnomemusic/widgets/smoothscale.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/gnomemusic/widgets/smoothscale.py b/gnomemusic/widgets/smoothscale.py
index 31bd85cd..e6eb3578 100644
--- a/gnomemusic/widgets/smoothscale.py
+++ b/gnomemusic/widgets/smoothscale.py
@@ -162,10 +162,10 @@ class SmoothScale(Gtk.Scale):
         duration = abs(self._player.props.duration)
 
         style_context = self.get_style_context()
-        state = style_context.get_state()
+        # state = style_context.get_state()
 
         width = self.get_allocated_width()
-        padding = style_context.get_padding(state)
+        padding = style_context.get_padding()
         width = max(width - (padding.left + padding.right), 1)
 
         timeout_period = min(1000 * duration // width, 200)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]