refactor: remove innclude guards, use pragma instead

This commit is contained in:
2024-03-28 03:05:26 +02:00
parent f27050afbc
commit 0bcceefd47
97 changed files with 186 additions and 551 deletions

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef ABSTRACTEXTITEM_H
#define ABSTRACTEXTITEM_H
#pragma once
#include <QVariant>
@ -102,6 +101,3 @@ private:
QLocalServer *m_socket = nullptr;
QString m_socketFile = "";
};
#endif /* ABSTRACTEXTITEM_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef ABSTRACTEXTITEMAGGREGATOR_H
#define ABSTRACTEXTITEMAGGREGATOR_H
#pragma once
#include <QStandardPaths>
@ -80,6 +79,3 @@ private:
// ui methods
virtual void doCreateItem(QListWidget *_widget) = 0;
};
#endif /* ABSTRACTEXTITEMAGGREGATOR_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef ABSTRACTQUOTESPROVIDER_H
#define ABSTRACTQUOTESPROVIDER_H
#pragma once
#include <QObject>
#include <QUrl>
@ -40,6 +39,3 @@ public:
};
[[nodiscard]] virtual QUrl url() const = 0;
};
#endif /* ABSTRACTQUOTESPROVIDER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef ABSTRACTWEATHERPROVIDER_H
#define ABSTRACTWEATHERPROVIDER_H
#pragma once
#include <QObject>
#include <QUrl>
@ -40,6 +39,3 @@ public:
};
[[nodiscard]] virtual QUrl url() const = 0;
};
#endif /* ABSTRACTWEATHERPROVIDER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef AWABSTRACTFORMATTER_H
#define AWABSTRACTFORMATTER_H
#pragma once
#include <QRegularExpression>
@ -52,6 +51,3 @@ private:
// properties
FormatterClass m_type = FormatterClass::NoFormat;
};
#endif /* AWABSTRACTFORMATTER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef AWDATETIMEFORMATTER_H
#define AWDATETIMEFORMATTER_H
#pragma once
#include <QLocale>
@ -52,6 +51,3 @@ private:
QString m_format = "";
bool m_translate = true;
};
#endif /* AWDATETIMEFORMATTER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef AWFLOATFORMATTER_H
#define AWFLOATFORMATTER_H
#pragma once
#include "awabstractformatter.h"
@ -68,6 +67,3 @@ private:
int m_precision = -1;
double m_summand = 0.0;
};
#endif /* AWFLOATFORMATTER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef AWJSONFORMATTER_H
#define AWJSONFORMATTER_H
#pragma once
#include "awabstractformatter.h"
@ -49,6 +48,3 @@ private:
QString m_path;
QVariantList m_splittedPath;
};
#endif /* AWJSONFORMATTER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef AWLISTFORMATTER_H
#define AWLISTFORMATTER_H
#pragma once
#include "awabstractformatter.h"
@ -53,6 +52,3 @@ private:
bool m_sorted = false;
QRegularExpression m_regex;
};
#endif /* AWLISTFORMATTER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef AWNOFORMATTER_H
#define AWNOFORMATTER_H
#pragma once
#include "awabstractformatter.h"
@ -37,6 +36,3 @@ private:
void translate(void *_ui) override;
// properties
};
#endif /* AWNOFORMATTER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef AWSCRIPTFORMATTER_H
#define AWSCRIPTFORMATTER_H
#pragma once
#include "awabstractformatter.h"
@ -56,6 +55,3 @@ private:
bool m_hasReturn = false;
QString m_program;
};
#endif /* AWSCRIPTFORMATTER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef AWSTRINGFORMATTER_H
#define AWSTRINGFORMATTER_H
#pragma once
#include "awabstractformatter.h"
@ -52,6 +51,3 @@ private:
QChar m_fillChar = QChar();
bool m_forceWidth = false;
};
#endif /* AWSTRINGFORMATTER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef EXTITEMAGGREGATOR_H
#define EXTITEMAGGREGATOR_H
#pragma once
#include <KI18n/KLocalizedString>
@ -150,6 +149,3 @@ private:
return items;
};
};
#endif /* EXTITEMAGGREGATOR_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef EXTNETWORKREQUEST_H
#define EXTNETWORKREQUEST_H
#pragma once
#include <QNetworkReply>
@ -59,6 +58,3 @@ private:
// values
QVariantHash m_values;
};
#endif /* EXTNETWORKREQUEST_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef EXTQUOTES_H
#define EXTQUOTES_H
#pragma once
#include <QNetworkReply>
@ -61,6 +60,3 @@ private:
// values
QVariantHash m_values;
};
#endif /* EXTQUOTES_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef EXTSCRIPT_H
#define EXTSCRIPT_H
#pragma once
#include <QProcess>
@ -76,6 +75,3 @@ private:
QVariantMap m_jsonFilters;
QVariantHash m_values;
};
#endif /* EXTSCRIPT_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef EXTUPGRADE_H
#define EXTUPGRADE_H
#pragma once
#include <QProcess>
@ -64,6 +63,3 @@ private:
// internal properties
QVariantHash m_values;
};
#endif /* EXTUPGRADE_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef EXTWEATHER_H
#define EXTWEATHER_H
#pragma once
#include <QNetworkReply>
@ -90,6 +89,3 @@ private:
// values
QVariantHash m_values;
};
#endif /* EXTWEATHER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef GRAPHICALITEM_H
#define GRAPHICALITEM_H
#pragma once
#include <QColor>
@ -118,6 +117,3 @@ private:
QStringList m_usedKeys;
int m_width = 100;
};
#endif /* GRAPHICALITEM_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef GRAPHICALITEMHELPER_H
#define GRAPHICALITEMHELPER_H
#pragma once
#include <QColor>
#include <QObject>
@ -56,6 +55,3 @@ private:
// list of values which will be used to store data for graph type only
QList<float> m_values;
};
#endif /* GRAPHICALITEMHELPER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef OWMWEATHERPROVIDER_H
#define OWMWEATHERPROVIDER_H
#pragma once
#include "abstractweatherprovider.h"
@ -42,6 +41,3 @@ private:
int m_ts = 0;
QUrl m_url;
};
#endif /* OWMWEATHERPROVIDER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef QCRONSCHEDULER_H
#define QCRONSCHEDULER_H
#pragma once
#include "QObject"
@ -58,6 +57,3 @@ private:
QTimer *m_timer = nullptr;
static QList<int> parseField(const QString &_value, int _min, int _max);
};
#endif /* QCRONSCHEDULER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef STOOQQUOTESPROVIDER_H
#define STOOQQUOTESPROVIDER_H
#pragma once
#include "abstractquotesprovider.h"
@ -37,6 +36,3 @@ public:
private:
QUrl m_url;
};
#endif /* STOOQQUOTESPROVIDER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef YAHOOQUOTESPROVIDER_H
#define YAHOOQUOTESPROVIDER_H
#pragma once
#include "abstractquotesprovider.h"
@ -38,6 +37,3 @@ public:
private:
QUrl m_url;
};
#endif /* YAHOOQUOTESPROVIDER_H */

View File

@ -15,8 +15,7 @@
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
***************************************************************************/
#ifndef YAHOOWEATHERPROVIDER_H
#define YAHOOWEATHERPROVIDER_H
#pragma once
#include "abstractweatherprovider.h"
@ -43,6 +42,3 @@ private:
int m_ts = 0;
QUrl m_url;
};
#endif /* YAHOOWEATHERPROVIDER_H */