OpenHantek
Toggle main menu visibility
Loading...
Searching...
No Matches
selectsupporteddevice.h
Go to the documentation of this file.
1
// SPDX-License-Identifier: GPL-2.0-or-later
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,
int
verboseLevel
= 0,
bool
autoConnect =
true
);
29
void
showLibUSBFailedDialogModel
(
int
error );
30
31
private
:
32
void
updateDeviceList
();
33
void
updateSupportedDevices
();
34
std::unique_ptr< Ui::SelectSupportedDevice >
ui
;
35
UniqueUSBid
selectedDevice
= 0;
36
bool
demoModeClicked
=
false
;
37
int
verboseLevel
= 0;
38
QPushButton *
btnDemoMode
;
39
};
SelectSupportedDevice::btnDemoMode
QPushButton * btnDemoMode
Definition
selectsupporteddevice.h:38
SelectSupportedDevice::selectedDevice
UniqueUSBid selectedDevice
Definition
selectsupporteddevice.h:35
SelectSupportedDevice::SelectSupportedDevice
SelectSupportedDevice(QWidget *parent=nullptr)
Definition
selectsupporteddevice.cpp:20
SelectSupportedDevice::ui
std::unique_ptr< Ui::SelectSupportedDevice > ui
Definition
selectsupporteddevice.h:34
SelectSupportedDevice::showLibUSBFailedDialogModel
void showLibUSBFailedDialogModel(int error)
Definition
selectsupporteddevice.cpp:164
SelectSupportedDevice::demoModeClicked
bool demoModeClicked
Definition
selectsupporteddevice.h:36
SelectSupportedDevice::updateDeviceList
void updateDeviceList()
SelectSupportedDevice::showSelectDeviceModal
std::unique_ptr< ScopeDevice > showSelectDeviceModal(libusb_context *context, int verboseLevel=0, bool autoConnect=true)
Definition
selectsupporteddevice.cpp:48
SelectSupportedDevice::updateSupportedDevices
void updateSupportedDevices()
Definition
selectsupporteddevice.cpp:173
SelectSupportedDevice::verboseLevel
int verboseLevel
Definition
selectsupporteddevice.h:37
scopedevice.h
UniqueUSBid
uint64_t UniqueUSBid
Definition
scopedevice.h:22
selectdevice
selectsupporteddevice.h
Generated by
1.17.0