aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-gnome/gtk+/gtk+-2.12.7/filechooser-sizefix.patch
blob: 694b059b9ae1d83dae691ae08a35ac738700bbd0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
--- gtk+-2.12.7.orig/gtk/gtkfilechooserdialog.c 
+++ gtk+-2.12.7/gtk/gtkfilechooserdialog.c 
@@ -165,10 +165,10 @@
   gdk_screen_get_monitor_geometry (screen, monitor_num, &monitor);
 
   if (width)
-    *width = MIN (*width, (monitor.width * 3) / 4);
+    *width = MIN (*width, monitor.width);
 
   if (height)
-    *height = MIN (*height, (monitor.height * 3) / 4);
+    *height = MIN (*height, monitor.height);
 }
 
 static void
@@ -183,6 +183,7 @@
 
   priv = GTK_FILE_CHOOSER_DIALOG_GET_PRIVATE (dialog);
 
+#if 0
   /* Unset any previously set size */
   gtk_widget_set_size_request (GTK_WIDGET (dialog), -1, -1);
 
@@ -209,6 +210,11 @@
   /* Ideal target size plus any extra size */
   width = default_width + width + (2 * GTK_CONTAINER (dialog)->border_width);
   height = default_height + height + (2 * GTK_CONTAINER (dialog)->border_width);
+#endif
+
+  /* for small screens we just hard code a sensible value */
+  width = 350;
+  height = 350;
 
   if (GTK_WIDGET_REALIZED (dialog))
     clamp_to_screen (GTK_WIDGET (dialog), &width, &height);