Browse Source

Minor tweaks `const`

Ray 3 years ago
parent
commit
cb62cb675f

+ 2 - 2
examples/core/core_basic_window_web.c

@@ -24,8 +24,8 @@
 //----------------------------------------------------------------------------------
 // Global Variables Definition
 //----------------------------------------------------------------------------------
-int screenWidth = 800;
-int screenHeight = 450;
+const int screenWidth = 800;
+const int screenHeight = 450;
 
 //----------------------------------------------------------------------------------
 // Module Functions Declaration

+ 2 - 2
examples/shaders/shaders_hot_reloading.c

@@ -27,8 +27,8 @@ int main(void)
 {
     // Initialization
     //--------------------------------------------------------------------------------------
-    int screenWidth = 800;
-    int screenHeight = 450;
+    const int screenWidth = 800;
+    const int screenHeight = 450;
 
     InitWindow(screenWidth, screenHeight, "raylib [shaders] example - hot reloading");
 

+ 2 - 2
examples/shaders/shaders_raymarching.c

@@ -24,8 +24,8 @@ int main(void)
 {
     // Initialization
     //--------------------------------------------------------------------------------------
-    int screenWidth = 800;
-    int screenHeight = 450;
+    const int screenWidth = 800;
+    const int screenHeight = 450;
 
     SetConfigFlags(FLAG_WINDOW_RESIZABLE);
     InitWindow(screenWidth, screenHeight, "raylib [shaders] example - raymarching shapes");

+ 2 - 2
examples/textures/textures_draw_tiled.c

@@ -19,8 +19,8 @@ int main(int argc, char **argv)
 {
     // Initialization
     //--------------------------------------------------------------------------------------
-    int screenWidth = 800;
-    int screenHeight = 450;
+    const int screenWidth = 800;
+    const int screenHeight = 450;
 
     SetConfigFlags(FLAG_WINDOW_RESIZABLE); // Make the window resizable
     InitWindow(screenWidth, screenHeight, "raylib [textures] example - Draw part of a texture tiled");

+ 1 - 0
src/rcore.c

@@ -6647,6 +6647,7 @@ static int FindNearestConnectorMode(const drmModeConnector *connector, uint widt
 
 #if defined(SUPPORT_EVENTS_AUTOMATION)
 // NOTE: Loading happens over AutomationEvent *events
+// TODO: This system should probably be redesigned
 static void LoadAutomationEvents(const char *fileName)
 {
     //unsigned char fileId[4] = { 0 };