mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
[autoclear] show cleared splits is optional
This commit is contained in:
@@ -50,6 +50,7 @@ struct _AutoClearWindow
|
||||
GNCAmountEdit *end_value;/* The ending value */
|
||||
GtkWidget *ok_button;
|
||||
GtkWidget *cancel_button;
|
||||
GtkWidget *show_cleared_splits_button;
|
||||
GtkLabel *status_label;
|
||||
};
|
||||
|
||||
@@ -151,7 +152,11 @@ gnc_autoclear_window_ok_cb (GtkWidget *widget,
|
||||
for (GList *node = toclear_list; node; node = node->next)
|
||||
xaccSplitSetReconcile (node->data, CREC);
|
||||
xaccAccountCommitEdit (data->account);
|
||||
show_cleared_splits (toclear_list);
|
||||
|
||||
if (gtk_toggle_button_get_active
|
||||
(GTK_TOGGLE_BUTTON (data->show_cleared_splits_button)))
|
||||
show_cleared_splits (toclear_list);
|
||||
|
||||
g_list_free (toclear_list);
|
||||
|
||||
/* Close window */
|
||||
@@ -207,6 +212,9 @@ autoClearWindow (GtkWidget *parent, Account *account)
|
||||
// Set the name for this dialog so it can be easily manipulated with css
|
||||
gtk_widget_set_name (GTK_WIDGET(data->window), "gnc-id-auto-clear");
|
||||
|
||||
data->show_cleared_splits_button =
|
||||
GTK_WIDGET (gtk_builder_get_object (builder, "show_cleared_splits_button"));
|
||||
|
||||
/* Add amount edit box */
|
||||
data->end_value = GNC_AMOUNT_EDIT(gnc_amount_edit_new());
|
||||
g_signal_connect(GTK_WIDGET(data->end_value), "activate",
|
||||
|
||||
@@ -135,6 +135,22 @@ Use this dialog if you want GnuCash to automatically find which transactions are
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="show_cleared_splits_button">
|
||||
<property name="label" translatable="yes">_Review cleared splits</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="tooltip_text" translatable="yes">Select this option to open a register tab with newly cleared splits.</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
|
||||
Reference in New Issue
Block a user