mirror of
https://github.com/cemu-project/Cemu.git
synced 2025-01-25 08:11:17 +01:00
39 lines
757 B
C
39 lines
757 B
C
|
#pragma once
|
||
|
|
||
|
#include <wx/button.h>
|
||
|
#include <wx/dialog.h>
|
||
|
#include <wx/gauge.h>
|
||
|
#include <wx/stattext.h>
|
||
|
|
||
|
class PairingDialog : public wxDialog
|
||
|
{
|
||
|
public:
|
||
|
PairingDialog(wxWindow* parent);
|
||
|
~PairingDialog();
|
||
|
|
||
|
private:
|
||
|
enum class PairingState
|
||
|
{
|
||
|
Pairing,
|
||
|
Finished,
|
||
|
NoBluetoothAvailable,
|
||
|
BluetoothFailed,
|
||
|
PairingFailed,
|
||
|
BluetoothUnusable
|
||
|
};
|
||
|
|
||
|
void OnClose(wxCloseEvent& event);
|
||
|
void OnCancelButton(const wxCommandEvent& event);
|
||
|
void OnGaugeUpdate(wxCommandEvent& event);
|
||
|
|
||
|
void WorkerThread();
|
||
|
void UpdateCallback(PairingState state);
|
||
|
|
||
|
wxStaticText* m_text;
|
||
|
wxGauge* m_gauge;
|
||
|
wxButton* m_cancelButton;
|
||
|
|
||
|
std::thread m_thread;
|
||
|
bool m_threadShouldQuit = false;
|
||
|
};
|