Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
pg mr
gajim
Commits
76501abf
Commit
76501abf
authored
Feb 09, 2021
by
Daniel Brötzmann
Browse files
Preferences: Check for pipeline before removing elements
Fixes #10430
parent
1692f3ed
Changes
1
Hide whitespace changes
Inline
Side-by-side
gajim/gtk/video_preview.py
View file @
76501abf
...
...
@@ -98,12 +98,14 @@ def _enable_preview(self):
def
_disable_preview
(
self
):
if
self
.
_av_pipeline
is
not
None
:
self
.
_av_pipeline
.
set_state
(
Gst
.
State
.
NULL
)
if
self
.
_av_src
is
not
None
:
self
.
_av_pipeline
.
remove
(
self
.
_av_src
)
self
.
_av_src
=
None
if
self
.
_av_sink
is
not
None
:
self
.
_av_pipeline
.
remove
(
self
.
_av_sink
)
self
.
_av_sink
=
None
if
self
.
_av_src
is
not
None
:
self
.
_av_pipeline
.
remove
(
self
.
_av_src
)
if
self
.
_av_sink
is
not
None
:
self
.
_av_pipeline
.
remove
(
self
.
_av_sink
)
self
.
_av_src
=
None
self
.
_av_sink
=
None
if
self
.
_av_widget
is
not
None
:
self
.
_ui
.
video_preview_box
.
remove
(
self
.
_av_widget
)
self
.
_ui
.
video_preview_placeholder
.
set_visible
(
True
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment