Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/lib/libalpm/trans.h
diff options
context:
space:
mode:
authorJudd Vinet <judd@archlinux.org>2005-10-09 06:09:57 +0000
committerJudd Vinet <judd@archlinux.org>2005-10-09 06:09:57 +0000
commita36ded25eb9bdea5b73c33f993820b657f9e6623 (patch)
treecd1fede1bf2400edee18bd8542f4a426354550aa /lib/libalpm/trans.h
parent9a4719d3c5e7d75fda485e3251edba0fb96b5b27 (diff)
added conversation callback support for transactions
Diffstat (limited to 'lib/libalpm/trans.h')
-rw-r--r--lib/libalpm/trans.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/lib/libalpm/trans.h b/lib/libalpm/trans.h
index 8518e5aa..b9ca04a8 100644
--- a/lib/libalpm/trans.h
+++ b/lib/libalpm/trans.h
@@ -38,6 +38,7 @@ typedef struct __pmtrans_t {
PMList *packages; /* PMList of (pmpkg_t *) or (pmsyncpkg_t *) */
PMList *skiplist; /* PMList of (char *) */
alpm_trans_cb_event cb_event;
+ alpm_trans_cb_conv cb_conv;
} pmtrans_t;
#define FREETRANS(p) \
@@ -49,14 +50,20 @@ do { \
} while (0)
#define EVENT(t, e, d1, d2) \
do { \
- if((t) && (t)->cb_event) { \
+ if((t) && (t)->cb_conv) { \
(t)->cb_event(e, d1, d2); \
} \
} while(0)
+#define QUESTION(t, e, d1, d2, d3, r) \
+do { \
+ if((t) && (t)->cb_event) { \
+ (t)->cb_conv(e, d1, d2, d3, r); \
+ } \
+} while(0)
pmtrans_t *trans_new();
void trans_free(pmtrans_t *trans);
-int trans_init(pmtrans_t *trans, unsigned char type, unsigned char flags, alpm_trans_cb_event event);
+int trans_init(pmtrans_t *trans, unsigned char type, unsigned char flags, alpm_trans_cb_event event, alpm_trans_cb_conv conv);
int trans_sysupgrade(pmtrans_t *trans);
int trans_addtarget(pmtrans_t *trans, char *target);
int trans_prepare(pmtrans_t *trans, PMList **data);