Skip to content

Commit 10dead9

Browse files
authored
Merge pull request #223 from OpenBrickProtocolFoundation/update_wraps
Update wraps
2 parents ece7d31 + 5d7a072 commit 10dead9

File tree

147 files changed

+683
-555
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

147 files changed

+683
-555
lines changed

src/discord/core.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11

2+
#include "helper/spdlog_wrapper.hpp"
23
#include <core/helper/utils.hpp>
34

45
#include "./core.hpp"
56

67
#include <fmt/format.h>
7-
#include <spdlog/spdlog.h>
8-
98

109
[[nodiscard]] std::string constants::discord ::get_asset_key(constants::discord::ArtAsset asset) {
1110

src/discord/core.hpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
#include <core/helper/expected.hpp>
66
#include <core/helper/types.hpp>
77

8-
#include "../helper/windows.hpp"
8+
#include "../helper/export_symbols.hpp"
99

1010
#include <chrono>
1111
#ifdef _WIN32
@@ -58,7 +58,7 @@ namespace constants::discord {
5858
// manually synchronized to https://discord.com/developers/applications/1220147916371394650/rich-presence/assets
5959
enum class ArtAsset : u8 { Logo };
6060

61-
OOPETRIS_GRAPHICS_EXPORTED [[nodiscard]] std::string get_asset_key(ArtAsset asset);
61+
[[nodiscard]] OOPETRIS_GRAPHICS_EXPORTED std::string get_asset_key(ArtAsset asset);
6262

6363
} // namespace constants::discord
6464

@@ -116,7 +116,7 @@ struct DiscordActivityWrapper {
116116
}
117117

118118

119-
OOPETRIS_GRAPHICS_EXPORTED [[nodiscard]] const discordpp::Activity& get_raw() const;
119+
[[nodiscard]] OOPETRIS_GRAPHICS_EXPORTED const discordpp::Activity& get_raw() const;
120120
};
121121

122122
enum class DiscordStatus : u8 { Starting = 0, Ok, Error };
@@ -131,15 +131,15 @@ struct DiscordInstance {
131131
public:
132132
OOPETRIS_GRAPHICS_EXPORTED explicit DiscordInstance();
133133

134-
OOPETRIS_GRAPHICS_EXPORTED [[nodiscard]] DiscordStatus get_status();
134+
[[nodiscard]] OOPETRIS_GRAPHICS_EXPORTED DiscordStatus get_status();
135135

136136
OOPETRIS_GRAPHICS_EXPORTED DiscordInstance(DiscordInstance&& old) noexcept;
137137

138138
OOPETRIS_GRAPHICS_EXPORTED DiscordInstance& operator=(DiscordInstance&& other) noexcept;
139139

140-
OOPETRIS_GRAPHICS_EXPORTED DiscordInstance(DiscordInstance& old) noexcept = delete;
140+
DiscordInstance(DiscordInstance& old) noexcept = delete;
141141

142-
OOPETRIS_GRAPHICS_EXPORTED DiscordInstance& operator=(const DiscordInstance& other) noexcept = delete;
142+
DiscordInstance& operator=(const DiscordInstance& other) noexcept = delete;
143143

144144
OOPETRIS_GRAPHICS_EXPORTED ~DiscordInstance();
145145

src/executables/game/application.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
#include "ui/layout.hpp"
1212

1313

14+
#include "helper/spdlog_wrapper.hpp"
1415
#include <fmt/chrono.h>
1516
#include <memory>
1617
#include <ranges>

src/executables/game/main.cpp

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,21 @@
2828
#include "helper/web_utils.hpp"
2929
#endif
3030

31+
32+
#if defined(_MSC_VER)
33+
#pragma warning(disable : 4275)
34+
#pragma warning(disable : 4251)
35+
#endif
36+
3137
#include <spdlog/sinks/basic_file_sink.h>
3238
#include <spdlog/sinks/rotating_file_sink.h>
3339
#include <spdlog/sinks/stdout_sinks.h>
40+
#include <spdlog/spdlog.h>
3441

42+
#if defined(_MSC_VER)
43+
#pragma warning(default : 4275)
44+
#pragma warning(default : 4251)
45+
#endif
3546

3647
namespace {
3748
void initialize_spdlog() {

src/executables/game/parser.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99
#include "helper/graphic_utils.hpp"
1010

1111

12+
#include "helper/spdlog_wrapper.hpp"
1213
#include <argparse/argparse.hpp>
13-
#include <spdlog/spdlog.h>
1414

1515

1616
helper::expected<CommandLineArguments, std::string> helper::parse_args(const std::vector<std::string>& arguments) {

src/game/bag.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#include <core/game/tetromino_type.hpp>
44
#include <core/helper/random.hpp>
55

6-
#include "../helper/windows.hpp"
6+
#include "../helper/export_symbols.hpp"
77
#include <array>
88

99
struct Bag final {

src/game/command_line_arguments.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
#include <core/helper/types.hpp>
77
#include <core/helper/utils.hpp>
88

9-
#include "../helper/windows.hpp"
9+
#include "../helper/export_symbols.hpp"
1010

1111
#include <filesystem>
1212
#include <optional>

src/game/game.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11

2+
#include "helper/spdlog_wrapper.hpp"
23
#include <core/helper/magic_enum_wrapper.hpp>
34
#include <core/helper/utils.hpp>
45

src/game/game.hpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#include <recordings/utility/recording.hpp>
44

55
#include "helper/clock_source.hpp"
6-
#include "helper/windows.hpp"
6+
#include "helper/export_symbols.hpp"
77
#include "input/input_creator.hpp"
88
#include "tetrion.hpp"
99
#include "ui/widget.hpp"
@@ -32,14 +32,14 @@ struct Game : public ui::Widget {
3232

3333
OOPETRIS_GRAPHICS_EXPORTED void render(const ServiceProvider& service_provider) const override;
3434

35-
OOPETRIS_GRAPHICS_EXPORTED [[nodiscard]] Widget::EventHandleResult
35+
[[nodiscard]] OOPETRIS_GRAPHICS_EXPORTED Widget::EventHandleResult
3636
handle_event(const std::shared_ptr<input::InputManager>& input_manager, const SDL_Event& event) override;
3737

3838
OOPETRIS_GRAPHICS_EXPORTED void set_paused(bool paused);
3939

40-
OOPETRIS_GRAPHICS_EXPORTED [[nodiscard]] bool is_paused() const;
40+
[[nodiscard]] OOPETRIS_GRAPHICS_EXPORTED bool is_paused() const;
4141

42-
OOPETRIS_GRAPHICS_EXPORTED [[nodiscard]] bool is_game_finished() const;
42+
[[nodiscard]] OOPETRIS_GRAPHICS_EXPORTED bool is_game_finished() const;
4343

44-
OOPETRIS_GRAPHICS_EXPORTED [[nodiscard]] const std::shared_ptr<input::GameInput>& game_input() const;
44+
[[nodiscard]] OOPETRIS_GRAPHICS_EXPORTED const std::shared_ptr<input::GameInput>& game_input() const;
4545
};

src/game/graphic_helpers.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
#include <core/core.hpp>
44

5-
#include "helper/windows.hpp"
5+
#include "helper/export_symbols.hpp"
66
#include "manager/service_provider.hpp"
77

88
enum class MinoTransparency : u8 {

0 commit comments

Comments
 (0)