]> pilppa.org Git - familiar-h63xx-build.git/blob - org.handhelds.familiar/packages/gtk+/gtk+-2.6.3/single-click.patch
OE tree imported from monotone branch org.openembedded.oz354fam083 at revision 8b12e3...
[familiar-h63xx-build.git] / org.handhelds.familiar / packages / gtk+ / gtk+-2.6.3 / single-click.patch
1 diff -urNd ../gtk+-2.6.3-r0.old/gtk+-2.6.3/gtk/gtkcalendar.c gtk+-2.6.3/gtk/gtkcalendar.c
2 --- ../gtk+-2.6.3-r0.old/gtk+-2.6.3/gtk/gtkcalendar.c   2005-04-06 16:57:04 +01:00
3 +++ gtk+-2.6.3/gtk/gtkcalendar.c        2005-04-06 20:05:18 +01:00
4 @@ -1023,9 +1023,11 @@
5         }
6  
7        gtk_calendar_select_and_focus_day (calendar, day);
8 -    }
9 +      
10 +      // This change causes the calendar to disappear after choosing a day
11 +/*    }
12    else if (event->type == GDK_2BUTTON_PRESS)
13 -    {
14 +    {*/
15        private_data->in_drag = 0;
16        if (day_month == MONTH_CURRENT)
17         g_signal_emit (calendar,
18 diff -urNd ../gtk+-2.6.3-r0.old/gtk+-2.6.3/gtk/gtkfilesel.c gtk+-2.6.3/gtk/gtkfilesel.c
19 --- ../gtk+-2.6.3-r0.old/gtk+-2.6.3/gtk/gtkfilesel.c    2005-04-06 16:57:07 +01:00
20 +++ gtk+-2.6.3/gtk/gtkfilesel.c 2005-04-07 13:40:32 +01:00
21 @@ -2468,6 +2468,33 @@
22        if (fs->last_selected != NULL)
23         g_free (fs->last_selected);
24  
25 +      // Single-click directory entry  
26 +         if (new_names->len == 1)
27 +           {
28 +             GtkTreeView *tree_view;
29 +             GtkTreeModel *model;
30 +             GtkTreePath *path;
31 +          GtkTreeIter iter;  
32 +          gboolean is_file;
33 +
34 +          tree_view = gtk_tree_selection_get_tree_view (selection);
35 +          
36 +          if (gtk_tree_selection_get_selected (selection, &model, &iter))
37 +            {
38 +              path = gtk_tree_model_get_path (model, &iter);              
39 +              gtk_tree_model_get (model, &iter, ISFILE_COLUMN, &is_file, -1);
40 +
41 +              if (!is_file)
42 +                {
43 +                  gtk_file_selection_dir_activate (tree_view, path, 
44 +                          gtk_tree_view_get_column (tree_view, DIR_COLUMN),
45 +                          user_data);
46 +                }
47 +                
48 +              gtk_tree_path_free (path);
49 +            }
50 +        }
51 +        
52        fs->last_selected = g_strdup (g_ptr_array_index (new_names, index));
53        filename = get_real_filename (fs->last_selected, FALSE);
54