aboutsummaryrefslogtreecommitdiffstats
path: root/feature-tests/key_sig.pl
diff options
context:
space:
mode:
authorTom Feist <shabble@metavore.org>2011-12-02 11:37:00 +0000
committerTom Feist <shabble@metavore.org>2011-12-02 11:47:17 +0000
commit85f08fc4684b854d973b3ad771bfd03af2b70b87 (patch)
tree09020fa22129346491566fb1d3f3fdc314ce5756 /feature-tests/key_sig.pl
parentAdd a whole bunch of un-tracked files that need some looking at. (diff)
downloadirssi-scripts-85f08fc4684b854d973b3ad771bfd03af2b70b87.tar.gz
irssi-scripts-85f08fc4684b854d973b3ad771bfd03af2b70b87.zip
Another flagrant abuse of version control because I'm too lazy to stash.
Diffstat (limited to 'feature-tests/key_sig.pl')
-rw-r--r--feature-tests/key_sig.pl26
1 files changed, 24 insertions, 2 deletions
diff --git a/feature-tests/key_sig.pl b/feature-tests/key_sig.pl
index ef69d45..3da50ac 100644
--- a/feature-tests/key_sig.pl
+++ b/feature-tests/key_sig.pl
@@ -25,12 +25,22 @@ Irssi::signal_add('key created', \&sig_key_created);
Irssi::signal_register({'key command' => [qw/string/]});
Irssi::signal_add_first('key command' => \&sig_key_cmd);
+Irssi::signal_register({'key key' => [qw/string/]});
+Irssi::signal_add_first('key key' => \&sig_key_key);
+
Irssi::signal_register({'key nothing' => [qw/string/]});
-Irssi::signal_add_first('key nothing' => \&sig_key_cmd);
+Irssi::signal_add_first('key nothing' => \&sig_key_nothing);
Irssi::signal_register({'keyboard created' => [qw/Irssi::UI::Keyboard/]});
Irssi::signal_add_first('keyboard created' => \&sig_keyboard);
+Irssi::signal_register({'key bacon' => [qw/string int int/]});
+Irssi::signal_add_first('key bacon' => \&sig_key_bacon);
+
+sub sig_key_bacon {
+ print "baconkey: " . Dumper(\@_);
+}
+
sub sig_keyboard {
my ($data) = @_;
print "keyboard: " . Dumper($data);
@@ -42,10 +52,22 @@ sub sig_key_cmd {
}
+sub sig_key_nothing {
+ my ($data) = @_;
+ print "key nothing: " . Dumper($data);
+
+}
+
+sub sig_key_key {
+ my ($data) = @_;
+ print "key key: " . Dumper($data);
+
+}
+
sub sig_key_created {
my @args = @_;
print "Key Created, Args: " . Dumper(\@args);
}
-Irssi::command("bind meta-q /echo moo");
+Irssi::command("bind meta-q key bacon");