From 33d021dd7778172e6abbba72a379dd8eb3fd8671 Mon Sep 17 00:00:00 2001 From: Lubos Petrovic Date: Sun, 20 Dec 2020 15:52:38 +0100 Subject: [PATCH] pragma --- Board320_240.cpp | 6 +----- Board320_240.h | 5 +---- BoardInterface.cpp | 5 +---- BoardInterface.h | 5 +---- BoardM5stackCore.cpp | 5 +---- BoardM5stackCore.h | 5 +---- BoardTtgoT4v13.cpp | 5 +---- CarHyundaiIoniq.cpp | 5 +---- CarHyundaiIoniq.h | 5 +---- CarKiaDebugObd2.h | 5 +---- CarKiaEniro.h | 5 +---- CarKiaNiroPhev.h | 5 +---- 12 files changed, 12 insertions(+), 49 deletions(-) diff --git a/Board320_240.cpp b/Board320_240.cpp index d04a2a3..2c1270e 100644 --- a/Board320_240.cpp +++ b/Board320_240.cpp @@ -1,5 +1,4 @@ -#ifndef BOARD320_240_CPP -#define BOARD320_240_CPP +#pragma once #include #include @@ -30,7 +29,6 @@ void Board320_240::initBoard() { getLocalTime(&now, 0); liveData->params.chargingStartTime = liveData->params.currentTime = mktime(&now); - // Init display Serial.println("Init tft display"); tft.begin(); @@ -1456,5 +1454,3 @@ void Board320_240::syncGPS() { settimeofday(&now, NULL); } } - -#endif // BOARD320_240_CPP diff --git a/Board320_240.h b/Board320_240.h index f807797..7d04305 100644 --- a/Board320_240.h +++ b/Board320_240.h @@ -1,5 +1,4 @@ -#ifndef BOARD320_240_H -#define BOARD320_240_H +#pragma once // TFT COMMON #define LOAD_GLCD // Font 1. Original Adafruit 8 pixel font needs ~1820 bytes in FLASH @@ -77,5 +76,3 @@ class Board320_240 : public BoardInterface { void loadTestData(); // }; - -#endif // BOARD320_240_H diff --git a/BoardInterface.cpp b/BoardInterface.cpp index a73b745..2fc04ce 100644 --- a/BoardInterface.cpp +++ b/BoardInterface.cpp @@ -1,5 +1,4 @@ -#ifndef BOARDINTERFACE_CPP -#define BOARDINTERFACE_CPP +#pragma once #define ARDUINOJSON_USE_LONG_LONG 1 @@ -329,5 +328,3 @@ bool BoardInterface::serializeParamsToJson(File file, bool inclApiKey) { serializeJson(jsonData, Serial); serializeJson(jsonData, file); } - -#endif // BOARDINTERFACE_CPP diff --git a/BoardInterface.h b/BoardInterface.h index 3355b1b..1602014 100644 --- a/BoardInterface.h +++ b/BoardInterface.h @@ -1,5 +1,4 @@ -#ifndef BOARDINTERFACE_H -#define BOARDINTERFACE_H +#pragma once #include #include "LiveData.h" @@ -50,5 +49,3 @@ class BoardInterface { virtual void sdcardToggleRecording()=0; bool serializeParamsToJson(File file, bool inclApiKey = false); }; - -#endif // BOARDINTERFACE_H diff --git a/BoardM5stackCore.cpp b/BoardM5stackCore.cpp index 12bf0d9..e8bf6f8 100644 --- a/BoardM5stackCore.cpp +++ b/BoardM5stackCore.cpp @@ -1,5 +1,4 @@ -#ifndef BOARDM5STACKCORE_CPP -#define BOARDM5STACKCORE_CPP +#pragma once #include "BoardInterface.h" #include "Board320_240.h" @@ -34,5 +33,3 @@ void BoardM5stackCore::mainLoop() { Board320_240::mainLoop(); } - -#endif // BOARDM5STACKCORE_CPP diff --git a/BoardM5stackCore.h b/BoardM5stackCore.h index 93078f8..71732d1 100644 --- a/BoardM5stackCore.h +++ b/BoardM5stackCore.h @@ -1,5 +1,4 @@ -#ifndef BOARDM5STACKCORE_H -#define BOARDM5STACKCORE_H +#pragma once // Setup for m5stack core #define USER_SETUP_LOADED 1 @@ -42,5 +41,3 @@ class BoardM5stackCore : public Board320_240 { void initBoard() override; void mainLoop() override; }; - -#endif // BOARDM5STACKCORE_H diff --git a/BoardTtgoT4v13.cpp b/BoardTtgoT4v13.cpp index 4057a96..3d90adb 100644 --- a/BoardTtgoT4v13.cpp +++ b/BoardTtgoT4v13.cpp @@ -1,5 +1,4 @@ -#ifndef BOARDTTGOT4V13_CPP -#define BOARDTTGOT4V13_CPP +#pragma once #include "BoardInterface.h" #include "Board320_240.h" @@ -22,5 +21,3 @@ void BoardTtgoT4v13::initBoard() { Board320_240::initBoard(); } - -#endif // BOARDTTGOT4V13_CPP diff --git a/CarHyundaiIoniq.cpp b/CarHyundaiIoniq.cpp index 69f3e40..2b53ecb 100644 --- a/CarHyundaiIoniq.cpp +++ b/CarHyundaiIoniq.cpp @@ -1,5 +1,4 @@ -#ifndef CARHYUNDAIIONIQ_CPP -#define CARHYUNDAIIONIQ_CPP +#pragma once #include "CarHyundaiIoniq.h" @@ -377,5 +376,3 @@ void CarHyundaiIoniq::loadTestData() { */ } - -#endif //CARHYUNDAIIONIQ_CPP diff --git a/CarHyundaiIoniq.h b/CarHyundaiIoniq.h index 6a4cb01..6b296f8 100644 --- a/CarHyundaiIoniq.h +++ b/CarHyundaiIoniq.h @@ -1,5 +1,4 @@ -#ifndef CARHYUNDAIIONIQ_H -#define CARHYUNDAIIONIQ_H +#pragma once #include "CarInterface.h" @@ -12,5 +11,3 @@ class CarHyundaiIoniq : public CarInterface { void parseRowMerged() override; void loadTestData() override; }; - -#endif diff --git a/CarKiaDebugObd2.h b/CarKiaDebugObd2.h index 43b4282..b7a12c7 100644 --- a/CarKiaDebugObd2.h +++ b/CarKiaDebugObd2.h @@ -1,5 +1,4 @@ -#ifndef CARKIADEBUGOBD2_H -#define CARKIADEBUGOBD2_H +#pragma once #include "CarInterface.h" @@ -12,5 +11,3 @@ class CarKiaDebugObd2 : public CarInterface { void parseRowMerged() override; void loadTestData() override; }; - -#endif // CARKIADEBUGOBD2_H diff --git a/CarKiaEniro.h b/CarKiaEniro.h index b7f8033..9b1b92f 100644 --- a/CarKiaEniro.h +++ b/CarKiaEniro.h @@ -1,5 +1,4 @@ -#ifndef CARKIAENIRO_H -#define CARKIAENIRO_H +#pragma once #include "CarInterface.h" @@ -12,5 +11,3 @@ class CarKiaEniro : public CarInterface { void parseRowMerged() override; void loadTestData() override; }; - -#endif // CARKIAENIRO_H diff --git a/CarKiaNiroPhev.h b/CarKiaNiroPhev.h index 7c580a9..6fd7a80 100644 --- a/CarKiaNiroPhev.h +++ b/CarKiaNiroPhev.h @@ -1,5 +1,4 @@ -#ifndef CARKIANIROPHEV_H -#define CARKIANIROPHEV_H +#pragma once #include "CarInterface.h" @@ -12,5 +11,3 @@ class CarKiaNiroPhev: public CarInterface { void parseRowMerged() override; void loadTestData() override; }; - -#endif