Skip to content

Commit 2a7dd1e

Browse files
committed
disp/vulkan_sdl3: Make state a rule of zero class
1 parent 1f8013c commit 2a7dd1e

1 file changed

Lines changed: 5 additions & 12 deletions

File tree

src/video_display/vulkan/vulkan_sdl3.cpp

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,11 @@ struct FrameMappings{
154154
};
155155

156156
struct state_vulkan_sdl3 {
157+
explicit state_vulkan_sdl3(module* parent): mod(MODULE_CLASS_DATA, parent, this, display_vulkan_new_message) {
158+
sdl_user_new_message_event = SDL_RegisterEvents(1);
159+
assert(sdl_user_new_message_event != 0);
160+
}
161+
157162
const uint32_t magic = magic_vulkan_sdl3;
158163
module_raii mod;
159164

@@ -178,18 +183,6 @@ struct state_vulkan_sdl3 {
178183

179184
std::atomic<bool> should_exit = false;
180185
video_desc current_desc{};
181-
182-
explicit state_vulkan_sdl3(module* parent): mod(MODULE_CLASS_DATA, parent, this, display_vulkan_new_message) {
183-
sdl_user_new_message_event = SDL_RegisterEvents(1);
184-
assert(sdl_user_new_message_event != 0);
185-
}
186-
187-
state_vulkan_sdl3(const state_vulkan_sdl3& other) = delete;
188-
state_vulkan_sdl3& operator=(const state_vulkan_sdl3& other) = delete;
189-
state_vulkan_sdl3(state_vulkan_sdl3&& other) = delete;
190-
state_vulkan_sdl3& operator=(state_vulkan_sdl3&& other) = delete;
191-
192-
~state_vulkan_sdl3() = default;
193186
};
194187

195188
constexpr std::pair<int64_t, std::string_view> display_vulkan_keybindings[] = {

0 commit comments

Comments
 (0)