Blob Blame History Raw
--- gnome-control-center-2.28.0/capplets/display/xrandr-capplet.c	2009-08-24 06:54:41.000000000 -0400
+++ hacked/capplets/display/xrandr-capplet.c	2009-09-30 09:29:05.160839814 -0400
@@ -516,6 +516,7 @@
 {
     int i;
     GnomeRRMode **modes;
+    int best_w, best_h;
     const char *current;
 
     clear_combo (app->resolution_combo);
@@ -533,6 +534,8 @@
 
     gtk_widget_set_sensitive (app->resolution_combo, TRUE);
 
+    best_w = 0;
+    best_h = 0;
     for (i = 0; modes[i] != NULL; ++i)
     {
 	int width, height;
@@ -543,12 +546,21 @@
 	add_key (app->resolution_combo,
 		 idle_free (make_resolution_string (width, height)),
 		 width, height, 0, -1);
+
+        if (width * height > best_w * best_h)
+        {
+            best_w = width;
+            best_h = height;
+        }
     }
 
     current = idle_free (make_resolution_string (app->current_output->width, app->current_output->height));
 
     if (!combo_select (app->resolution_combo, current))
-	g_assert_not_reached ();
+    {
+         combo_select (app->resolution_combo,
+                       idle_free (make_resolution_string (best_w, best_h)));
+    }
 }
 
 static void