websocket client boilerplate
This commit is contained in:
parent
25c3c5171c
commit
b27dcec0b9
@ -45,33 +45,33 @@
|
|||||||
#include <QKeyEvent>
|
#include <QKeyEvent>
|
||||||
|
|
||||||
#include <QBluetoothLocalDevice>
|
#include <QBluetoothLocalDevice>
|
||||||
//#include <QtBluetooth>
|
// #include <QtBluetooth>
|
||||||
|
|
||||||
namespace Ui
|
namespace Ui
|
||||||
{
|
{
|
||||||
class MainWindow;
|
class MainWindow;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace f1x
|
namespace f1x
|
||||||
{
|
{
|
||||||
namespace openauto
|
namespace openauto
|
||||||
{
|
{
|
||||||
namespace autoapp
|
namespace autoapp
|
||||||
{
|
{
|
||||||
namespace ui
|
namespace ui
|
||||||
{
|
{
|
||||||
|
|
||||||
class MainWindow : public QMainWindow
|
class MainWindow : public QMainWindow
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
explicit MainWindow(configuration::IConfiguration::Pointer configuration, QWidget *parent = nullptr);
|
explicit MainWindow(configuration::IConfiguration::Pointer configuration, QWidget *parent = nullptr);
|
||||||
~MainWindow() override;
|
~MainWindow() override;
|
||||||
QMediaPlayer* player;
|
QMediaPlayer *player;
|
||||||
QFileSystemWatcher* watcher;
|
QFileSystemWatcher *watcher;
|
||||||
QFileSystemWatcher* watcher_tmp;
|
QFileSystemWatcher *watcher_tmp;
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
void exit();
|
void exit();
|
||||||
void reboot();
|
void reboot();
|
||||||
void openSettings();
|
void openSettings();
|
||||||
@ -100,11 +100,11 @@ signals:
|
|||||||
void TriggerAppStop();
|
void TriggerAppStop();
|
||||||
void CloseAllDialogs();
|
void CloseAllDialogs();
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void on_horizontalSliderBrightness_valueChanged(int value);
|
void on_horizontalSliderBrightness_valueChanged(int value);
|
||||||
void updateAlpha();
|
void updateAlpha();
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void on_pushButtonBrightness_clicked();
|
void on_pushButtonBrightness_clicked();
|
||||||
void on_pushButtonBrightness2_clicked();
|
void on_pushButtonBrightness2_clicked();
|
||||||
void switchGuiToDay();
|
void switchGuiToDay();
|
||||||
@ -152,14 +152,16 @@ private slots:
|
|||||||
void updateNetworkInfo();
|
void updateNetworkInfo();
|
||||||
bool check_file_exist(const char *filename);
|
bool check_file_exist(const char *filename);
|
||||||
void hostModeStateChanged(QBluetoothLocalDevice::HostMode);
|
void hostModeStateChanged(QBluetoothLocalDevice::HostMode);
|
||||||
|
void connectWebSocket();
|
||||||
|
void handleIncomingMessage(const QString &message);
|
||||||
|
|
||||||
//void on_AlbumCoverListView_clicked(const QModelIndex &index);
|
// void on_AlbumCoverListView_clicked(const QModelIndex &index);
|
||||||
void on_AlbumCoverListView_clicked(const QModelIndex &index);
|
void on_AlbumCoverListView_clicked(const QModelIndex &index);
|
||||||
|
|
||||||
void on_pushButtonAlbum_clicked();
|
void on_pushButtonAlbum_clicked();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
Ui::MainWindow* ui_;
|
Ui::MainWindow *ui_;
|
||||||
configuration::IConfiguration::Pointer configuration_;
|
configuration::IConfiguration::Pointer configuration_;
|
||||||
|
|
||||||
QString brightnessFilename = "/sys/class/backlight/rpi_backlight/brightness";
|
QString brightnessFilename = "/sys/class/backlight/rpi_backlight/brightness";
|
||||||
@ -263,12 +265,11 @@ private:
|
|||||||
|
|
||||||
QBluetoothLocalDevice *localDevice;
|
QBluetoothLocalDevice *localDevice;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void keyPressEvent(QKeyEvent *event);
|
void keyPressEvent(QKeyEvent *event);
|
||||||
|
};
|
||||||
|
|
||||||
};
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user