pidgin/plugins/perl/common/GtkConv.xs

Sat, 28 Apr 2007 02:33:40 +0000

author
Luke Schierer <lschiere@pidgin.im>
date
Sat, 28 Apr 2007 02:33:40 +0000
changeset 16621
616dc666cfb8
parent 15899
75f0041f72b8
child 18068
b6554e3c8224
child 34659
4fc616843cb2
permissions
-rw-r--r--

Quoth Charkins:
This patch has two changes:

"This patch has two changes:

First is to slightly change the re-creation behavior of the docklet. Sadrul pointed out on gaim-devel that the x11 docklet re-creates itself when it is destroyed and thought this might be causing problems with fluxbox. This patch now distinguishes between initial creation and re-creation. When re-creating, the docklet no longer registers itself as a visibility manager until it successfully embeds.

Second is to change the timeout behavior for embedding. Because the notification area API is asynchronous, gaim assumes the docklet gets embeded for a certain timeout period, allowing the buddy list to start hidden before the docklet has been embeded in the notification area. If the timeout occurs, it is removed as a visibility manager and the buddy list will become visible. This timeout has been set at 5 seconds. There have been a few reports that indicate this timeout period is not long enough when starting gaim from a saved session upon login. I have been hesitant to increase the timeout, as it has the potential of delaying the startup of gaim for the timeout period if the buddy list was hidden when gaim last closed and there is not currently a notification area available. This patch makes the x11 docklet track whether it was successfully embedded and uses a longer timeout (15 seconds in this patch) only if it successfully embedded on the previous execution. Otherwise, it uses the shorter 5 second timeout. "

14478
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
1 #include "gtkmodule.h"
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
2
15590
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
3 MODULE = Pidgin::Conversation PACKAGE = Pidgin::Conversation PREFIX = pidgin_conv_
14478
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
4 PROTOTYPES: ENABLE
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
5
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
6 void
15590
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
7 pidgin_conv_update_buddy_icon(conv)
15899
75f0041f72b8 Pidgin perl fixes for s/gaim/purple/.
Daniel Atallah <datallah@pidgin.im>
parents: 15711
diff changeset
8 Purple::Conversation conv
14478
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
9
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
10 void
15590
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
11 pidgin_conv_switch_active_conversation(conv)
15899
75f0041f72b8 Pidgin perl fixes for s/gaim/purple/.
Daniel Atallah <datallah@pidgin.im>
parents: 15711
diff changeset
12 Purple::Conversation conv
14478
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
13
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
14 void
15590
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
15 pidgin_conv_update_buttons_by_protocol(conv)
15899
75f0041f72b8 Pidgin perl fixes for s/gaim/purple/.
Daniel Atallah <datallah@pidgin.im>
parents: 15711
diff changeset
16 Purple::Conversation conv
14478
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
17
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
18 void
15590
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
19 pidgin_conv_present_conversation(conv)
15899
75f0041f72b8 Pidgin perl fixes for s/gaim/purple/.
Daniel Atallah <datallah@pidgin.im>
parents: 15711
diff changeset
20 Purple::Conversation conv
14478
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
21
15590
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
22 Pidgin::Conversation::Window
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
23 pidgin_conv_get_window(conv)
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
24 Pidgin::Conversation conv
14478
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
25
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
26 void
15590
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
27 pidgin_conv_new(class, conv)
15899
75f0041f72b8 Pidgin perl fixes for s/gaim/purple/.
Daniel Atallah <datallah@pidgin.im>
parents: 15711
diff changeset
28 Purple::Conversation conv
14652
eb05a313591c [gaim-migrate @ 17314]
Etan Reisner <deryni@pidgin.im>
parents: 14641
diff changeset
29 C_ARGS:
eb05a313591c [gaim-migrate @ 17314]
Etan Reisner <deryni@pidgin.im>
parents: 14641
diff changeset
30 conv
14478
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
31
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
32 gboolean
15590
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
33 pidgin_conv_is_hidden(gtkconv)
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
34 Pidgin::Conversation gtkconv
14478
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
35
15127
5fc0e97f117d [gaim-migrate @ 17849]
Daniel Atallah <datallah@pidgin.im>
parents: 14780
diff changeset
36 void
15590
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
37 pidgin_conv_get_gtkconv(conv)
15899
75f0041f72b8 Pidgin perl fixes for s/gaim/purple/.
Daniel Atallah <datallah@pidgin.im>
parents: 15711
diff changeset
38 Purple::Conversation conv
15127
5fc0e97f117d [gaim-migrate @ 17849]
Daniel Atallah <datallah@pidgin.im>
parents: 14780
diff changeset
39 PPCODE:
15711
cd8a32e0e0b5 I like being able to compile :-)
Luke Schierer <lschiere@pidgin.im>
parents: 15590
diff changeset
40 if (conv != NULL && PIDGIN_IS_PIDGIN_CONVERSATION(conv))
15899
75f0041f72b8 Pidgin perl fixes for s/gaim/purple/.
Daniel Atallah <datallah@pidgin.im>
parents: 15711
diff changeset
41 XPUSHs(sv_2mortal(purple_perl_bless_object(
15590
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
42 PIDGIN_CONVERSATION(conv),
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
43 "Pidgin::Conversation")));
15127
5fc0e97f117d [gaim-migrate @ 17849]
Daniel Atallah <datallah@pidgin.im>
parents: 14780
diff changeset
44
15590
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
45 MODULE = Pidgin::Conversation PACKAGE = Pidgin::Conversations PREFIX = pidgin_conversations_
14478
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
46 PROTOTYPES: ENABLE
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
47
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
48 void
15590
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
49 pidgin_conversations_find_unseen_list(type, min_state, hidden_only, max_count)
15899
75f0041f72b8 Pidgin perl fixes for s/gaim/purple/.
Daniel Atallah <datallah@pidgin.im>
parents: 15711
diff changeset
50 Purple::ConversationType type
75f0041f72b8 Pidgin perl fixes for s/gaim/purple/.
Daniel Atallah <datallah@pidgin.im>
parents: 15711
diff changeset
51 Pidgin::UnseenState min_state
14478
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
52 gboolean hidden_only
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
53 guint max_count
a6b831ab1d13 [gaim-migrate @ 17124]
Etan Reisner <deryni@pidgin.im>
parents:
diff changeset
54
15899
75f0041f72b8 Pidgin perl fixes for s/gaim/purple/.
Daniel Atallah <datallah@pidgin.im>
parents: 15711
diff changeset
55 Purple::Handle
15590
c07dd12bf3f4 Partial fix for pidgin perl support. Fixing fully is going to require a decision on splitting from some of the core perl support - more than I want to deal with right now.
Daniel Atallah <datallah@pidgin.im>
parents: 15435
diff changeset
56 pidgin_conversations_get_handle()

mercurial