Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Small bugfix to clean up old occurrences when calling from isearch #32

Merged
merged 2 commits into from

2 participants

Mark Needham victorhge
Mark Needham

No description provided.

mbneedham added some commits
Mark Needham mbneedham Update iedit-lib.el ceb7298
Mark Needham mbneedham clean up old occurrences when calling from isearch
If iedit-mode-from-isearch is called when iedit is already active, 
it's possible to have overlays for two different patterns at the same time.
This cleans up the old occurrences before making new ones.
46d5f65
victorhge victorhge merged commit 79d0f4f into from
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jan 19, 2013
  1. Mark Needham

    Update iedit-lib.el

    mbneedham authored
Commits on Jan 25, 2013
  1. Mark Needham

    clean up old occurrences when calling from isearch

    mbneedham authored
    If iedit-mode-from-isearch is called when iedit is already active, 
    it's possible to have overlays for two different patterns at the same time.
    This cleans up the old occurrences before making new ones.
This page is out of date. Refresh to see the latest.
Showing with 3 additions and 1 deletion.
  1. +1 −1  iedit-lib.el
  2. +2 −0  iedit.el
2  iedit-lib.el
View
@@ -773,7 +773,7 @@ Return nil if occurrence string is empty string."
(if ov
(let ((beg (overlay-start ov))
(end (overlay-end ov)))
- (if (and ov (/= beg end))
+ (if (/= beg end)
(buffer-substring-no-properties beg end)
nil))
nil)))
2  iedit.el
View
@@ -362,6 +362,8 @@ Keymap used within overlays:
(isearch-exit)
(setq mark-active nil)
(run-hooks 'deactivate-mark-hook)
+ (when iedit-mode
+ (iedit-cleanup))
(iedit-start regexp (point-min) (point-max))
;; TODO: reconsider how to avoid the loop in iedit-same-length
(cond ((not iedit-occurrences-overlays)
Something went wrong with that request. Please try again.