[libcamera-devel] [RFC] [PATCH 1/3] Added statusbar to show the camera stream configuration
Laurent Pinchart
laurent.pinchart at ideasonboard.com
Fri Mar 20 15:41:32 CET 2020
Hi Show,
Thank you for the patch.
On Fri, Mar 20, 2020 at 04:50:27PM +0800, Show Liu wrote:
> qcam: Added statusbar to show the camera stream information
This should be the subject line :-)
s/statusbar/status bar/
> Signed-off-by: Show Liu <show.liu at linaro.org>
> ---
> src/qcam/main_window.cpp | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/src/qcam/main_window.cpp b/src/qcam/main_window.cpp
> index ae1760d..98e55ba 100644
> --- a/src/qcam/main_window.cpp
> +++ b/src/qcam/main_window.cpp
> @@ -21,6 +21,7 @@
> #include <QTimer>
> #include <QToolBar>
> #include <QToolButton>
> +#include <QStatusBar>
Please keep headers sorted alphabetically.
>
> #include <libcamera/camera_manager.h>
> #include <libcamera/version.h>
> @@ -238,6 +239,8 @@ int MainWindow::startCapture()
> return ret;
> }
>
> + statusBar()->showMessage(QString(cfg.toString().c_str()));
> +
Shouldn't we create the status bar when creating the main window, to
avoid its magical apparition when starting the stream ? I would then
store it in the MainWindow class to avoid retrieving it from Qt every
time.
> adjustSize();
>
> allocator_ = FrameBufferAllocator::create(camera_);
> @@ -342,6 +345,8 @@ void MainWindow::stopCapture()
>
> config_.reset();
>
> + statusBar()->clearMessage();
> +
> titleTimer_.stop();
> setWindowTitle(title_);
> }
--
Regards,
Laurent Pinchart
More information about the libcamera-devel
mailing list