Skip to content

Commit

Permalink
Cleanup std includes
Browse files Browse the repository at this point in the history
  • Loading branch information
tobiashienzsch committed Sep 30, 2023
1 parent 4ce0159 commit 733d85a
Show file tree
Hide file tree
Showing 7 changed files with 23 additions and 25 deletions.
5 changes: 2 additions & 3 deletions example/app-sdl/main.cpp
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
#include <stdbool.h>
#include <stdio.h>

#include <cairo/cairo.h>
#include <SDL2/SDL.h>

#include <cstdio>

int main(int argc, char* argv[])
{
SDL_Init(SDL_INIT_VIDEO);
Expand Down
2 changes: 1 addition & 1 deletion example/app/main.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#include <cstdio>
#include <iostream>
#include <stdio.h>
#include <vector>

#include "bindings/imgui_impl_glfw.h"
Expand Down
2 changes: 1 addition & 1 deletion example/plugin-imgui/src/audio_plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

#include "audio_plugin.hpp"

#include <string.h>
#include <cstring>

clap_host const* clapHost;
extern clap_plugin_timer_support guiTimerSupport;
Expand Down
10 changes: 5 additions & 5 deletions example/plugin-imgui/src/gain_plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@

#include "gain_plugin.hpp"

#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>

#include "imgui.h"

#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <cstring>

static const clap_param_info _param_info[GainPlugin::NUM_PARAMS] = {
{0, CLAP_PARAM_REQUIRES_PROCESS, nullptr, "Volume", "", -60.0, 12.0, 0.0},
{1, CLAP_PARAM_REQUIRES_PROCESS, nullptr, "Pan", "", -100.0, 100.0, 0.0}
Expand Down
6 changes: 3 additions & 3 deletions example/plugin-imgui/src/gui.cpp
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
// generic ui functions.
// plugin implementations that use imgui should not need to touch this file.

#include <stdio.h>
#include <string.h>

#include "audio_plugin.hpp"

#include <cstdio>
#include <cstring>

bool AudioPlugin::createUI(char const* api, bool is_floating)
{
return isApiSupported(api, is_floating);
Expand Down
11 changes: 5 additions & 6 deletions example/plugin-imgui/src/main_clap.cpp
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
#include <cstdlib>
#include <stdint.h>
#include <string.h>

#include <string_view>

#if defined _WIN32
#include <windows.h>
HINSTANCE g_hinst;
#endif

#include "gain_plugin.hpp"

#include <cstdint>
#include <cstdlib>
#include <cstring>
#include <string_view>

namespace factory {
auto getPluginCount(clap_plugin_factory const* factory) -> uint32_t { return 1; }

Expand Down
12 changes: 6 additions & 6 deletions src/ta/ui/window/window.cpp
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
#include "window.hpp"

#include <cstdlib>
#include <optional>
#include <string>

#define GLFW_EXPOSE_NATIVE_WIN32
#include <cairo/cairo-win32.h>
#include <cairo/cairo.h>
#include <GLFW/glfw3.h>
#include <GLFW/glfw3native.h>

#include <cstdlib>
#include <optional>
#include <string>

namespace ta {

namespace detail {
Expand All @@ -28,9 +28,9 @@ struct WindowPimpl
GLFWwindow* glfwWindow{nullptr};
cairo_surface_t* surface;
cairo_t* ctx;
Optional<Canvas> canvas;
std::optional<Canvas> canvas;

String title;
std::string title;
int initialWidth;
int initialHeight;
};
Expand Down

0 comments on commit 733d85a

Please sign in to comment.