anchor.diff:  
   ;;;; Signal registration
   
  +(defvar *registered-signals* ())
  +
   (defbinding %signal-newv (name itype flags return-type param-types) 
       unsigned-int
     ((signal-name-to-string name) string)
  
positive.code: 
  (define-flags-type connect-flags :after :swapped)
  
  (defvar *overridden-signals* (make-hash-table :test 'equalp))
  
  (defbinding %signal-override-class-closure () nil
    (signal-id unsigned-int)
    (type-number type-number)
    (callback-closure pointer))
  
  
  (defun signal-override-class-closure (name type function)
    (let* ((signal-id (ensure-signal-id-from-type name type))
  	 (type-number (find-type-number type t))
  	 (callback-id (gethash (cons type-number signal-id) *overridden-signals*)))
      (if callback-id
  	(update-user-data callback-id function)
        (multiple-value-bind (callback-closure callback-id)
  	  (make-callback-closure function class-handler-marshal)
  	(%signal-override-class-closure signal-id type-number callback-closure)
  	(setf 
  	 (gethash (cons type-number signal-id) *overridden-signals*)
  	 callback-id)))))
  
  
  (defbinding %signal-chain-from-overridden () nil
    (args pointer)
  
negative.code: ;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
  ;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  
  ;; $Id: gcallback.lisp,v 1.51 2009-02-10 15:18:15 espen Exp $
  
  (in-package "GLIB")
  
  