Switch to #pragma once because fuck you here's why

This commit is contained in:
Stepland 2022-03-02 23:59:19 +01:00
parent 79e655cf5e
commit 204609c4d0
21 changed files with 24 additions and 88 deletions

View File

@ -1,5 +1,4 @@
#ifndef FEIS_CHART_H
#define FEIS_CHART_H
#pragma once
#include <iostream>
#include <set>
@ -33,5 +32,3 @@ public:
private:
int resolution;
};
#endif // FEIS_CHART_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_CHARTWITHHIST_H
#define FEIS_CHARTWITHHIST_H
#pragma once
#include "chart.hpp"
#include "history.hpp"
@ -24,5 +23,3 @@ struct Chart_with_History {
std::optional<Note> makeLongNoteDummy(int current_tick) const;
std::optional<Note> makeCurrentLongNote() const;
};
#endif // FEIS_CHARTWITHHIST_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_EDITORSTATE_H
#define FEIS_EDITORSTATE_H
#pragma once
#include <SFML/Audio.hpp>
#include <SFML/Graphics.hpp>
@ -173,5 +172,3 @@ namespace ESHelper {
bool showCustomDifName = false;
};
}
#endif // FEIS_EDITORSTATE_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_FUMEN_H
#define FEIS_FUMEN_H
#pragma once
#include <filesystem>
#include <fstream>
@ -56,5 +55,3 @@ public:
float getChartRuntime(Chart c);
};
#endif // FEIS_FUMEN_H

View File

@ -1,7 +1,4 @@
#ifndef FEIS_HISTORYSTATE_H
#define FEIS_HISTORYSTATE_H
#pragma once
#include <memory>
#include <string>
@ -60,5 +57,3 @@ protected:
};
std::string get_message(const std::shared_ptr<ActionWithMessage>& awm);
#endif // FEIS_HISTORYSTATE_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_IMGUI_CUSTOM_H
#define FEIS_IMGUI_CUSTOM_H
#pragma once
#include <SFML/Graphics/Color.hpp>
#include <imgui-SFML_export.h>
@ -9,5 +8,3 @@
namespace ImGui {
IMGUI_SFML_API bool ColorEdit4(const char* label, sf::Color& col, ImGuiColorEditFlags flags = 0);
}
#endif // FEIS_IMGUI_CUSTOM_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_LNMARKER_H
#define FEIS_LNMARKER_H
#pragma once
#include <SFML/Graphics/RenderTexture.hpp>
#include <SFML/Graphics/Sprite.hpp>
@ -73,5 +72,3 @@ private:
}
}
};
#endif // FEIS_LNMARKER_H

View File

@ -1,5 +1,5 @@
#ifndef FEIS_MARKER_H
#define FEIS_MARKER_H
#pragma once
#include <SFML/Graphics.hpp>
#include <cmath>
#include <filesystem>
@ -51,5 +51,3 @@ private:
};
Marker first_available_marker_from_folder(std::filesystem::path assets_folder);
#endif // FEIS_MARKER_H

View File

@ -13,8 +13,7 @@
// based chart validation. since it removes the need for a fancy consistency
// check between the note and its tail positions
#ifndef FEIS_NOTE_H
#define FEIS_NOTE_H
#pragma once
/*
* A Note has :
@ -75,5 +74,3 @@ private:
void initAsClosestLongNote(const Note& start, int end_timing, int wanted_tail_pos);
};
#endif // FEIS_NOTE_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_NOTESCLIPBOARD_H
#define FEIS_NOTESCLIPBOARD_H
#pragma once
#include <set>
@ -17,5 +16,3 @@ public:
private:
std::set<Note> contents;
};
#endif // FEIS_NOTESCLIPBOARD_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_NOTIFICATION_H
#define FEIS_NOTIFICATION_H
#pragma once
#include <string>
@ -55,5 +54,3 @@ public:
const std::string message;
};
#endif // FEIS_NOTIFICATION_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_NOTIFICATIONSQUEUE_H
#define FEIS_NOTIFICATIONSQUEUE_H
#pragma once
#include <SFML/System.hpp>
#include <deque>
@ -26,5 +25,3 @@ private:
const unsigned int max_size;
std::deque<std::shared_ptr<Notification>> queue;
};
#endif // FEIS_NOTIFICATIONSQUEUE_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_PRECISE_MUSIC_H
#define FEIS_PRECISE_MUSIC_H
#pragma once
#include <filesystem>
#include <array>
@ -18,5 +17,3 @@ struct PreciseMusic : sf::Music {
protected:
LPALGETSOURCEDVSOFT alGetSourcedvSOFT;
};
#endif // FEIS_PRECISE_MUSIC_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_PREFERENCES_H
#define FEIS_PREFERENCES_H
#pragma once
#include <filesystem>
#include <fstream>
@ -21,5 +20,3 @@ public:
MarkerEndingState markerEndingState;
const std::filesystem::path file_path;
};
#endif // FEIS_PREFERENCES_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_SOUNDEFFECT_H
#define FEIS_SOUNDEFFECT_H
#pragma once
#include <SFML/Audio.hpp>
#include <filesystem>
@ -32,5 +31,3 @@ private:
sf::Sound sound;
int volume;
};
#endif // FEIS_SOUNDEFFECT_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_TIMESELECTION_H
#define FEIS_TIMESELECTION_H
#pragma once
#include <variant>
@ -13,5 +12,3 @@ struct TimeSelection {
};
typedef std::variant<std::monostate, unsigned int, TimeSelection> SelectionState;
#endif // FEIS_TIMESELECTION_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_TOOLBOX_H
#define FEIS_TOOLBOX_H
#pragma once
#define IM_MAX(_A, _B) (((_A) >= (_B)) ? (_A) : (_B))
@ -98,5 +97,3 @@ private:
T low_output;
T high_output;
};
#endif // FEIS_TOOLBOX_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_BLANKSCREEN_H
#define FEIS_BLANKSCREEN_H
#pragma once
#include <SFML/Graphics.hpp>
@ -15,5 +14,3 @@ private:
sf::Texture tex_FEIS_logo;
sf::Sprite FEIS_logo;
};
#endif // FEIS_BLANKSCREEN_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_DENSITYGRAPH_H
#define FEIS_DENSITYGRAPH_H
#pragma once
#include <SFML/Graphics.hpp>
#include <imgui-SFML.h>
@ -37,5 +36,3 @@ private:
void computeDensities(int height, float chartRuntime, Chart& chart, float BPM, int resolution);
void updateGraphTexture();
};
#endif // FEIS_DENSITYGRAPH_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_LINEARVIEW_H
#define FEIS_LINEARVIEW_H
#pragma once
#include <SFML/Graphics.hpp>
#include <cmath>
@ -63,5 +62,3 @@ private:
int zoom = 0;
const std::filesystem::path font_path;
};
#endif // FEIS_LINEARVIEW_H

View File

@ -1,5 +1,4 @@
#ifndef FEIS_PLAYFIELD_H
#define FEIS_PLAYFIELD_H
#pragma once
#include <SFML/Graphics.hpp>
#include <imgui-SFML.h>
@ -50,5 +49,3 @@ public:
private:
const std::filesystem::path texture_path;
};
#endif // FEIS_PLAYFIELD_H