argument of passphrase-callback.
(epg-status-PROGRESS): Ditto.
 2006-04-26  Daiki Ueno  <ueno@unixuser.org>
 
+       * epg.el (epg-status-GET_HIDDEN): Pass epg-context as the first
+       argument of passphrase-callback.
+       (epg-status-PROGRESS): Ditto.
+
+2006-04-26  Daiki Ueno  <ueno@unixuser.org>
+
        * epa.el (epa-select-keys): Don't set inhibit-quit when
        recursive-edit is called.
        (epg-cancel): New function.
 
   
 (defvar epa-file-passphrase-alist nil)
 
-(defun epa-file-passphrase-callback-function (key-id file)
+(defun epa-file-passphrase-callback-function (context key-id file)
   (if (eq key-id 'SYM)
       (let ((entry (assoc file epa-file-passphrase-alist))
            passphrase)
                (setq entry (list file)
                      epa-file-passphrase-alist (cons entry
                                                 epa-file-passphrase-alist)))
-             (setq passphrase (epg-passphrase-callback-function key-id nil))
+             (setq passphrase (epg-passphrase-callback-function context
+                                                                key-id nil))
              (setcdr entry (copy-sequence passphrase))
              passphrase)))
-    (epg-passphrase-callback-function key-id nil)))
+    (epg-passphrase-callback-function context key-id nil)))
 
 (defun epa-file-handler (operation &rest args)
   (save-match-data
 
                (progn
                  (setq passphrase
                        (funcall
+                        epg-context
                         (if (consp (epg-context-passphrase-callback
                                     epg-context))
                             (car (epg-context-passphrase-callback
 (defun epg-status-PROGRESS (process string)
   (if (string-match "\\`\\([^ ]+\\) \\([^ ]\\) \\([0-9]+\\) \\([0-9]+\\)"
                    string)
-      (funcall (if (consp (epg-context-progress-callback epg-context))
+      (funcall epg-context
+              (if (consp (epg-context-progress-callback epg-context))
                   (car (epg-context-progress-callback epg-context))
                 (epg-context-progress-callback epg-context))
               (match-string 1 string)
                   (cons 'fingerprint (substring string (match-end 0))))
             (epg-context-result-for epg-context 'sign)))))
 
-(defun epg-passphrase-callback-function (key-id handback)
+(defun epg-passphrase-callback-function (context key-id handback)
   (read-passwd
    (if (eq key-id 'SYM)
        "Passphrase for symmetric encryption: "
             (format "Passphrase for %s %s: " key-id (cdr entry))
           (format "Passphrase for %s: " key-id)))))))
 
-(defun epg-progress-callback-function (what char current total handback)
+(defun epg-progress-callback-function (context what char current total
+                                              handback)
   (message "%s: %d%%/%d%%" what current total))
 
 (defun epg-configuration ()
 
 
 (defvar pgg-epg-secret-key-id-list nil)
 
-(defun pgg-epg-passphrase-callback (key-id ignore)
+(defun pgg-epg-passphrase-callback (context key-id ignore)
   (if (eq key-id 'SYM)
-      (epg-passphrase-callback-function key-id nil)
+      (epg-passphrase-callback-function context key-id nil)
     (let* ((entry (assoc key-id epg-user-id-alist))
           (passphrase
            (pgg-read-passphrase