Mercurial > pidgin.yaz
annotate plugins/gaim.pl @ 3063:22c84cbcd5a6
[gaim-migrate @ 3077]
A buddy window placement fix by Marc Deslauriers and a compile fix from Benjamin Miller. Thanks guys. Also, an irc fix.
committer: Tailor Script <tailor@pidgin.im>
author | Sean Egan <seanegan@gmail.com> |
---|---|
date | Sat, 16 Mar 2002 20:14:24 +0000 |
parents | a83b4a5ffcd6 |
children | cd938f18f3f8 |
rev | line source |
---|---|
1526
190cef255530
[gaim-migrate @ 1536]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
806
diff
changeset
|
1 GAIM::register("gaim test", "0.0.1", "goodbye", ""); |
806 | 2 |
1526
190cef255530
[gaim-migrate @ 1536]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
806
diff
changeset
|
3 $ver = GAIM::get_info(0); |
2355
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
4 @ids = GAIM::get_info(1); |
806 | 5 |
2355
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
6 $msg = "Gaim $ver:"; |
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
7 foreach $id (@ids) { |
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
8 $pro = GAIM::get_info(7, $id); |
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
9 $nam = GAIM::get_info(3, $id); |
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
10 $msg .= "\n$nam using $pro"; |
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
11 } |
806 | 12 |
2355
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
13 GAIM::print("Perl Says", $msg); |
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
14 |
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
15 GAIM::command("idle", 6000); |
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
16 |
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
17 GAIM::add_event_handler("event_buddy_signon", "echo_reply"); |
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
18 GAIM::add_timeout_handler(60, "notify"); |
806 | 19 |
20 sub echo_reply { | |
2511
a83b4a5ffcd6
[gaim-migrate @ 2524]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
2355
diff
changeset
|
21 $index = $_[0]; |
a83b4a5ffcd6
[gaim-migrate @ 2524]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
2355
diff
changeset
|
22 $who = $_[1]; |
a83b4a5ffcd6
[gaim-migrate @ 2524]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
2355
diff
changeset
|
23 GAIM::print_to_conv($index, $who, "Hello", 0); |
806 | 24 } |
25 | |
26 sub notify { | |
2355
571971659533
[gaim-migrate @ 2368]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
1526
diff
changeset
|
27 GAIM::print("1 minute", "gaim test has been loaded for 1 minute"); |
806 | 28 } |
29 | |
30 sub goodbye { | |
1526
190cef255530
[gaim-migrate @ 1536]
Eric Warmenhoven <eric@warmenhoven.org>
parents:
806
diff
changeset
|
31 GAIM::print("You Bastard!", "You killed Kenny!"); |
806 | 32 } |