From: Eric Sherman <hyperbolist@gmail.com>
To: sup-devel <sup-devel@rubyforge.org>
Subject: [sup-devel] [PATCH] [issue4] kill buffers in buffer-list-mode with "X"
Date: Sun, 03 Jan 2010 12:09:50 -0500 [thread overview]
Message-ID: <1262538511-sup-5390@changeling.local> (raw)
---
lib/sup/modes/buffer-list-mode.rb | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/lib/sup/modes/buffer-list-mode.rb b/lib/sup/modes/buffer-list-mode.rb
index 1554cae..40f2e76 100644
--- a/lib/sup/modes/buffer-list-mode.rb
+++ b/lib/sup/modes/buffer-list-mode.rb
@@ -4,6 +4,7 @@ class BufferListMode < LineCursorMode
register_keymap do |k|
k.add :jump_to_buffer, "Jump to selected buffer", :enter
k.add :reload, "Reload buffer list", "@"
+ k.add :kill_selected_buffer, "Kill selected buffer", "X"
end
def initialize
@@ -40,6 +41,10 @@ protected
def jump_to_buffer
BufferManager.raise_to_front @bufs[curpos][1]
end
+
+ def kill_selected_buffer
+ reload if BufferManager.kill_buffer_safely @bufs[curpos][1]
+ end
end
end
--
1.6.5.7
_______________________________________________
Sup-devel mailing list
Sup-devel@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-devel
next reply other threads:[~2010-01-03 17:16 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-03 17:09 Eric Sherman [this message]
2010-01-03 22:11 ` William Morgan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1262538511-sup-5390@changeling.local \
--to=hyperbolist@gmail.com \
--cc=sup-devel@rubyforge.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox