Merge branch 'maint'

This commit is contained in:
Nicolas Goaziou 2015-02-18 02:04:39 +01:00
commit 2dd548a4e0
1 changed files with 5 additions and 2 deletions

View File

@ -543,8 +543,11 @@ There is a mode hook, and keybindings for `org-edit-src-exit' and
(defun org-src-mode-configure-edit-buffer ()
(when (org-bound-and-true-p org-src--from-org-mode)
(org-add-hook 'kill-buffer-hook
(lambda () (delete-overlay org-src--overlay)) nil 'local)
(if (org-bound-and-true-p org-src--allow-write-back-p)
(lambda ()
(when (overlayp org-edit-src-overlay)
(delete-overlay org-edit-src-overlay)))
nil 'local)
(if (org-bound-and-true-p org-edit-src-allow-write-back-p)
(progn
(setq buffer-offer-save t)
(setq buffer-file-name