Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Eliminate duplicate modes with different refresh rates
  • Loading branch information
slouken committed Feb 1, 2006
1 parent 6b5989a commit e9d9ecf
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/video/x11/SDL_x11modes.c
Expand Up @@ -366,6 +366,13 @@ int X11_GetVideoModes(_THIS)
for ( i=0; i<nmodes; ++i ) {
int w, h;

/* Eliminate duplicate modes with different refresh rates */
if ( i > 0 &&
modes[i]->hdisplay == modes[i-1]->hdisplay &&
modes[i]->vdisplay == modes[i-1]->vdisplay ) {
continue;
}

/* Check to see if we should add the screen size (Xinerama) */
w = modes[i]->hdisplay;
h = modes[i]->vdisplay;
Expand Down

0 comments on commit e9d9ecf

Please sign in to comment.