]> Dogcows Code - chaz/homebank/blob - src/ui-transaction.h
Merge branch 'upstream'
[chaz/homebank] / src / ui-transaction.h
1 /* HomeBank -- Free, easy, personal accounting for everyone.
2 * Copyright (C) 1995-2019 Maxime DOYEN
3 *
4 * This file is part of HomeBank.
5 *
6 * HomeBank is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
10 *
11 * HomeBank is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
18 */
19
20 #ifndef __HB_TRANSACTION_GTK_H__
21 #define __HB_TRANSACTION_GTK_H__
22
23 #include "ui-split.h"
24
25
26 /* official GTK_RESPONSE are negative */
27 #define HB_RESPONSE_ADD 1
28 #define HB_RESPONSE_ADDKEEP 2
29
30
31 enum {
32 HID_AMOUNT,
33 MAX_HID_AMOUNT
34 };
35
36
37 struct deftransaction_data
38 {
39 GtkWidget *window;
40
41
42 GtkWidget *PO_date;
43 GtkWidget *PO_pay;
44 GtkWidget *ST_memo;
45 GtkWidget *ST_amount, *BT_split;
46 GtkWidget *CM_cheque;
47
48 GtkWidget *NU_mode;
49 GtkWidget *ST_info;
50 GtkWidget *PO_cat;
51 GtkWidget *LB_accfrom, *PO_acc;
52 GtkWidget *LB_accto, *PO_accto;
53 GtkWidget *ST_tags, *CY_tags;
54 GtkWidget *RA_status;
55
56 GtkWidget *IB_warnsign;
57
58 /* popover */
59 GtkWidget *MB_template;
60 GtkTreeModel *model;
61 GtkTreeModelFilter *modelfilter;
62 GtkWidget *LV_arc;
63 GtkWidget *CM_showsched;
64 GtkWidget *CM_showallacc;
65 GtkWidget *ST_search;
66
67 gint action;
68 gint accnum;
69 gint type;
70 guint32 kacc;
71 gboolean showtemplate;
72
73 Transaction *ope;
74 };
75
76
77 enum
78 {
79 LST_DSPTPL_DATAS,
80 LST_DSPTPL_NAME,
81 NUM_LST_DSPTPL
82 };
83
84
85 GtkWidget *create_deftransaction_window (GtkWindow *parent, gint type, gboolean postmode, guint32 kacc);
86 void deftransaction_set_amount(GtkWidget *widget, gdouble amount);
87 gint deftransaction_external_edit(GtkWindow *parent, Transaction *old_txn, Transaction *new_txn);
88 void deftransaction_set_transaction(GtkWidget *widget, Transaction *ope);
89 void deftransaction_get (GtkWidget *widget, gpointer user_data);
90 void deftransaction_add (GtkWidget *widget, gpointer user_data);
91 void deftransaction_dispose(GtkWidget *widget, gpointer user_data);
92 void deftransaction_set_amount_from_split(GtkWidget *widget, gdouble amount);
93
94 #endif
This page took 0.031855 seconds and 4 git commands to generate.