/[gtk-cffi]/gtk-cffi/gtk/accel-group.lisp
ViewVC logotype

Contents of /gtk-cffi/gtk/accel-group.lisp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations)
Sun Aug 28 10:30:13 2011 UTC (2 years, 7 months ago) by rklochkov
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +10 -3 lines
GtkWidget is finished
1 ;;;; -*- Mode: lisp; indent-tabs-mode: nil -*-
2 ;;;
3 ;;; accel-group -- GtkAccelGroup
4 ;;;
5 ;;; Copyright (C) 2007, Roman Klochkov <kalimehtar@mail.ru>
6 ;;;
7
8 (in-package :gtk-cffi)
9
10 (defclass accel-group (object)
11 ())
12
13 (defbitfield accel-flags
14 :visible :locked)
15
16 (defcfun "gtk_accel_group_new" :pointer)
17
18 (defmethod gconstructor ((accel-group accel-group) &key &allow-other-keys)
19 (gtk-accel-group-new))
20
21 (defcfun gtk-accel-group-connect :void
22 (accel-group pobject) (accel-key :uint) (accel-mods modifier-type)
23 (accel-flags accel-flags) (closure :pointer))
24
25 (defcfun gtk-accel-group-connect-by-path :void
26 (accel-group pobject) (accel-path :string) (closure :pointer))
27
28 (defmethod connect ((accel-group accel-group) func
29 &key path key accel-mods accel-flags)
30 "FUNC should have args: (accel-group acceleratable keyval modifier)
31 CONNECT returns foreign pointer to create GLib closure"
32 (let ((closure (make-closure func)))
33 (if path
34 (gtk-accel-group-connect-by-path accel-group path closure)
35 (gtk-accel-group-connect accel-group
36 key accel-mods accel-flags closure))
37 closure))
38
39 (defgtkfun disconnect :boolean accel-group (closure object))
40
41 (defcfun ("gtk_accel_group_from_accel_closure" accel-group-from-accel-closure)
42 pobject (closure :pointer))

  ViewVC Help
Powered by ViewVC 1.1.5