[grisbi-cvs] [SCM] grisbi branch, master, updated. 588a03ea3cc844e1065b65c5e9617c33f74beefc
Pierre Biava
pbiava at users.sourceforge.net
Wed Jun 2 20:41:26 CEST 2010
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "grisbi".
The branch, master has been updated
via 588a03ea3cc844e1065b65c5e9617c33f74beefc (commit)
from 8908faef95c9a55a9219dfcb867828750553e231 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 588a03ea3cc844e1065b65c5e9617c33f74beefc
Author: Pierre Biava <pierre.biava at nerim.net>
Date: Wed Jun 2 20:39:36 2010 +0200
corrects a problem updating of balance date a cash account in the budget management module
-----------------------------------------------------------------------
Changes:
diff --git a/src/balance_estimate_data.c b/src/balance_estimate_data.c
index 3c0e03f..45711aa 100644
--- a/src/balance_estimate_data.c
+++ b/src/balance_estimate_data.c
@@ -1703,35 +1703,22 @@ gboolean bet_data_transfert_modify_line ( struct_transfert_data *transfert )
* */
void bet_data_transfert_update_date_if_necessary ( struct_transfert_data *transfert )
{
- GDate *date_jour;
+ GDate *date_jour_1;
GDate *tmp_date;
- date_jour = gdate_today ( );
+ devel_debug (NULL);
+ date_jour_1 = gdate_today ( );
+ g_date_set_day ( date_jour_1, 1 );
tmp_date = gsb_date_copy ( transfert -> date );
- g_date_add_months ( tmp_date, 1 );
- if ( g_date_compare ( date_jour, tmp_date ) >= 0 )
+ if ( g_date_get_month ( date_jour_1 ) == g_date_get_month ( tmp_date ) )
{
- if ( g_date_get_month ( date_jour ) == g_date_get_month ( tmp_date ) )
- {
- g_date_free ( transfert -> date );
- g_date_free ( date_jour );
- transfert -> date = tmp_date;
- }
- else
- {
- g_date_set_day ( date_jour, g_date_get_day ( tmp_date ) );
- g_date_free ( transfert -> date );
- g_date_free ( tmp_date );
- transfert -> date = date_jour;
- }
- bet_data_transfert_modify_line ( transfert );
- }
- else
- {
- g_date_free ( tmp_date );
- g_date_free ( date_jour );
+ g_date_free ( transfert -> date );
+ g_date_add_months ( tmp_date, 1 );
+ transfert -> date = tmp_date;
}
+
+ g_date_free ( date_jour_1 );
}
diff --git a/src/balance_estimate_future.c b/src/balance_estimate_future.c
index f9bf2dd..1abf8e4 100644
--- a/src/balance_estimate_future.c
+++ b/src/balance_estimate_future.c
@@ -1965,7 +1965,7 @@ GtkWidget *bet_transfert_create_dialog ( gint account_number )
button = gtk_check_button_new_with_label ( _("Monthly auto-increment") );
gtk_toggle_button_set_active ( GTK_TOGGLE_BUTTON ( button ), FALSE );
g_object_set_data ( G_OBJECT ( dialog ), "bet_transfert_auto_inc", button );
- //~ gtk_box_pack_start ( GTK_BOX ( hbox ), button, FALSE, FALSE, 5 );
+ gtk_box_pack_start ( GTK_BOX ( hbox ), button, FALSE, FALSE, 5 );
//~ g_signal_connect ( G_OBJECT ( button ),
//~ "toggled",
//~ G_CALLBACK ( bet_transfert_auto_inc_toggle ),
diff --git a/src/balance_estimate_tab.c b/src/balance_estimate_tab.c
index 9b106bc..74c8bb1 100644
--- a/src/balance_estimate_tab.c
+++ b/src/balance_estimate_tab.c
@@ -1906,24 +1906,15 @@ gboolean bet_array_start_date_focus_out ( GtkWidget *entry,
gboolean bet_array_list_select_path ( GtkWidget *tree_view, GtkTreePath *path )
{
GtkTreeSelection *selection;
- gboolean reset_pos = FALSE;
selection = gtk_tree_view_get_selection ( GTK_TREE_VIEW ( tree_view ) );
if ( path == NULL )
- {
path = gtk_tree_path_new_from_string ( "0" );
- reset_pos = TRUE;
- }
gtk_widget_grab_focus ( tree_view );
gtk_tree_selection_select_path ( selection, path );
- if ( reset_pos )
- gtk_tree_view_scroll_to_cell ( GTK_TREE_VIEW ( tree_view ),
- path, NULL,
- FALSE, 0.0, 0.0 );
-
return FALSE;
}
hooks/post-receive
--
grisbi
More information about the cvs
mailing list