JustAudio/gui/ui.h

58 lines
1.0 KiB
C
Raw Normal View History

#ifndef UI_H
#define UI_H
#include <QWidget>
#include <QVBoxLayout>
#include <QHBoxLayout>
#include <QSlider>
#include <QLabel>
#include <QDir>
#include <QFile>
#include <QMediaPlayer>
#include <QUrl>
#include <QFileDialog>
#include <QStringList>
#include <QMessageBox>
#include <QFont>
#include <QApplication>
#include <QRect>
#include <QDesktopWidget>
#include <QTimer>
#include "icon.h"
#include "../io/aud_file.h"
class Ui : public QWidget
{
Q_OBJECT
private:
QLabel *fileName;
QSlider *slider;
QMediaPlayer *player;
AudFile *ioDev;
Icon *pausePlay;
Icon *settings;
Icon *open;
QString fileDir;
bool pressed;
private slots:
void error(QMediaPlayer::Error error);
void sliderPressed();
void sliderReleased();
void posChanged(qint64 pos);
void durationChanged(qint64 len);
void openDialog();
void nextFile();
void play(const QString &path);
public:
Ui(const QStringList &args, QWidget *parent = 0);
};
#endif // UI_H