summaryrefslogtreecommitdiff
path: root/src/qcam/main_window.h
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2019-08-18 03:22:45 +0300
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2019-08-19 19:06:23 +0300
commitaf49b18c81a3998b59b1aae0daa16ec5050e44fc (patch)
treedb3b3ba4078bcad37da3bb447f940760d09e90ad /src/qcam/main_window.h
parent749dbd576f98d928fc4bc6a5116640d98f2f6dce (diff)
qcam: Pass camera manager to MainWindow class
Pass the CameraManager instance from the main() function to the MainWindow class instead of accessing it through CameraManager::instance(). This prepares for the removal of the CameraManager::instance() method. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
Diffstat (limited to 'src/qcam/main_window.h')
-rw-r--r--src/qcam/main_window.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/qcam/main_window.h b/src/qcam/main_window.h
index b45cbca7..6873155a 100644
--- a/src/qcam/main_window.h
+++ b/src/qcam/main_window.h
@@ -16,6 +16,7 @@
#include <QTimer>
#include <libcamera/camera.h>
+#include <libcamera/camera_manager.h>
#include <libcamera/stream.h>
#include "../cam/options.h"
@@ -35,14 +36,14 @@ class MainWindow : public QMainWindow
Q_OBJECT
public:
- MainWindow(const OptionsParser::Options &options);
+ MainWindow(CameraManager *cm, const OptionsParser::Options &options);
~MainWindow();
private Q_SLOTS:
void updateTitle();
private:
- int openCamera();
+ int openCamera(CameraManager *cm);
int startCapture();
void stopCapture();