diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2018-06-22 12:54:47 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2018-06-26 23:01:53 +0200 |
commit | f50ac3549d6a7f1199fa012e4b03f581bc8d305b (patch) | |
tree | 50ff044f1c618119c88544709808f533ed02225e /gui | |
parent | d61eb905ae3fa161d50821d01ee47915713e89c2 (diff) |
core, modules: modernize syntax only
Use more C++17 features where this helps any.
Diffstat (limited to 'gui')
-rw-r--r-- | gui/keyboard.h | 2 | ||||
-rw-r--r-- | gui/mapping-dialog.cpp | 2 | ||||
-rw-r--r-- | gui/mapping-dialog.hpp | 4 | ||||
-rw-r--r-- | gui/process_detector.cpp | 1 | ||||
-rw-r--r-- | gui/process_detector.h | 1 | ||||
-rw-r--r-- | gui/settings.cpp | 2 |
6 files changed, 6 insertions, 6 deletions
diff --git a/gui/keyboard.h b/gui/keyboard.h index c17a7bad..19d29e75 100644 --- a/gui/keyboard.h +++ b/gui/keyboard.h @@ -17,7 +17,7 @@ #include "ui_keyboard_listener.h" #include <QDialog> -#include <QKeyEvent> +#include <QtEvents> class OTR_GUI_EXPORT keyboard_listener : public QDialog { diff --git a/gui/mapping-dialog.cpp b/gui/mapping-dialog.cpp index d4f8a1d4..43130a92 100644 --- a/gui/mapping-dialog.cpp +++ b/gui/mapping-dialog.cpp @@ -10,6 +10,8 @@ #include "logic/main-settings.hpp" #include "spline/spline-widget.hpp" +#include <QtEvents> + mapping_dialog::mapping_dialog(Mappings& m) : m(m), widgets{} { ui.setupUi(this); diff --git a/gui/mapping-dialog.hpp b/gui/mapping-dialog.hpp index 23edb696..09170c62 100644 --- a/gui/mapping-dialog.hpp +++ b/gui/mapping-dialog.hpp @@ -8,9 +8,7 @@ #include <QWidget> #include <QDialog> -#include <QShowEvent> -#include <QCloseEvent> -#include <QCheckBox> +#include <QtEvents> class OTR_GUI_EXPORT mapping_dialog final : public QDialog { diff --git a/gui/process_detector.cpp b/gui/process_detector.cpp index b29df7fb..7563d521 100644 --- a/gui/process_detector.cpp +++ b/gui/process_detector.cpp @@ -18,6 +18,7 @@ #include <QHash> #include <QPushButton> #include <QSettings> +#include <QtEvents> static constexpr inline auto RECORD_SEPARATOR = QChar(char(0x1e)); // RS ^] static constexpr inline auto UNIT_SEPARATOR = QChar(char(0x1f)); // US ^_ diff --git a/gui/process_detector.h b/gui/process_detector.h index 393dafb3..c3ff078a 100644 --- a/gui/process_detector.h +++ b/gui/process_detector.h @@ -13,7 +13,6 @@ #include <QObject> #include <QWidget> #include <QTableWidget> -#include <QResizeEvent> #include "gui/ui_process_widget.h" #include "process-detector-fancy-table.hpp" diff --git a/gui/settings.cpp b/gui/settings.cpp index fc7cde19..ee0e9959 100644 --- a/gui/settings.cpp +++ b/gui/settings.cpp @@ -151,7 +151,7 @@ options_dialog::options_dialog(std::function<void(bool)> pause_keybindings) : val.label, [=](const QString&) { val.label->setText(kopts_to_string(val.opt)); }); { - connect(val.button, &QPushButton::clicked, this, [=]() { bind_key(val.opt, val.label); }); + connect(val.button, &QPushButton::clicked, this, [=] { bind_key(val.opt, val.label); }); } } } |