"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "gnucash/gnome-search/dialog-search.c" between
gnucash-5.0.tar.bz2 and gnucash-5.1.tar.bz2

About: GnuCash is personal and small-business financial-accounting software.

dialog-search.c  (gnucash-5.0.tar.bz2):dialog-search.c  (gnucash-5.1.tar.bz2)
skipping to change at line 371 skipping to change at line 371
/* Deselect all the select buttons and any items */ /* Deselect all the select buttons and any items */
gnc_search_dialog_select_buttons_enable (sw, 0); gnc_search_dialog_select_buttons_enable (sw, 0);
gnc_query_view_unselect_all (GNC_QUERY_VIEW(sw->result_view)); gnc_query_view_unselect_all (GNC_QUERY_VIEW(sw->result_view));
/* set 'new search' if fewer than max_count items is returned. */ /* set 'new search' if fewer than max_count items is returned. */
max_count = gnc_prefs_get_float(GNC_PREFS_GROUP_SEARCH_GENERAL, GNC_PREF_NEW _SEARCH_LIMIT); max_count = gnc_prefs_get_float(GNC_PREFS_GROUP_SEARCH_GENERAL, GNC_PREF_NEW _SEARCH_LIMIT);
if (gnc_query_view_get_num_entries(GNC_QUERY_VIEW(sw->result_view)) < max_co unt) if (gnc_query_view_get_num_entries(GNC_QUERY_VIEW(sw->result_view)) < max_co unt)
gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON (sw->new_rb), TRUE); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON (sw->new_rb), TRUE);
/* If there is only one item then select it */ /* If there are results then select the first, and grab focus */
if (gnc_query_view_get_num_entries (GNC_QUERY_VIEW(sw->result_view)) == 1) if (gnc_query_view_get_num_entries (GNC_QUERY_VIEW(sw->result_view)) > 0)
{ {
GtkTreeSelection *selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (sw->result_view)); GtkTreeSelection *selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (sw->result_view));
GtkTreePath *path = gtk_tree_path_new_first (); GtkTreePath *path = gtk_tree_path_new_first ();
gtk_tree_selection_select_path (selection, path); gtk_tree_selection_select_path (selection, path);
gtk_tree_path_free (path); gtk_tree_path_free (path);
gtk_widget_grab_focus (sw->result_view);
} }
} }
static void static void
match_combo_changed (GtkComboBoxText *combo_box, GNCSearchWindow *sw) match_combo_changed (GtkComboBoxText *combo_box, GNCSearchWindow *sw)
{ {
sw->grouping = gtk_combo_box_get_active(GTK_COMBO_BOX(combo_box)); sw->grouping = gtk_combo_box_get_active(GTK_COMBO_BOX(combo_box));
} }
static void static void
 End of changes. 2 change blocks. 
2 lines changed or deleted 3 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)