Skip to content

Commit

Permalink
Use idle timer
Browse files Browse the repository at this point in the history
  • Loading branch information
jcs090218 committed Nov 25, 2021
1 parent 59223a1 commit 71c9d2d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions auto-highlight-symbol.el
Original file line number Diff line number Diff line change
Expand Up @@ -953,7 +953,7 @@ You can do these operations at One Key!
(ahs-unhighlight) ; unhighlight it once here so we can see the result immediately
(when (timerp ahs-idle-timer) (cancel-timer ahs-idle-timer))
(setq ahs-idle-timer
(run-with-timer
(run-with-idle-timer
;; if switch window, immediately change focus/unfocus unless the user
;; doesn't want us to
(if (or (eq ahs-selected-window (selected-window))
Expand Down Expand Up @@ -1154,8 +1154,7 @@ You can do these operations at One Key!
(if (ahs-face-p face 'ahs-definition-face-list)
(if current ahs-definition-face
ahs-definition-face-unfocused)
(if current ahs-face
ahs-face-unfocused)))
(if current ahs-face ahs-face-unfocused)))
(push overlay ahs-overlay-list))))

(defun ahs-highlight (symbol beg end)
Expand Down

0 comments on commit 71c9d2d

Please sign in to comment.