diff src/video/riscos/SDL_riscosFullScreenVideo.c @ 1208:d90b362628ea

From: "alan buckley" <alan_baa@hotmail.com> Subject: Patch for RISC OS cursor palette handling in SDL Date: Mon, 07 Nov 2005 09:14:15 -0800 The mouse cursor palette was not correctly restored on RISC OS if the system was using anything but the default mouse colours. Additionally I've modifed the order the wait for vsync is called as it should be after the screen bank switching.
author Sam Lantinga <slouken@libsdl.org>
date Fri, 23 Dec 2005 09:40:15 +0000
parents 974ba6ae0fa3
children c9b51268668f
line wrap: on
line diff
--- a/src/video/riscos/SDL_riscosFullScreenVideo.c	Wed Dec 21 18:02:36 2005 +0000
+++ b/src/video/riscos/SDL_riscosFullScreenVideo.c	Fri Dec 23 09:40:15 2005 +0000
@@ -280,8 +280,6 @@
       } else
 	   this->UpdateRects = FULLSCREEN_UpdateRects; /* Default do nothing implementation */
 
-	if (this->SetColors == FULLSCREEN_SetColors) return; /* Already set up */
-
 	this->SetColors   = FULLSCREEN_SetColors;
 
 	this->FlipHWSurface = FULLSCREEN_FlipHWSurface;
@@ -368,14 +366,15 @@
 {
    _kernel_swi_regs regs;
    regs.r[0] = 19;
-   /* Wait for Vsync */
-   _kernel_swi(OS_Byte, &regs, &regs);
 
    FULLSCREEN_SetDisplayBank(this->hidden->current_bank);
    this->hidden->current_bank ^= 1;
    FULLSCREEN_SetWriteBank(this->hidden->current_bank);
    surface->pixels = this->hidden->bank[this->hidden->current_bank];
 
+   /* Wait for Vsync */
+   _kernel_swi(OS_Byte, &regs, &regs);
+
 	return(0);
 }