# HG changeset patch # User Martin Rudalics # Date 1180419174 0 # Node ID 03efa2eaa3b70879b5cff7402a7a9e8d64d254b0 # Parent e686ba4e7a34c599f869d1bb09b058963b55ef11 (table--point-entered-cell-function) (table--point-left-cell-function): Bind `inhibit-point-motion-hooks' to t. diff -r e686ba4e7a34 -r 03efa2eaa3b7 lisp/textmodes/table.el --- a/lisp/textmodes/table.el Tue May 29 02:16:17 2007 +0000 +++ b/lisp/textmodes/table.el Tue May 29 06:12:54 2007 +0000 @@ -5333,21 +5333,25 @@ (defun table--point-entered-cell-function (&optional old-point new-point) "Point has entered a cell. Refresh the menu bar." - (unless table-cell-entered-state - (setq table-cell-entered-state t) - (setq table-mode-indicator t) - (force-mode-line-update) - (table--warn-incompatibility) - (run-hooks 'table-point-entered-cell-hook))) + ;; Avoid calling point-motion-hooks recursively. + (let ((inhibit-point-motion-hooks t)) + (unless table-cell-entered-state + (setq table-cell-entered-state t) + (setq table-mode-indicator t) + (force-mode-line-update) + (table--warn-incompatibility) + (run-hooks 'table-point-entered-cell-hook)))) (defun table--point-left-cell-function (&optional old-point new-point) "Point has left a cell. Refresh the menu bar." - (when table-cell-entered-state - (setq table-cell-entered-state nil) - (setq table-mode-indicator nil) - (force-mode-line-update) - (run-hooks 'table-point-left-cell-hook))) + ;; Avoid calling point-motion-hooks recursively. + (let ((inhibit-point-motion-hooks t)) + (when table-cell-entered-state + (setq table-cell-entered-state nil) + (setq table-mode-indicator nil) + (force-mode-line-update) + (run-hooks 'table-point-left-cell-hook)))) (defun table--warn-incompatibility () "If called from interactive operation warn the know incompatibilities.