API: make "state" into a property

This commit is contained in:
Rafał Dzięgiel
2021-04-26 22:30:01 +02:00
parent f4e48c9f8c
commit ec1d4619a7
3 changed files with 35 additions and 2 deletions

View File

@@ -33,7 +33,6 @@ class ClapperPlayer extends GstClapper.Clapper
this.widget = gtk4plugin.video_sink.widget;
this.widget.add_css_class('videowidget');
this.state = GstClapper.ClapperState.STOPPED;
this.visualization_enabled = false;
this.webserver = null;
@@ -518,7 +517,6 @@ class ClapperPlayer extends GstClapper.Clapper
_onStateChanged(player, state)
{
this.state = state;
this.emitWs('state_changed', state);
if(state !== GstClapper.ClapperState.BUFFERING) {