90 |
} |
} |
91 |
|
|
92 |
|
|
|
/* Destroy the progress dialog and cleanup. */ |
|
|
void |
|
|
keygen_cb_dlg_destroy (void) |
|
|
{ |
|
|
if (dlg_hwnd) { |
|
|
EndDialog (dlg_hwnd, TRUE); |
|
|
dlg_hwnd = NULL; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
93 |
/* GPGME progress callback function. */ |
/* GPGME progress callback function. */ |
94 |
void |
void |
95 |
keygen_cb (void * opaque, const char * what, int type, int curretn, int total) |
keygen_cb (void *opaque, const char *what, int type, int curretn, int total) |
96 |
{ |
{ |
97 |
static char cb[8192] = {0}; |
static char cb[8192] = {0}; |
98 |
static int cb_pos = 0; |
static int cb_pos = 0; |
113 |
|
|
114 |
SetDlgItemText (dlg_hwnd, IDC_KEYPROG_CB, cb); |
SetDlgItemText (dlg_hwnd, IDC_KEYPROG_CB, cb); |
115 |
} |
} |
116 |
|
|
117 |
|
|
118 |
|
/* Destroy the progress dialog and cleanup. |
119 |
|
If flush is 1 reset the callback state. */ |
120 |
|
void |
121 |
|
keygen_cb_dlg_destroy (int flush) |
122 |
|
{ |
123 |
|
if (dlg_hwnd) { |
124 |
|
EndDialog (dlg_hwnd, TRUE); |
125 |
|
dlg_hwnd = NULL; |
126 |
|
} |
127 |
|
if (flush) |
128 |
|
keygen_cb (NULL, NULL, 0, 0, 0); |
129 |
|
} |
130 |
|
|