Skip to content

Commit

Permalink
Fix recursive editing.
Browse files Browse the repository at this point in the history
  • Loading branch information
nex3 committed Sep 21, 2009
1 parent d867344 commit 8e5f53e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions perspective.el
Expand Up @@ -497,7 +497,7 @@ See also `persp-add-buffer'."
(defadvice recursive-edit (around persp-preserve-for-recursive-edit)
"Preserve the current perspective when entering a recursive edit."
(persp-save)
(let ((persp-recursive-name (persp-name persp-curr))
(let ((persp-recursive persp-curr)
(old-hash (copy-hash-table perspectives-hash)))
ad-do-it
;; We want the buffer lists that were created in the recursive edit,
Expand All @@ -511,7 +511,7 @@ See also `persp-add-buffer'."

(defadvice exit-recursive-edit (before persp-restore-after-recursive-edit)
"Restore the old perspective when exiting a recursive edit."
(if persp-recursive-name (persp-switch (persp-name persp-recursive))))
(if persp-recursive (persp-switch (persp-name persp-recursive))))

;;;###autoload
(define-minor-mode persp-mode
Expand Down

0 comments on commit 8e5f53e

Please sign in to comment.