python: Support status callbacks.
authorJustus Winter <justus@gnupg.org>
Tue, 24 May 2016 13:14:53 +0000 (15:14 +0200)
committerJustus Winter <justus@gnupg.org>
Tue, 24 May 2016 16:00:16 +0000 (18:00 +0200)
commit8b57f06e0c04f5c9b87a3c76618230d757412076
treee7a0779263eb230b5e82cf2dd6abf2b9188655b3
parent72afb68f8c2f0cb326f20b289215402fd849339d
python: Support status callbacks.

* lang/python/helpers.c (pyStatusCb): New function.
(pygpgme_set_status_cb): Likewise.
* lang/python/helpers.h (pygpgme_set_status_cb): New prototype.
* lang/python/pyme/core.py (Context.__init__): Initialize
'last_statuscb'.
(Context._free_statuscb): New function.
(Context.set_status_cb): Likewise.
* lang/python/tests/t-callbacks.py: Test status callbacks.

Signed-off-by: Justus Winter <justus@gnupg.org>
lang/python/helpers.c
lang/python/helpers.h
lang/python/pyme/core.py
lang/python/tests/t-callbacks.py