GNU bug report logs - #75361
31.0.50; run-with-idle-timer not working unless there is some activity

Previous Next

Package: emacs;

Reported by: Jean Louis <bugs <at> gnu.support>

Date: Sat, 4 Jan 2025 17:39:01 UTC

Severity: normal

Tags: notabug

Found in version 31.0.50

Done: Stefan Kangas <stefankangas <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Jean Louis <bugs <at> gnu.support>
To: Ship Mints <shipmints <at> gmail.com>
Cc: 75361 <at> debbugs.gnu.org
Subject: bug#75361: SOLVED - Re: bug#75361: 31.0.50; run-with-idle-timer not working unless there is some activity
Date: Fri, 10 Jan 2025 18:42:01 +0300
Thanks much.

(defun rcd-check-if-idle (&optional seconds)
  "Verify if Emacs is idle for number of SECONDS.

If SECONDS is not provided, default is 3 seconds."
       (cond ((and (current-idle-time) 
       	      (>= (cadr (current-idle-time)) (or seconds 3)) t))
	  (t nil)))

I am using now this function to check if user is idle while running it
`run-with-timer`.

-- 
Jean Louis




This bug report was last modified 211 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.