projects
/
pulseview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Make member variable underscores a suffix instead of a prefix
[pulseview.git]
/
pv
/
dialogs
/
connect.h
diff --git
a/pv/dialogs/connect.h
b/pv/dialogs/connect.h
index eeb108c105dd5a4c28edaf4e658ed10fa2e137f6..b46da06fdfc28ce55645323750b94e5a95dc7a69 100644
(file)
--- a/
pv/dialogs/connect.h
+++ b/
pv/dialogs/connect.h
@@
-21,6
+21,8
@@
#ifndef PULSEVIEW_PV_CONNECT_H
#define PULSEVIEW_PV_CONNECT_H
#ifndef PULSEVIEW_PV_CONNECT_H
#define PULSEVIEW_PV_CONNECT_H
+#include <memory>
+
#include <QComboBox>
#include <QDialog>
#include <QDialogButtonBox>
#include <QComboBox>
#include <QDialog>
#include <QDialogButtonBox>
@@
-30,10
+32,18
@@
#include <QPushButton>
#include <QVBoxLayout>
#include <QPushButton>
#include <QVBoxLayout>
-struct sr_config;
-struct sr_dev_inst;
+namespace sigrok {
+ class Driver;
+ class HardwareDevice;
+}
+
+Q_DECLARE_METATYPE(std::shared_ptr<sigrok::Driver>);
+Q_DECLARE_METATYPE(std::shared_ptr<sigrok::HardwareDevice>);
namespace pv {
namespace pv {
+
+class DeviceManager;
+
namespace dialogs {
class Connect : public QDialog
namespace dialogs {
class Connect : public QDialog
@@
-41,9
+51,9
@@
class Connect : public QDialog
Q_OBJECT
public:
Q_OBJECT
public:
- Connect(QWidget *parent);
+ Connect(QWidget *parent
, pv::DeviceManager &device_manager
);
- st
ruct sr_dev_inst*
get_selected_device() const;
+ st
d::shared_ptr<sigrok::HardwareDevice>
get_selected_device() const;
private:
void populate_drivers();
private:
void populate_drivers();
@@
-52,28
+62,27
@@
private:
void set_serial_connection();
void set_serial_connection();
-private
slots
:
+private
Q_SLOTS
:
void device_selected(int index);
void scan_pressed();
private:
void device_selected(int index);
void scan_pressed();
private:
-
static void free_drvopts(sr_config *src)
;
+
pv::DeviceManager &device_manager_
;
-private:
- QVBoxLayout _layout;
+ QVBoxLayout layout_;
- QWidget
_form
;
- QFormLayout
_form_layout
;
+ QWidget
form_
;
+ QFormLayout
form_layout_
;
- QComboBox
_drivers
;
+ QComboBox
drivers_
;
- QLineEdit
_serial_device
;
+ QLineEdit
serial_device_
;
- QPushButton
_scan_button
;
- QListWidget
_device_list
;
+ QPushButton
scan_button_
;
+ QListWidget
device_list_
;
- QDialogButtonBox
_button_box
;
+ QDialogButtonBox
button_box_
;
};
} // namespace dialogs
};
} // namespace dialogs