summaryrefslogtreecommitdiff
path: root/ui/qt5
diff options
context:
space:
mode:
authorA. Wilcox <AWilcox@Wilcox-Tech.com>2019-11-09 22:33:09 -0600
committerA. Wilcox <AWilcox@Wilcox-Tech.com>2019-11-09 22:33:09 -0600
commitb1614829b5ea99db3c6768dcf704a1b67c40cc73 (patch)
treed323c4f0c3901397be556db43427a0843116ebbf /ui/qt5
parentf879356affc02c2346f95f1073ce3e0be9e8f3bf (diff)
downloadhorizon-b1614829b5ea99db3c6768dcf704a1b67c40cc73.tar.gz
horizon-b1614829b5ea99db3c6768dcf704a1b67c40cc73.tar.bz2
horizon-b1614829b5ea99db3c6768dcf704a1b67c40cc73.tar.xz
horizon-b1614829b5ea99db3c6768dcf704a1b67c40cc73.zip
Qt UI: Fix up NetworkingPage to fit with modern style
Diffstat (limited to 'ui/qt5')
-rw-r--r--ui/qt5/networkingpage.cc25
-rw-r--r--ui/qt5/networkingpage.hh16
2 files changed, 30 insertions, 11 deletions
diff --git a/ui/qt5/networkingpage.cc b/ui/qt5/networkingpage.cc
index 140e9af..eb8d883 100644
--- a/ui/qt5/networkingpage.cc
+++ b/ui/qt5/networkingpage.cc
@@ -1,12 +1,22 @@
+/*
+ * networkingpage.cc - Implementation of the UI.Network.AddressType page
+ * horizon-qt5, the Qt 5 user interface for
+ * Project Horizon
+ *
+ * Copyright (c) 2019 Adélie Linux and contributors. All rights reserved.
+ * This code is licensed under the AGPL 3.0 license, as noted in the
+ * LICENSE-code file in the root directory of this repository.
+ *
+ * SPDX-License-Identifier: AGPL-3.0-only
+ */
+
#include "networkingpage.hh"
#include "horizonwizard.hh"
-#include <cstdint>
#include <QLabel>
#include <QVBoxLayout>
-NetworkingPage::NetworkingPage(QWidget *parent) : HorizonWizardPage(parent)
-{
+NetworkingPage::NetworkingPage(QWidget *parent) : HorizonWizardPage(parent) {
QLabel *descLabel;
QVBoxLayout *layout;
@@ -35,7 +45,7 @@ NetworkingPage::NetworkingPage(QWidget *parent) : HorizonWizardPage(parent)
radioGroup->addButton(skip);
QObject::connect(radioGroup, static_cast<void (QButtonGroup:: *)(QAbstractButton *)>(&QButtonGroup::buttonClicked),
- [=](QAbstractButton *button __attribute__((unused))) {
+ [=](QAbstractButton *) {
emit completeChanged();
});
@@ -48,15 +58,12 @@ NetworkingPage::NetworkingPage(QWidget *parent) : HorizonWizardPage(parent)
setLayout(layout);
}
-bool NetworkingPage::isComplete() const
-{
+bool NetworkingPage::isComplete() const {
return (radioGroup->checkedButton() != nullptr);
}
-int NetworkingPage::nextId() const
-{
+int NetworkingPage::nextId() const {
if(radioGroup->checkedButton() == simple) {
- /* determine wifi */
if(false) {
return HorizonWizard::Page_Network_Wireless;
} else {
diff --git a/ui/qt5/networkingpage.hh b/ui/qt5/networkingpage.hh
index 3353fb6..5914af2 100644
--- a/ui/qt5/networkingpage.hh
+++ b/ui/qt5/networkingpage.hh
@@ -1,3 +1,15 @@
+/*
+ * networkingpage.hh - Definition of the UI.Network.AddressType page
+ * horizon-qt5, the Qt 5 user interface for
+ * Project Horizon
+ *
+ * Copyright (c) 2019 Adélie Linux and contributors. All rights reserved.
+ * This code is licensed under the AGPL 3.0 license, as noted in the
+ * LICENSE-code file in the root directory of this repository.
+ *
+ * SPDX-License-Identifier: AGPL-3.0-only
+ */
+
#ifndef NETWORKINGPAGE_HH
#define NETWORKINGPAGE_HH
@@ -8,7 +20,7 @@
class NetworkingPage : public HorizonWizardPage {
public:
- NetworkingPage(QWidget *parent = 0);
+ NetworkingPage(QWidget *parent = nullptr);
bool isComplete() const;
int nextId() const;
@@ -17,4 +29,4 @@ private:
QRadioButton *simple, *advanced, *skip;
};
-#endif // NETWORKINGPAGE_HH
+#endif /* !NETWORKINGPAGE_HH */