SDL: test: Fix a window parenting bug in testmodal (28721)

From 28721e3cd29278ae104690183c733e82456823fa Mon Sep 17 00:00:00 2001
From: Frank Praznik <[EMAIL REDACTED]>
Date: Wed, 18 Jun 2025 09:21:36 -0400
Subject: [PATCH] test: Fix a window parenting bug in testmodal

(cherry picked from commit 390fe653237a11c736801af1c7ada5dd39e73a2f)
---
 test/testmodal.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/test/testmodal.c b/test/testmodal.c
index 9e5ea63e409a3..d898b89697e1f 100644
--- a/test/testmodal.c
+++ b/test/testmodal.c
@@ -97,7 +97,7 @@ int main(int argc, char *argv[])
                     }
 
                     if (e.key.key == SDLK_M) {
-                        if (SDL_SetWindowParent(w2, w2)) {
+                        if (SDL_SetWindowParent(w2, w1)) {
                             if (SDL_SetWindowModal(w2, true)) {
                                 SDL_SetWindowTitle(w2, "Modal Window");
                             }