Stop viewfinder if there is an error
authorMohammed Sameer <msameer@foolab.org>
Sat, 8 Dec 2012 22:49:55 +0000 (00:49 +0200)
committerMohammed Sameer <msameer@foolab.org>
Sat, 8 Dec 2012 22:49:55 +0000 (00:49 +0200)
lib/qtcamdevice.cpp

index 4120640..2eb5d3f 100644 (file)
@@ -197,6 +197,9 @@ bool QtCamDevice::stop(bool force) {
   if (d_ptr->error) {
     gst_element_set_state(d_ptr->cameraBin, GST_STATE_NULL);
     d_ptr->error = false;
+
+    d_ptr->viewfinder->stop();
+
     return true;
   }