Mercurial > pidgin
annotate plugins/ipc-test-server.c @ 12115:e9790eb93216
[gaim-migrate @ 14415]
quoth charkins:
" This patch has a few small fixes for the visibility
stuff in gtkblist.c.
First, tracking of the ICONIFIED state of the blist was
removed. This was intended to allow the blist to
"remember" if it was minimized between restarts.
Unfortunately, this is not possible because the
ICONIFIED state gets set when the blist is on a
different desktop with many window managers.
Second, while talking about the ICONIFIED issue on
#gtk@GIMPNet, muntyan_ asked about a bug where the
blist would get shown on an account re-connect with
1.5.0. Luke mentioned something about this with cvs as
well. This patch introduces a check in
gaim_gtk_blist_show() to prevent the window from being
shown if it already exists and is visible.
Third, sadrul pointed me to a one-line fix for the
missing blist on startup. I added a second line to make
sure the blist restores its proper size as well.
Finally, when the last visibility manager is removed,
gaim will now minimize the blist if it was previously
hidden, rather than showing it. This could prevent a
race condition with out-of-process applets, preventing
gaim from maintaining the visibility state properly
between restarts.
This was 'cvs diff'ed against the last available anon
cvs from Friday. Hopefully it'll apply cleanly."
it did.
committer: Tailor Script <tailor@pidgin.im>
author | Luke Schierer <lschiere@pidgin.im> |
---|---|
date | Wed, 16 Nov 2005 17:55:26 +0000 |
parents | bb0d7b719af2 |
children |
rev | line source |
---|---|
6822 | 1 /* |
2 * IPC test server plugin. | |
3 * | |
4 * Copyright (C) 2003 Christian Hammond. | |
5 * | |
6 * This program is free software; you can redistribute it and/or | |
7 * modify it under the terms of the GNU General Public License as | |
8 * published by the Free Software Foundation; either version 2 of the | |
9 * License, or (at your option) any later version. | |
10 * | |
11 * This program is distributed in the hope that it will be useful, but | |
12 * WITHOUT ANY WARRANTY; without even the implied warranty of | |
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
14 * General Public License for more details. | |
15 * | |
16 * You should have received a copy of the GNU General Public License | |
17 * along with this program; if not, write to the Free Software | |
18 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA | |
19 * 02111-1307, USA. | |
20 */ | |
21 #define IPC_TEST_SERVER_PLUGIN_ID "core-ipc-test-server" | |
22 | |
23 #include "internal.h" | |
24 #include "debug.h" | |
25 #include "plugin.h" | |
9954 | 26 #include "version.h" |
6822 | 27 |
28 static int | |
29 add_func(int i1, int i2) | |
30 { | |
31 gaim_debug_misc("ipc-test-server", "Got %d, %d, returning %d\n", | |
32 i1, i2, i1 + i2); | |
33 return i1 + i2; | |
34 } | |
35 | |
36 static int | |
37 sub_func(int i1, int i2) | |
38 { | |
39 gaim_debug_misc("ipc-test-server", "Got %d, %d, returning %d\n", | |
40 i1, i2, i1 - i2); | |
41 return i1 - i2; | |
42 } | |
43 | |
44 static gboolean | |
45 plugin_load(GaimPlugin *plugin) | |
46 { | |
47 gaim_plugin_ipc_register(plugin, "add", GAIM_CALLBACK(add_func), | |
48 gaim_marshal_INT__INT_INT, | |
49 gaim_value_new(GAIM_TYPE_INT), 2, | |
50 gaim_value_new(GAIM_TYPE_INT), | |
51 gaim_value_new(GAIM_TYPE_INT)); | |
52 | |
53 gaim_plugin_ipc_register(plugin, "sub", GAIM_CALLBACK(sub_func), | |
54 gaim_marshal_INT__INT_INT, | |
55 gaim_value_new(GAIM_TYPE_INT), 2, | |
56 gaim_value_new(GAIM_TYPE_INT), | |
57 gaim_value_new(GAIM_TYPE_INT)); | |
58 | |
59 return TRUE; | |
60 } | |
61 | |
62 static GaimPluginInfo info = | |
63 { | |
9954 | 64 GAIM_PLUGIN_MAGIC, |
65 GAIM_MAJOR_VERSION, | |
66 GAIM_MINOR_VERSION, | |
6822 | 67 GAIM_PLUGIN_STANDARD, /**< type */ |
68 NULL, /**< ui_requirement */ | |
69 0, /**< flags */ | |
70 NULL, /**< dependencies */ | |
71 GAIM_PRIORITY_DEFAULT, /**< priority */ | |
72 | |
73 IPC_TEST_SERVER_PLUGIN_ID, /**< id */ | |
74 N_("IPC Test Server"), /**< name */ | |
75 VERSION, /**< version */ | |
76 /** summary */ | |
77 N_("Test plugin IPC support, as a server."), | |
78 /** description */ | |
79 N_("Test plugin IPC support, as a server. This registers the IPC " | |
80 "commands."), | |
81 "Christian Hammond <chipx86@gnupdate.org>", /**< author */ | |
82 GAIM_WEBSITE, /**< homepage */ | |
83 | |
84 plugin_load, /**< load */ | |
11256
bb0d7b719af2
[gaim-migrate @ 13430]
Gary Kramlich <grim@reaperworld.com>
parents:
11033
diff
changeset
|
85 NULL, /**< unload */ |
6822 | 86 NULL, /**< destroy */ |
87 | |
88 NULL, /**< ui_info */ | |
8993 | 89 NULL, /**< extra_info */ |
90 NULL, | |
91 NULL | |
6822 | 92 }; |
93 | |
94 static void | |
95 init_plugin(GaimPlugin *plugin) | |
96 { | |
97 } | |
98 | |
99 GAIM_INIT_PLUGIN(ipctestserver, init_plugin, info) |