summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1995-08-08 21:18:36 +0000
committerRichard M. Stallman <rms@gnu.org>1995-08-08 21:18:36 +0000
commitfab2e906baee1924e34d9006dfb7998eb3b40d5f (patch)
tree5f5595f6e61a4d7a6bdeeecb5ae03308d4f60360 /lisp
parentd544c776f62b54b76f55e61f00bda00a3cc4f489 (diff)
downloademacs-fab2e906baee1924e34d9006dfb7998eb3b40d5f.tar.gz
emacs-fab2e906baee1924e34d9006dfb7998eb3b40d5f.tar.bz2
emacs-fab2e906baee1924e34d9006dfb7998eb3b40d5f.zip
(vc-revert-buffer): In a dedicated solitary window,
make the frame invisible instead of trying to delete window.
Diffstat (limited to 'lisp')
-rw-r--r--lisp/vc.el10
1 files changed, 8 insertions, 2 deletions
diff --git a/lisp/vc.el b/lisp/vc.el
index af950518703..fa38ca4f0d5 100644
--- a/lisp/vc.el
+++ b/lisp/vc.el
@@ -1372,11 +1372,17 @@ the file on the branch you are editing."
(if (and changed (or vc-suppress-confirm
(not (yes-or-no-p "Discard changes? "))))
(progn
- (delete-window)
+ (if (and (window-dedicated-p (selected-window))
+ (one-window-p t 'selected-frame))
+ (make-frame-invisible (selected-frame))
+ (delete-window))
(error "Revert cancelled"))
(set-buffer obuf))
(if changed
- (delete-window))
+ (if (and (window-dedicated-p (selected-window))
+ (one-window-p t 'selected-frame))
+ (make-frame-invisible (selected-frame))
+ (delete-window)))
(vc-backend-revert file)
(vc-resynch-window file t t)
)