From 722aba17810c97bb24a1565f4a03e3a1e05a8266 Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Mon, 8 May 2006 04:19:03 +0000 Subject: [PATCH] Eliminate duplicate video modes --- src/video/directfb/SDL_DirectFB_video.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/video/directfb/SDL_DirectFB_video.c b/src/video/directfb/SDL_DirectFB_video.c index 63d6814a0..696b5c3b1 100644 --- a/src/video/directfb/SDL_DirectFB_video.c +++ b/src/video/directfb/SDL_DirectFB_video.c @@ -191,6 +191,9 @@ static DFBEnumerationResult EnumModesCallback (int width, HIDDEN->nummodes++; + if (enumlist && enumlist->r.w == width && enumlist->r.h == height) + return DFENUM_OK; + enumrect = SDL_calloc(1, sizeof(struct DirectFBEnumRect)); if (!enumrect) {