Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

added a quit-window function, blatantly stolen from the magit project

  • Loading branch information...
commit dad9b430df4cc4fddd5c2a29d89264b878ca0ff7 1 parent d69121f
@fred-o fred-o authored
Showing with 8 additions and 2 deletions.
  1. +1 −1  eclim-problems.el
  2. +1 −1  eclim-project.el
  3. +6 −0 eclim.el
View
2  eclim-problems.el
@@ -56,7 +56,7 @@
(define-key map (kbd "a") 'eclim-problems-show-all)
(define-key map (kbd "e") 'eclim-problems-show-errors)
(define-key map (kbd "g") 'eclim-problems-buffer-refresh)
- (define-key map (kbd "q") 'quit-window)
+ (define-key map (kbd "q") 'eclim-quit-window)
(define-key map (kbd "w") 'eclim-problems-show-warnings)
(define-key map (kbd "f") 'eclim-problems-toggle-filefilter)
(define-key map (kbd "RET") 'eclim-problems-open-current)
View
2  eclim-project.el
@@ -47,7 +47,7 @@
(define-key map (kbd "p") 'eclim-project-update)
(define-key map (kbd "g") 'eclim-project-mode-refresh)
(define-key map (kbd "R") 'eclim-project-rename)
- (define-key map (kbd "q") 'quit-window)
+ (define-key map (kbd "q") 'eclim-quit-window)
map))
View
6 eclim.el
@@ -127,6 +127,12 @@ saved."
(defvar eclim--compressed-file-path-replacement-regexp "\\\\")
(defvar eclim--compressed-file-path-removal-regexp "^/")
+(defun eclim-quit-window (&optional kill-buffer)
+ "Bury the buffer and delete its window. With a prefix argument, kill the
+buffer instead."
+ (interactive "P")
+ (quit-window kill-buffer (selected-window)))
+
(defun string-startswith-p (string prefix)
(eq t (compare-strings string nil (string-width prefix) prefix nil nil)))
Please sign in to comment.
Something went wrong with that request. Please try again.