commit fe62cb4767964ba51a7c1610cdcfb0752f5df1ff
parent c6c7b4c058e26cab2ec653a992e56cdb880df310
Author: Suraj N. Kurapati <sunaku@gmail.com>
Date: Sun, 10 Sep 2006 17:46:30 -0700
[project @ d308b644d9952128c9b0d4ed161c6c8e86ed133b]
[project @ 47]
revert to old tagging rules handling
Diffstat:
wmiirc | | | 30 | +++++++++--------------------- |
1 file changed, 9 insertions(+), 21 deletions(-)
diff --git a/wmiirc b/wmiirc
@@ -53,18 +53,19 @@ WM.def.colmode = 'default'
WM.def.colwidth = 0
WM.def.rules = <<EOS
-/MPlayer/ -> ~
+/jEdit.*/ -> code
+/Buddy List.*/ -> chat
+/XChat.*/ -> chat
+/.*thunderbird.*/ -> mail
+/Gimp.*/ -> gimp
+/QEMU.*/ -> ~
+/MPlayer.*/ -> ~
+/xconsole.*/ -> ~
+/alsamixer.*/ -> ~
/.*/ -> !
/.*/ -> 1
EOS
-TAGGING_RULES = [
- [:code, /jEdit/],
- [:chat, /gaim/, /xchat/],
- [:mail, /thunderbird/i, /azureus/i],
- [:gimp, /gimp/],
-]
-
## KEY CONFIGURATION
@@ -440,19 +441,6 @@ begin
Wmii::Client.new("/client/#{client}").invert_selection!
end
- when 'CreateClient'
- client = Wmii::Client.new("/client/#{arg}")
- info = client[:class]
-
- TAGGING_RULES.each do |(tag, *regexps)|
- regexps.each do |r|
- if info =~ r
- client.tags = tag
- raise
- end
- end
- end rescue nil
-
when 'Key'
SHORTCUTS[arg].call
end