File indexing completed on 2024-05-19 16:31:41

0001 /*
0002  *   SPDX-FileCopyrightText: 2015 Bernhard Friedreich <friesoft@gmail.com>
0003  *
0004  *   SPDX-License-Identifier: GPL-2.0-or-later
0005  */
0006 
0007 #ifndef TIMER_H
0008 #define TIMER_H
0009 
0010 #include <QObject>
0011 
0012 class Timer : public QObject
0013 {
0014     Q_OBJECT
0015 
0016 public:
0017     explicit Timer(QObject *parent = nullptr);
0018     Q_INVOKABLE void runCommand(const QString &command);
0019     /*!
0020      * Represent \a seconds as s string representing time duration with
0021      * given format based on QTime.
0022      */
0023     Q_INVOKABLE QString secondsToString(int seconds, const QString &format);
0024 };
0025 
0026 #endif // TIMER_H