Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3630 in orxonox.OLD for orxonox/trunk/src/lib/gui


Ignore:
Timestamp:
Mar 22, 2005, 11:50:39 AM (20 years ago)
Author:
bensch
Message:

orxonox/trunk: gui: little patch, now only one resolution will be shown, if multiple bpp's are availiable

Location:
orxonox/trunk/src/lib/gui/gui
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/lib/gui/gui/orxonox_gui_gtk.cc

    r3628 r3630  
    127127      //! \todo move this into the gui-gtk-file
    128128      //! \todo finish it.
     129      //! \todo memory leek at save(); and save is a BAD word, use saveString instead, or something like it.
    129130    }
    130131#endif /* HAVE_GTK2 */
  • orxonox/trunk/src/lib/gui/gui/orxonox_gui_video.cc

    r3624 r3630  
    154154  SDL_Rect **modes;
    155155  int i;
     156  int x = 0,y =0; // check for difference
    156157  char tmpChar[100];
    157158 
     
    174175    for(i = 0; modes[i] ;++i)
    175176      {
    176         PRINT(4)("  %d x %d\n", modes[i]->w, modes[i]->h);
    177         sprintf(tmpChar, "%dx%d", modes[i]->w, modes[i]->h);
    178         menu->addItem(tmpChar);
     177        if (x != modes[i]->w || y != modes[i]->h)
     178          {
     179            PRINT(4)("  %d x %d\n", modes[i]->w, modes[i]->h);
     180            sprintf(tmpChar, "%dx%d", modes[i]->w, modes[i]->h);
     181            menu->addItem(tmpChar);
     182            x = modes[i]->w; y = modes[i]->h;
     183          }
    179184      }
    180185  }
Note: See TracChangeset for help on using the changeset viewer.