mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
2001-10-22 Joshua Sled <jsled@asynchronous.org>
* src/engine/SchedXaction.c (xaccSchedXactionInit): Fixed number-of-occurances init problem. * src/gnome/dialog-scheduledxaction.c (schedXact_editor_populate): Fixed bug in populating the editor. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@5712 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
98a6062c43
commit
6820436bdb
@ -1,3 +1,11 @@
|
||||
2001-10-22 Joshua Sled <jsled@asynchronous.org>
|
||||
|
||||
* src/engine/SchedXaction.c (xaccSchedXactionInit): Fixed
|
||||
number-of-occurances init problem.
|
||||
|
||||
* src/gnome/dialog-scheduledxaction.c (schedXact_editor_populate):
|
||||
Fixed bug in populating the editor.
|
||||
|
||||
2001-10-22 Joshua Sled <jsled@asynchronous.org>
|
||||
|
||||
* src/gnome/window-main.c (gnc_ui_mainWindow_nextrun_cb):
|
||||
|
@ -66,7 +66,7 @@ xaccSchedXactionInit( SchedXaction *sx, GNCSession *session)
|
||||
g_date_clear( &sx->start_date, 1 );
|
||||
g_date_clear( &sx->end_date, 1 );
|
||||
|
||||
sx->num_occurances_total = -1;
|
||||
sx->num_occurances_total = 0;
|
||||
sx->kvp_data = kvp_frame_new();
|
||||
sx->autoCreateOption = FALSE;
|
||||
sx->autoCreateNotify = FALSE;
|
||||
|
@ -357,6 +357,11 @@ scheduledxaction_editor_dialog_destroy(GtkObject *object, gpointer data)
|
||||
if (sxed == NULL)
|
||||
return;
|
||||
|
||||
if ( sxed->ledger ) {
|
||||
sxed_close_handler( sxed );
|
||||
return;
|
||||
}
|
||||
|
||||
gnc_unregister_gui_component_by_data
|
||||
(DIALOG_SCHEDXACTION_EDITOR_CM_CLASS, sxed);
|
||||
|
||||
@ -535,7 +540,6 @@ gnc_ui_scheduled_xaction_editor_dialog_create( SchedXactionDialog *sxd,
|
||||
return sxed;
|
||||
}
|
||||
|
||||
|
||||
sxed = g_new0( SchedXactionEditorDialog, 1 );
|
||||
|
||||
/* sxed->dialog = create_Scheduled_Transaction_Editor(); */
|
||||
@ -960,13 +964,14 @@ schedXact_editor_populate( SchedXactionEditorDialog *sxed )
|
||||
g_free( tmpTm );
|
||||
gnome_date_edit_set_time( GNOME_DATE_EDIT(w), tmpDate );
|
||||
set_endgroup_toggle_states( sxed, END_DATE );
|
||||
} else if ( xaccSchedXactionGetNumOccur( sxed->sx ) != -1 ) {
|
||||
} else if ( xaccSchedXactionHasOccurDef( sxed->sx ) ) {
|
||||
gint numOccur = xaccSchedXactionGetNumOccur( sxed->sx );
|
||||
w = glade_xml_get_widget( sxed->gxml, "rb_num_occur" );
|
||||
gtk_toggle_button_set_active( GTK_TOGGLE_BUTTON(w), TRUE );
|
||||
w = glade_xml_get_widget( sxed->gxml, END_GNOME_NUMENTRY );
|
||||
w = gnome_number_entry_gtk_entry( GNOME_NUMBER_ENTRY(w) );
|
||||
tmpgStr = g_string_sized_new(5);
|
||||
g_string_sprintf( tmpgStr, "%d", xaccSchedXactionGetNumOccur( sxed->sx ) );
|
||||
g_string_sprintf( tmpgStr, "%d", numOccur );
|
||||
gtk_entry_set_text( GTK_ENTRY(w), tmpgStr->str );
|
||||
g_string_free( tmpgStr, TRUE );
|
||||
set_endgroup_toggle_states( sxed, END_OCCUR );
|
||||
|
Loading…
Reference in New Issue
Block a user