branch: elpa/golden-ratio
commit 2d1553431cb6a6acbb7264cc80a92e99f2ca706a
Merge: 7504957a7a af7c754985
Author: Roman Gonzalez <[email protected]>
Commit: Roman Gonzalez <[email protected]>
Merge pull request #22 from Fuco1/master
Add advice on `delete-window`
---
golden-ratio.el | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/golden-ratio.el b/golden-ratio.el
index deb99053e6..31334cd897 100644
--- a/golden-ratio.el
+++ b/golden-ratio.el
@@ -99,6 +99,9 @@ the window to be resized to the golden ratio."
(after golden-ratio-resize-window)
(golden-ratio))
+(defadvice delete-window
+ (after golden-ratio-resize-window)
+ (golden-ratio))
;;;###autoload
(defun golden-ratio-enable ()
@@ -106,7 +109,8 @@ the window to be resized to the golden ratio."
(interactive)
(ad-activate 'select-window)
(ad-activate 'other-window)
- (ad-activate 'split-window))
+ (ad-activate 'split-window)
+ (ad-activate 'delete-window))
;;;###autoload
@@ -115,7 +119,8 @@ the window to be resized to the golden ratio."
(interactive)
(ad-deactivate 'select-window)
(ad-deactivate 'other-window)
- (ad-deactivate 'split-window))
+ (ad-deactivate 'split-window)
+ (ad-deactivate 'delete-window))
(provide 'golden-ratio)