[slime-cvs] CVS slime

CVS User sboukarev sboukarev at common-lisp.net
Sat May 1 06:12:30 UTC 2010


Update of /project/slime/cvsroot/slime
In directory cl-net:/tmp/cvs-serv6980

Modified Files:
	ChangeLog slime.el 
Log Message:
* contrib/slime-repl.el (slime-repl-update-banner): Use slime-move-point
instead of goto-char alone, ensuring that the point is moved even
if the window isn't currently selected.

* slime.el (slime-restart-sentinel): Don't pop to the inferior
buffer, since this command is usually run either from
*inferior-lisp* buffer or from REPL, it makes sense to reuse
current window instead of messing up window configuration.
(slime-move-point): New function, moves point in a buffer and
its window.


--- /project/slime/cvsroot/slime/ChangeLog	2010/04/30 03:14:35	1.2079
+++ /project/slime/cvsroot/slime/ChangeLog	2010/05/01 06:12:30	1.2080
@@ -1,3 +1,12 @@
+2010-05-01  Stas Boukarev  <stassats at gmail.com>
+
+	* slime.el (slime-restart-sentinel): Don't pop to the inferior
+	buffer, since this command is usually run either from
+	*inferior-lisp* buffer or from REPL, it makes sense to reuse
+	current window instead of messing up window configuration.
+	(slime-move-point): New function, moves point in a buffer and
+	its window.
+
 2010-04-29  Stas Boukarev  <stassats at gmail.com>
 
 	* slime.el (slime-compile-file): Run check-parens after checking
--- /project/slime/cvsroot/slime/slime.el	2010/04/30 03:14:36	1.1309
+++ /project/slime/cvsroot/slime/slime.el	2010/05/01 06:12:30	1.1310
@@ -2475,7 +2475,6 @@
                                      buffer)))
     (slime-net-close process)
     (slime-inferior-connect new-proc args)
-    (pop-to-buffer buffer)
     (switch-to-buffer buffer)
     (goto-char (point-max))))
 
@@ -6267,6 +6266,13 @@
 
 (defvar slime-thread-index-to-id nil)
 
+(defun slime-move-point (position)
+  "Move point in the current buffer and in the window the buffer is displayed."
+  (let ((window (get-buffer-window (current-buffer) t)))
+    (goto-char position)
+    (when window
+      (set-window-point window position))))
+
 ;;; FIXME: the region selection is jumping
 (defun slime-display-threads (threads)
   (with-current-buffer slime-threads-buffer-name
@@ -6283,7 +6289,7 @@
         (goto-char (point-min))
         (forward-line (1- (or new-position old-line)))
         (move-to-column old-column)
-        (set-window-point (get-buffer-window (current-buffer)) (point))))))
+        (slime-move-point (point))))))
 
 (defvar *slime-threads-table-properties*
   '(nil (face bold)))





More information about the slime-cvs mailing list