emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: idle-timer clock gets reset upon subprocess output.


From: Richard Stallman
Subject: Re: idle-timer clock gets reset upon subprocess output.
Date: Thu, 27 Jun 2002 10:45:13 -0600 (MDT)

I think I have fixed it.  Please try this fix.

*** keyboard.c.~1.683.~ Tue Jun 18 04:21:20 2002
--- keyboard.c  Thu Jun 27 08:41:32 2002
***************
*** 664,669 ****
--- 664,674 ----
  
  static EMACS_TIME timer_idleness_start_time;
  
+ /* After Emacs stops being idle, this saves the last value
+    of timer_idleness_start_time from when it was idle.  */
+ 
+ static EMACS_TIME timer_last_idleness_start_time;
+ 
  
  /* Global variable declarations.  */
  
***************
*** 3999,4004 ****
--- 4004,4011 ----
  
    EMACS_GET_TIME (timer_idleness_start_time);
  
+   timer_last_idleness_start_time = timer_idleness_start_time;
+ 
    /* Mark all idle-time timers as once again candidates for running.  */
    for (timers = Vtimer_idle_list; CONSP (timers); timers = XCDR (timers))
      {
***************
*** 8332,8337 ****
--- 8339,8351 ----
             keymap may have changed, so replay the sequence.  */
          if (BUFFERP (key))
            {
+             EMACS_TIME initial_idleness_start_time
+               = timer_last_idleness_start_time;
+ 
+             /* Resume idle state, using the same start-time as before.  */
+             timer_start_idle ();
+             timer_idleness_start_time = initial_idleness_start_time;
+ 
              mock_input = t;
              /* Reset the current buffer from the selected window
                 in case something changed the former and not the latter.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]