File indexing completed on 2024-05-12 04:52:54

0001 /*
0002     SPDX-FileCopyrightText: 2018 Jean-Baptiste Mardelle
0003     This file is part of Kdenlive. See www.kdenlive.org.
0004 
0005     SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
0006 */
0007 
0008 #pragma once
0009 
0010 #include "abstractparamwidget.hpp"
0011 #include "ui_boolparamwidget_ui.h"
0012 #include <QWidget>
0013 
0014 /** @brief This class represents a parameter that requires
0015            the user to choose tick a checkbox
0016  */
0017 class MultiSwitchParamWidget : public AbstractParamWidget, public Ui::BoolParamWidget_UI
0018 {
0019     Q_OBJECT
0020 public:
0021     /** @brief Constructor for the widgetComment
0022         @param name String containing the name of the parameter
0023         @param comment Optional string containing the comment associated to the parameter
0024         @param checked Boolean indicating whether the checkbox should initially be checked
0025         @param parent Parent widget
0026     */
0027     MultiSwitchParamWidget(std::shared_ptr<AssetParameterModel> model, QModelIndex index, QWidget *parent);
0028 
0029 public Q_SLOTS:
0030     /** @brief Toggle the comments on or off
0031      */
0032     void slotShowComment(bool show) override;
0033 
0034     /** @brief refresh the properties to reflect changes in the model
0035      */
0036     void slotRefresh() override;
0037 };