From 18a7d34d954bfbe3d4be54bd0af15f370a7ce98e Mon Sep 17 00:00:00 2001 From: Rafostar <40623528+Rafostar@users.noreply.github.com> Date: Tue, 1 Sep 2020 17:45:36 +0200 Subject: [PATCH] Do not set position adjustment twice --- clapper_src/interface.js | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/clapper_src/interface.js b/clapper_src/interface.js index 23e192f9..a744cfb2 100644 --- a/clapper_src/interface.js +++ b/clapper_src/interface.js @@ -18,9 +18,9 @@ class ClapperInterface extends Gtk.Grid { this._player = player; this._player.widget.expand = true; - this._connectControlsToPlayer(); this.attach(this._player.widget, 0, 0, 1, 1); + this._connectControlsToPlayer(); } _connectControlsToPlayer() @@ -68,11 +68,9 @@ class ClapperInterface extends Gtk.Grid ? 1 : duration / 100; - let adjustment = this.controls.positionScale.get_adjustment(); - adjustment.set_upper(duration); - adjustment.set_step_increment(increment); - adjustment.set_page_increment(increment); - this.controls.positionScale.set_adjustment(adjustment); + this.controls.positionAdjustment.set_upper(duration); + this.controls.positionAdjustment.set_step_increment(increment); + this.controls.positionAdjustment.set_page_increment(increment); } _onPlayerPositionUpdated(player, position)