From e615524d8e5ff7a356f2d84d8040d7730dcad7b4 Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Tue, 19 Mar 2019 18:12:24 +0100 Subject: tracker/pt: move to inner scope --- tracker-pt/ftnoir_tracker_pt.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tracker-pt/ftnoir_tracker_pt.cpp b/tracker-pt/ftnoir_tracker_pt.cpp index 1ca51368..ca228a24 100644 --- a/tracker-pt/ftnoir_tracker_pt.cpp +++ b/tracker-pt/ftnoir_tracker_pt.cpp @@ -57,7 +57,6 @@ void Tracker_PT::run() { pt_camera_info info; bool new_frame = false; - const bool preview_visible = check_is_visible(); { QMutexLocker l(&camera_mtx); @@ -68,6 +67,8 @@ void Tracker_PT::run() if (new_frame) { + const bool preview_visible = check_is_visible(); + if (preview_visible) *preview_frame = *frame; -- cgit v1.2.3