shithub: cstory

Download patch

ref: 92d565692aea7a9472a892f54ccef0b2b181f0fd
parent: 5ed34e73d4ddf92d109f761d73b14ca2494fdf95
author: Gabriel Ravier <gabravier@gmail.com>
date: Sat Apr 11 21:16:45 EDT 2020

Backends: Use "SDL" instead of "SDL2" to match documentation vocabulary

Signed-off-by: Gabriel Ravier <gabravier@gmail.com>

--- a/src/Backends/Audio/SDL2.cpp
+++ b/src/Backends/Audio/SDL2.cpp
@@ -72,7 +72,7 @@
 		return FALSE;
 	}
 
-	Backend_PrintInfo("Available SDL2 audio drivers:");
+	Backend_PrintInfo("Available SDL audio drivers:");
 
 	for (int i = 0; i < SDL_GetNumAudioDrivers(); ++i)
 		Backend_PrintInfo("%s", SDL_GetAudioDriver(i));
@@ -99,7 +99,7 @@
 
 	SDL_PauseAudioDevice(device_id, 0);
 
-	Backend_PrintInfo("Selected SDL2 audio driver: %s", SDL_GetCurrentAudioDriver());
+	Backend_PrintInfo("Selected SDL audio driver: %s", SDL_GetCurrentAudioDriver());
 
 	return TRUE;
 }
--- a/src/Backends/Rendering/SDLTexture.cpp
+++ b/src/Backends/Rendering/SDLTexture.cpp
@@ -128,7 +128,7 @@
 
 RenderBackend_Surface* RenderBackend_Init(const char *window_title, int screen_width, int screen_height, BOOL fullscreen)
 {
-	Backend_PrintInfo("Available SDL2 render drivers:");
+	Backend_PrintInfo("Available SDL render drivers:");
 
 	for (int i = 0; i < SDL_GetNumRenderDrivers(); ++i)
 	{
@@ -161,7 +161,7 @@
 			if (SDL_GetRendererInfo(renderer, &info) < 0)
 				Backend_PrintError("Couldn't get selected render driver information: %s", SDL_GetError());
 			else
-				Backend_PrintInfo("Selected SDL2 render driver: %s", info.name);
+				Backend_PrintInfo("Selected SDL render driver: %s", info.name);
 
 			framebuffer.texture = SDL_CreateTexture(renderer, SDL_PIXELFORMAT_RGBA32, SDL_TEXTUREACCESS_TARGET, screen_width, screen_height);
 
--- a/src/Backends/SDL2/Controller.cpp
+++ b/src/Backends/SDL2/Controller.cpp
@@ -19,7 +19,7 @@
 {
 	if (SDL_InitSubSystem(SDL_INIT_JOYSTICK) < 0)
 	{
-		Backend_PrintError("Couldn't initialise joystack SDL2 subsystem: %s", SDL_GetError());
+		Backend_PrintError("Couldn't initialise joystick SDL subsystem: %s", SDL_GetError());
 		return FALSE;
 	}
 
--- a/src/Backends/SDL2/Misc.cpp
+++ b/src/Backends/SDL2/Misc.cpp
@@ -37,7 +37,7 @@
 	{
 		if (SDL_InitSubSystem(SDL_INIT_VIDEO) == 0)
 		{
-			Backend_PrintInfo("Available SDL2 video drivers:");
+			Backend_PrintInfo("Available SDL video drivers:");
 
 			for (int i = 0; i < SDL_GetNumVideoDrivers(); ++i)
 				Backend_PrintInfo("%s", SDL_GetVideoDriver(i));
@@ -45,14 +45,14 @@
 			const char *driver = SDL_GetCurrentVideoDriver();
 
 			if (driver != NULL)
-				Backend_PrintInfo("Selected SDL2 video driver: %s", driver);
+				Backend_PrintInfo("Selected SDL video driver: %s", driver);
 			else
-				Backend_PrintError("No SDL2 video driver initialized !");
+				Backend_PrintError("No SDL video driver initialized !");
 
 			return TRUE;
 		}
 
-		std::string error_message = std::string("Could not initialise SDL2 video subsystem: ") + SDL_GetError();
+		std::string error_message = std::string("Could not initialise SDL video subsystem: ") + SDL_GetError();
 		Backend_ShowMessageBox("Fatal error", error_message.c_str());
 
 		SDL_Quit();
@@ -59,7 +59,7 @@
 		return FALSE;
 	}
 
-	std::string error_message = std::string("Could not initialise SDL2: ") + SDL_GetError();
+	std::string error_message = std::string("Could not initialise SDL: ") + SDL_GetError();
 	Backend_ShowMessageBox("Fatal error", error_message.c_str());
 
 	return FALSE;