OpenHantek
selectsupporteddevice.h
Go to the documentation of this file.
1 // SPDX-License-Identifier: GPL-2.0+
2 
3 #pragma once
4 
5 #include "ui_selectsupporteddevice.h"
6 
7 #include <QDialog>
8 #include <QPushButton>
9 
10 #include "usb/scopedevice.h"
11 #include <memory>
12 
13 struct libusb_context;
14 
23 class SelectSupportedDevice : public QDialog {
24  Q_OBJECT
25 
26  public:
27  explicit SelectSupportedDevice( QWidget *parent = nullptr );
28  std::unique_ptr< ScopeDevice > showSelectDeviceModal( libusb_context *context, unsigned verboseLevel );
29  void showLibUSBFailedDialogModel( int error );
30 
31  private:
32  void updateDeviceList();
34  std::unique_ptr< Ui::SelectSupportedDevice > ui;
36  bool demoModeClicked = false;
37  unsigned verboseLevel = 0;
38 };
std::unique_ptr< Ui::SelectSupportedDevice > ui
Definition: selectsupporteddevice.h:34
void updateSupportedDevices()
Definition: selectsupporteddevice.cpp:161
SelectSupportedDevice(QWidget *parent=nullptr)
Definition: selectsupporteddevice.cpp:19
UniqueUSBid selectedDevice
Definition: selectsupporteddevice.h:35
unsigned verboseLevel
Definition: selectsupporteddevice.h:37
std::unique_ptr< ScopeDevice > showSelectDeviceModal(libusb_context *context, unsigned verboseLevel)
Definition: selectsupporteddevice.cpp:41
void showLibUSBFailedDialogModel(int error)
Definition: selectsupporteddevice.cpp:152
Definition: selectsupporteddevice.h:23
uint64_t UniqueUSBid
Definition: scopedevice.h:20
bool demoModeClicked
Definition: selectsupporteddevice.h:36