chiark
/
gitweb
/
~mdw
/
clg
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
fb9bc91
)
Stock item bindings updated to Gtk+ 2.8
author
espen
<espen>
Sun, 26 Feb 2006 21:19:02 +0000
(21:19 +0000)
committer
espen
<espen>
Sun, 26 Feb 2006 21:19:02 +0000
(21:19 +0000)
gtk/gtk.lisp
patch
|
blob
|
blame
|
history
diff --git
a/gtk/gtk.lisp
b/gtk/gtk.lisp
index 3a66823ce0bc2c1ff22232082979375db83dbd72..6a95c27215fd01351ce4b2f4817bfbfa082591ea 100644
(file)
--- a/
gtk/gtk.lisp
+++ b/
gtk/gtk.lisp
@@
-20,7
+20,7
@@
;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-;; $Id: gtk.lisp,v 1.5
5 2006/02/26 15:20:46
espen Exp $
+;; $Id: gtk.lisp,v 1.5
6 2006/02/26 21:19:02
espen Exp $
(in-package "GTK")
(in-package "GTK")
@@
-2245,13
+2245,22
@@
(defbinding %stock-lookup () boolean
(location pointer))
(defun stock-lookup (stock-id)
(location pointer))
(defun stock-lookup (stock-id)
- (let ((location
- (allocate-memory (foreign-size (find-class 'stock-item)))))
- (unwind-protect
- (when (%stock-lookup stock-id location)
- (ensure-proxy-instance 'stock-item (%stock-item-copy location)))
- (deallocate-memory location))))
+ (with-allocated-memory (stock-item (foreign-size (find-class 'stock-item)))
+ (when (%stock-lookup stock-id stock-item)
+ (ensure-proxy-instance 'stock-item (%stock-item-copy stock-item)))))
+#+gtk2.8
+(progn
+ (define-callback-marshal %stock-translate-callback string ((path string)))
+
+ (defbinding (stock-set-translate-function "gtk_stock_set_translate_func")
+ (domain function) nil
+ (domain string)
+ (%stock-translate-callback callback)
+ ((register-callback-function function) unsigned-int)
+ (user-data-destroy-callback callback)))
+
+
;;; Tooltips
;;; Tooltips