From 9b06f1c48184e4eb6a10cbd4b7ea119afdd00127 Mon Sep 17 00:00:00 2001 From: kervala Date: Sat, 10 Jul 2010 13:59:45 +0200 Subject: [PATCH] Fixed: sort screen modes by width, height and frequency --- code/nel/src/3d/driver_user.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/code/nel/src/3d/driver_user.cpp b/code/nel/src/3d/driver_user.cpp index 5afebf8e3..ea8a44e83 100644 --- a/code/nel/src/3d/driver_user.cpp +++ b/code/nel/src/3d/driver_user.cpp @@ -286,7 +286,12 @@ struct CModeSorter { bool operator()(const UDriver::CMode &mode1, const UDriver::CMode &mode2) const { - if (mode1.Width == mode2.Width) return mode1.Height < mode2.Height; + if (mode1.Width == mode2.Width) + { + if (mode1.Height == mode2.Height) return mode1.Frequency < mode2.Frequency; + + return mode1.Height < mode2.Height; + } return mode1.Width < mode2.Width; }