Fix to allow SDL compiled under XFree v4 to work with XFree v3 xservers.
Contributed by Jarek Sobieszek --HG-- extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%4091
This commit is contained in:
parent
ec76bd6aef
commit
b4001bd1ff
2 changed files with 3 additions and 3 deletions
|
@ -37,7 +37,7 @@ static char rcsid =
|
||||||
static int X11_SetGammaNoLock(_THIS, float red, float green, float blue)
|
static int X11_SetGammaNoLock(_THIS, float red, float green, float blue)
|
||||||
{
|
{
|
||||||
#ifdef XFREE86_VMGAMMA
|
#ifdef XFREE86_VMGAMMA
|
||||||
if (use_vidmode) {
|
if (use_vidmode >= 2) {
|
||||||
XF86VidModeGamma gamma;
|
XF86VidModeGamma gamma;
|
||||||
Bool succeeded;
|
Bool succeeded;
|
||||||
|
|
||||||
|
@ -98,7 +98,7 @@ int X11_SetVidModeGamma(_THIS, float red, float green, float blue)
|
||||||
static int X11_GetGammaNoLock(_THIS, float *red, float *green, float *blue)
|
static int X11_GetGammaNoLock(_THIS, float *red, float *green, float *blue)
|
||||||
{
|
{
|
||||||
#ifdef XFREE86_VMGAMMA
|
#ifdef XFREE86_VMGAMMA
|
||||||
if (use_vidmode) {
|
if (use_vidmode >= 2) {
|
||||||
XF86VidModeGamma gamma;
|
XF86VidModeGamma gamma;
|
||||||
if (XVidMode(GetGamma, (SDL_Display, SDL_Screen, &gamma))) {
|
if (XVidMode(GetGamma, (SDL_Display, SDL_Screen, &gamma))) {
|
||||||
*red = gamma.red;
|
*red = gamma.red;
|
||||||
|
|
|
@ -271,7 +271,7 @@ int X11_GetVideoModes(_THIS)
|
||||||
}
|
}
|
||||||
XFree(modes);
|
XFree(modes);
|
||||||
|
|
||||||
use_vidmode = 1;
|
use_vidmode = vm_major;
|
||||||
save_mode(this);
|
save_mode(this);
|
||||||
}
|
}
|
||||||
#endif /* XFREE86_VM */
|
#endif /* XFREE86_VM */
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue