SceneSwitcher/lib/utils/duration-control.hpp
WarmUpTill 7d0332dd0e Restructure library and plugins
The "core" macro conditions and actions have been extracted out to the
"base" plugin.

The library now mostly contains functionality which is required across
all plugins and (e.g. definitions for macro segments).

The goal is to reduce the complexity and cross-dependencies and group
the source files in a better way.

This should relsove the "library limit of 65535 objects exceeded" build
issue occuring in some Windows build environments.
2024-01-27 14:10:34 +01:00

35 lines
749 B
C++

#pragma once
#include "duration.hpp"
#include "variable-spinbox.hpp"
#include <QWidget>
#include <QDoubleSpinBox>
#include <QComboBox>
#include <QPushButton>
namespace advss {
class DurationSelection : public QWidget {
Q_OBJECT
public:
EXPORT DurationSelection(QWidget *parent = nullptr,
bool showUnitSelection = true,
double minValue = 0.0);
EXPORT void SetDuration(const Duration &);
EXPORT QDoubleSpinBox *SpinBox() { return _duration->SpinBox(); }
private slots:
void _DurationChanged(const NumberVariable<double> &value);
void _UnitChanged(int idx);
signals:
void DurationChanged(const Duration &value);
private:
VariableDoubleSpinBox *_duration;
QComboBox *_unitSelection;
Duration _current;
};
} // namespace advss