[cells-gtk-cvs] CVS update: root/cells-gtk/gtk-app.lisp

Peter Denno pdenno at common-lisp.net
Sun May 29 21:06:47 UTC 2005


Update of /project/cells-gtk/cvsroot/root/cells-gtk
In directory common-lisp.net:/tmp/cvs-serv8059/cells-gtk

Modified Files:
	gtk-app.lisp 
Log Message:
Moved duplicated foreign loading code (substantially cleaned up) into gtk-ffi/gtk-ffi.lisp
Date: Sun May 29 23:06:47 2005
Author: pdenno

Index: root/cells-gtk/gtk-app.lisp
diff -u root/cells-gtk/gtk-app.lisp:1.13 root/cells-gtk/gtk-app.lisp:1.14
--- root/cells-gtk/gtk-app.lisp:1.13	Sat Feb 26 23:26:09 2005
+++ root/cells-gtk/gtk-app.lisp	Sun May 29 23:06:47 2005
@@ -137,23 +137,11 @@
   (funcall (aref *gtk-global-callbacks* n)))
 
 (defun cells-gtk-init ()
-  (gtk-reset)
   #-cmu
   (unless *gtk-loaded*
-    (loop for lib in '(:gthread :glib :gobject :gdk :gtk #+libcellsgtk :cgtk)
-          for libname = (gtk-ffi::libname lib)
-          with libpath = (cond ((directory "/usr/lib/libgtk*") "/usr/lib/")
-                               ((directory "/opt/gnome/lib/libgtk*") "/opt/gnome/lib/")
-                               ((find :mswindows *features*) nil)
-                               (t (error "Cannot find a path containing libgtk")))
-        do #-mswindows ;; probably have to refine this for diff implementations
-          (setq libname (uffi:find-foreign-library (gtk-ffi::libname lib) libpath))
-          (assert (or (uffi:load-foreign-library libname
-                         :force-load #+lispworks t #-lispworks nil
-                         :module (string lib))
-                      (eql lib :cgtk)))
-        finally (setf *gtk-loaded* t))
-    #-libcellsgtk(warn "libcellsgtk.so not found. Just a few capabilities will be unavailable.")))
+    (gtk-ffi:load-gtk-libs)
+    (setf *gtk-loaded* t))
+  (gtk-reset))
 
 ;;; Implements quits other than through destroy.
 (let (quit)




More information about the Cells-gtk-cvs mailing list