[Gnucash-changes] Enable HBCI statement download again.
Christian Stimming
cstim at cvs.gnucash.org
Mon Jul 25 16:45:06 EDT 2005
Log Message:
-----------
Enable HBCI statement download again. Works fully now.
2005-07-25 Christian Stimming <stimming at tuhh.de>
* src/import-export/hbci/dialog-daterange.c: Enable HBCI statement
download again. Works fully now.
Tags:
----
gnucash-gnome2-dev
Modified Files:
--------------
gnucash:
ChangeLog
GNOME2_STATUS
gnucash/src/import-export/hbci:
dialog-daterange.c
dialog-hbcitrans.c
hbci-interaction.c
gnucash/src/import-export/hbci/glade:
hbci.glade
Revision Data
-------------
Index: ChangeLog
===================================================================
RCS file: /home/cvs/cvsroot/gnucash/ChangeLog,v
retrieving revision 1.1487.2.253
retrieving revision 1.1487.2.254
diff -LChangeLog -LChangeLog -u -r1.1487.2.253 -r1.1487.2.254
--- ChangeLog
+++ ChangeLog
@@ -1,3 +1,8 @@
+2005-07-25 Christian Stimming <stimming at tuhh.de>
+
+ * src/import-export/hbci/dialog-daterange.c: Enable HBCI statement
+ download again. Works fully now.
+
2005-07-25 Derek Atkins <derek at ihtfp.com>
* src/business/business-core/gncInvoice.c: revert the
Index: GNOME2_STATUS
===================================================================
RCS file: /home/cvs/cvsroot/gnucash/Attic/GNOME2_STATUS,v
retrieving revision 1.1.2.58
retrieving revision 1.1.2.59
diff -LGNOME2_STATUS -LGNOME2_STATUS -u -r1.1.2.58 -r1.1.2.59
--- GNOME2_STATUS
+++ GNOME2_STATUS
@@ -32,7 +32,7 @@
Properties Dialog
QIF Import
OFX Import
-MT940 Import (need test data file)
+HBCI Import
Export Accounts
Stock Split Dialog
@@ -138,14 +138,12 @@
- Importing
- - HBCI - Needs new HTTP support [gnet] -- huh, no, the
- import-export/hbci module does not need any extra http library,
- especially not at compile-time. The module only needs the
- aqbanking library but really nothing else. If the aqbanking
- library links against any http library, then that's a business of
- that library, but to my knowledge it comes with its own http
- implementation so gnucash should really not be concerned about
- http! cstim, 2005-04-09.
+ - HBCI - Issuing a transaction doesn't work fully, because some
+ widget changes have not been changed in the code. But Balance
+ download fully works. (Earlier this
+ said: "Needs new HTTP support [gnet]", but no, the
+ import-export/hbci module does not need any extra http
+ library. cstim, 2005-04-09.)
- Budgeting
Index: dialog-daterange.c
===================================================================
RCS file: /home/cvs/cvsroot/gnucash/src/import-export/hbci/dialog-daterange.c,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -Lsrc/import-export/hbci/dialog-daterange.c -Lsrc/import-export/hbci/dialog-daterange.c -u -r1.1.4.1 -r1.1.4.2
--- src/import-export/hbci/dialog-daterange.c
+++ src/import-export/hbci/dialog-daterange.c
@@ -64,7 +64,7 @@
dialog = glade_xml_get_widget (xml, "HBCI_daterange_dialog");
if (parent)
- gnome_dialog_set_parent (GNOME_DIALOG (dialog), GTK_WINDOW (parent));
+ gtk_window_set_transient_for (GTK_WINDOW (dialog), GTK_WINDOW (parent));
heading_label = glade_xml_get_widget (xml, "heading_label");
last_retrieval_button = glade_xml_get_widget (xml, "last_retrieval_button");
@@ -95,7 +95,7 @@
gtk_signal_connect (GTK_OBJECT (info.enter_to_button), "toggled",
GTK_SIGNAL_FUNC (on_button_toggled), &info);
- gnome_dialog_set_default (GNOME_DIALOG (dialog), 0);
+ gtk_dialog_set_default_response (GTK_DIALOG (dialog), 1);
if (heading)
gtk_label_set_text (GTK_LABEL (heading_label), heading);
@@ -104,12 +104,14 @@
/* Hide on close instead of destroy since we still need the values
from the boxes. */
- gnome_dialog_close_hides (GNOME_DIALOG (dialog), TRUE);
+ /* gnome_dialog_close_hides (GTK_DIALOG (dialog), TRUE); */
gtk_widget_show_all (GTK_WIDGET (dialog));
- result = gnome_dialog_run_and_close (GNOME_DIALOG (dialog));
+ result = gtk_dialog_run (GTK_DIALOG (dialog));
+ if (result >= 0)
+ gtk_widget_hide (GTK_WIDGET (dialog));
- if (result == 0)
+ if (result == 1)
{
*from_date = gnc_date_edit_get_date_ts (GNC_DATE_EDIT (info.from_dateedit));
*last_retv_date = gtk_toggle_button_get_active
@@ -124,7 +126,8 @@
return TRUE;
}
- gtk_widget_destroy (GTK_WIDGET (dialog));
+ if (result >= 0)
+ gtk_widget_destroy (GTK_WIDGET (dialog));
return FALSE;
}
Index: hbci-interaction.c
===================================================================
RCS file: /home/cvs/cvsroot/gnucash/src/import-export/hbci/hbci-interaction.c,v
retrieving revision 1.16.4.12
retrieving revision 1.16.4.13
diff -Lsrc/import-export/hbci/hbci-interaction.c -Lsrc/import-export/hbci/hbci-interaction.c -u -r1.16.4.12 -r1.16.4.13
--- src/import-export/hbci/hbci-interaction.c
+++ src/import-export/hbci/hbci-interaction.c
@@ -167,7 +167,9 @@
g_assert(i);
GNCInteractor_show_nodelete(i);
/* Clear log window. */
- gtk_editable_delete_text (GTK_EDITABLE (i->log_text), 0, -1);
+ gtk_text_buffer_set_text
+ (gtk_text_view_get_buffer (GTK_TEXT_VIEW (i->log_text) ),
+ "", 0);
}
@@ -605,6 +607,7 @@
/* GNCInteractor_add_log_text (data, text); */
/* Set progress bar */
+ gtk_widget_set_sensitive (data->action_progress, TRUE);
gtk_progress_set_percentage (GTK_PROGRESS (data->action_progress),
0.0);
data->action_max = total;
@@ -693,20 +696,12 @@
int debug_pmonitor = FALSE;
void GNCInteractor_add_log_text (GNCInteractor *data, const char *msg)
{
- int pos;
+ GtkTextBuffer *tb;
g_assert(data);
- //
- // DRH - Fix me. This is a GtkTextView now, not a GtkText. These
- // casts to an editable will fail at runtime.
- //
- // pos = gtk_text_get_length (GTK_TEXT (data->log_text));
- gtk_editable_insert_text (GTK_EDITABLE (data->log_text),
- msg, strlen (msg),
- &pos);
- gtk_editable_insert_text (GTK_EDITABLE (data->log_text),
- "\n", 1,
- &pos);
+ tb = gtk_text_view_get_buffer (GTK_TEXT_VIEW (data->log_text) );
+ gtk_text_buffer_insert_at_cursor (tb, msg, -1);
+ gtk_text_buffer_insert_at_cursor (tb, "\n", -1);
}
static void
Index: dialog-hbcitrans.c
===================================================================
RCS file: /home/cvs/cvsroot/gnucash/src/import-export/hbci/dialog-hbcitrans.c,v
retrieving revision 1.9.4.12
retrieving revision 1.9.4.13
diff -Lsrc/import-export/hbci/dialog-hbcitrans.c -Lsrc/import-export/hbci/dialog-hbcitrans.c -u -r1.9.4.12 -r1.9.4.13
--- src/import-export/hbci/dialog-hbcitrans.c
+++ src/import-export/hbci/dialog-hbcitrans.c
@@ -75,7 +75,7 @@
GtkWidget *recp_bankname_label;
/* The template choosing GtkList */
- GtkWidget *template_gtk_list;
+ GtkWidget *template_gtktreeview;
/* The selected template in the list */
GtkWidget *selected_template;
@@ -194,7 +194,7 @@
static void fill_template_list_func(gpointer data, gpointer user_data)
{
GNCTransTempl *templ = data;
- GtkList *list = user_data;
+ GtkTreeView *list = user_data;
GtkWidget *item;
g_assert(templ);
@@ -303,7 +303,7 @@
g_assert
((exec_later_button = glade_xml_get_widget (xml, "exec_later_button")) != NULL);
g_assert
- ((td->template_gtk_list = glade_xml_get_widget (xml, "template_list")) != NULL);
+ ((td->template_gtktreeview = glade_xml_get_widget (xml, "template_list")) != NULL);
g_assert
((add_templ_button = glade_xml_get_widget (xml, "add_templ_button")) != NULL);
g_assert
@@ -322,6 +322,16 @@
gnc_amount_edit_set_fraction (GNC_AMOUNT_EDIT (td->amount_edit),
xaccAccountGetCommoditySCU (gnc_acc));
+ /* FIXME: Greyed out the template widgets because they are not yet
+ implemented -- need to change the GTK_LIST code to
+ GTK_TREE_VIEW */
+ gtk_widget_set_sensitive (td->template_gtktreeview, FALSE);
+ gtk_widget_set_sensitive (add_templ_button, FALSE);
+ gtk_widget_set_sensitive (moveup_templ_button, FALSE);
+ gtk_widget_set_sensitive (movedown_templ_button, FALSE);
+ gtk_widget_set_sensitive (sort_templ_button, FALSE);
+ gtk_widget_set_sensitive (del_templ_button, FALSE);
+
/* Check for what kind of transaction this should be, and change
the labels accordingly. */
switch (trans_type) {
@@ -372,8 +382,9 @@
hbci_bankid);
/* fill list for choosing a transaction template */
- g_list_foreach(td->templ, fill_template_list_func,
- GTK_LIST (td->template_gtk_list));
+ /* g_list_foreach(td->templ, fill_template_list_func,
+ GTK_TREE_VIEW (td->template_gtktreeview)); */
+ /* FIXME: commented out until the GTK_TREE_VIEW is implemented! */
td->selected_template = NULL;
td->templ_changed = FALSE;
@@ -382,7 +393,7 @@
/* gnc_option_menu_init_w_signal (td->template_option,
GTK_SIGNAL_FUNC(template_selection_cb),
td); */
- gtk_signal_connect (GTK_OBJECT (td->template_gtk_list), "select_child",
+ gtk_signal_connect (GTK_OBJECT (td->template_gtktreeview), "select_child",
GTK_SIGNAL_FUNC (on_template_list_select_child),
td);
@@ -880,7 +891,7 @@
if (td->selected_template) {
t = gtk_object_get_user_data(GTK_OBJECT(td->selected_template));
- index = 1+gtk_list_child_position(GTK_LIST(td->template_gtk_list), td->selected_template);
+ index = 1+gtk_list_child_position(GTK_LIST(td->template_gtktreeview), td->selected_template);
}
else index = 0;
@@ -888,16 +899,16 @@
td->templ_changed = TRUE;
- gtk_list_clear_items(GTK_LIST(td->template_gtk_list), 0, -1);
+ gtk_list_clear_items(GTK_LIST(td->template_gtktreeview), 0, -1);
/* fill list for choosing a transaction template */
g_list_foreach(td->templ, fill_template_list_func,
- GTK_LIST (td->template_gtk_list));
+ GTK_TREE_VIEW (td->template_gtktreeview));
- gtk_list_select_item(GTK_LIST(td->template_gtk_list), index);
+ gtk_list_select_item(GTK_LIST(td->template_gtktreeview), index);
/* the show_all is necessary since otherwise the new item doesn't show up */
- gtk_widget_show_all (GTK_WIDGET ( GTK_LIST (td->template_gtk_list)));
+ gtk_widget_show_all (GTK_WIDGET ( GTK_LIST (td->template_gtktreeview)));
}
}
@@ -914,22 +925,22 @@
if (td->selected_template) {
t = gtk_object_get_user_data(GTK_OBJECT(td->selected_template));
- index = gtk_list_child_position(GTK_LIST(td->template_gtk_list), td->selected_template);
+ index = gtk_list_child_position(GTK_LIST(td->template_gtktreeview), td->selected_template);
if (index > 0) {
td->templ = g_list_remove( td->templ, t);
td->templ = g_list_insert( td->templ, t, index-1);
td->templ_changed = TRUE;
- gtk_list_clear_items(GTK_LIST(td->template_gtk_list), 0, -1);
+ gtk_list_clear_items(GTK_LIST(td->template_gtktreeview), 0, -1);
/* fill list for choosing a transaction template */
g_list_foreach(td->templ, fill_template_list_func,
- GTK_LIST (td->template_gtk_list));
+ GTK_TREE_VIEW (td->template_gtktreeview));
- gtk_list_select_item(GTK_LIST(td->template_gtk_list), index-1);
+ gtk_list_select_item(GTK_LIST(td->template_gtktreeview), index-1);
- gtk_widget_show_all (GTK_WIDGET ( GTK_LIST (td->template_gtk_list)));
+ gtk_widget_show_all (GTK_WIDGET ( GTK_LIST (td->template_gtktreeview)));
}
}
}
@@ -947,22 +958,22 @@
if (td->selected_template) {
t = gtk_object_get_user_data(GTK_OBJECT(td->selected_template));
- index = gtk_list_child_position(GTK_LIST(td->template_gtk_list), td->selected_template);
+ index = gtk_list_child_position(GTK_LIST(td->template_gtktreeview), td->selected_template);
if (index < g_list_length(td->templ)-1) {
td->templ = g_list_remove( td->templ, t);
td->templ = g_list_insert( td->templ, t, index+1);
td->templ_changed = TRUE;
- gtk_list_clear_items(GTK_LIST(td->template_gtk_list), 0, -1);
+ gtk_list_clear_items(GTK_LIST(td->template_gtktreeview), 0, -1);
/* fill list for choosing a transaction template */
g_list_foreach(td->templ, fill_template_list_func,
- GTK_LIST (td->template_gtk_list));
+ GTK_TREE_VIEW (td->template_gtktreeview));
- gtk_list_select_item(GTK_LIST(td->template_gtk_list), index+1);
+ gtk_list_select_item(GTK_LIST(td->template_gtktreeview), index+1);
- gtk_widget_show_all (GTK_WIDGET ( GTK_LIST (td->template_gtk_list)));
+ gtk_widget_show_all (GTK_WIDGET ( GTK_LIST (td->template_gtktreeview)));
}
}
}
@@ -989,15 +1000,15 @@
td->templ_changed = TRUE;
- gtk_list_clear_items(GTK_LIST(td->template_gtk_list), 0, -1);
+ gtk_list_clear_items(GTK_LIST(td->template_gtktreeview), 0, -1);
/* fill list for choosing a transaction template */
g_list_foreach(td->templ, fill_template_list_func,
- GTK_LIST (td->template_gtk_list));
+ GTK_TREE_VIEW (td->template_gtktreeview));
- gtk_list_unselect_all ( GTK_LIST (td->template_gtk_list) );
+ gtk_list_unselect_all ( GTK_LIST (td->template_gtktreeview) );
- gtk_widget_show_all (GTK_WIDGET ( GTK_LIST (td->template_gtk_list)));
+ gtk_widget_show_all (GTK_WIDGET ( GTK_LIST (td->template_gtktreeview)));
}
}
@@ -1016,21 +1027,21 @@
t = gtk_object_get_user_data(GTK_OBJECT(td->selected_template));
- index = gtk_list_child_position(GTK_LIST(td->template_gtk_list), td->selected_template);
+ index = gtk_list_child_position(GTK_LIST(td->template_gtktreeview), td->selected_template);
if (gnc_verify_dialog (td->parent,
FALSE, _("Do you really want to delete the template '%s'?"),
gnc_trans_templ_get_name(g_list_nth_data(td->templ, index)))) {
- gtk_list_clear_items(GTK_LIST(td->template_gtk_list), index, index+1);
+ gtk_list_clear_items(GTK_LIST(td->template_gtktreeview), index, index+1);
td->templ = g_list_remove( td->templ, t);
td->templ_changed = TRUE;
gnc_trans_templ_delete(t);
- gtk_list_unselect_all ( GTK_LIST (td->template_gtk_list) );
+ gtk_list_unselect_all ( GTK_LIST (td->template_gtktreeview) );
- gtk_widget_show_all (GTK_WIDGET ( GTK_LIST (td->template_gtk_list)));
+ gtk_widget_show_all (GTK_WIDGET ( GTK_LIST (td->template_gtktreeview)));
}
}
Index: hbci.glade
===================================================================
RCS file: /home/cvs/cvsroot/gnucash/src/import-export/hbci/glade/hbci.glade,v
retrieving revision 1.27.2.11
retrieving revision 1.27.2.12
diff -Lsrc/import-export/hbci/glade/hbci.glade -Lsrc/import-export/hbci/glade/hbci.glade -u -r1.27.2.11 -r1.27.2.12
--- src/import-export/hbci/glade/hbci.glade
+++ src/import-export/hbci/glade/hbci.glade
@@ -1614,6 +1614,7 @@
<property name="label">gtk-ok</property>
<property name="use_stock">yes</property>
<property name="use_underline">yes</property>
+ <property name="response_id">1</property>
</widget>
</child>
@@ -1625,6 +1626,7 @@
<property name="label">gtk-cancel</property>
<property name="use_stock">yes</property>
<property name="use_underline">yes</property>
+ <property name="response_id">2</property>
</widget>
</child>
</widget>
More information about the gnucash-changes
mailing list