pidgin.vv: 1c835724: Remove some of the deprecated API.
maiku at soc.pidgin.im
maiku at soc.pidgin.im
Tue Jan 13 08:46:27 EST 2009
-----------------------------------------------------------------
Revision: 1c8357244603e0d86b5df08b5df711f916c01347
Ancestor: 5dab0faac3cd79a0ff33b8562bd6141739392e39
Author: maiku at soc.pidgin.im
Date: 2009-01-13T13:43:13
Branch: im.pidgin.pidgin.vv
URL: http://d.pidgin.im/viewmtn/revision/info/1c8357244603e0d86b5df08b5df711f916c01347
Modified files:
finch/gntmedia.c libpurple/media.c libpurple/media.h
libpurple/protocols/jabber/google.c
libpurple/protocols/jabber/jingle/rtp.c pidgin/gtkblist.c
pidgin/gtkconv.c
ChangeLog:
Remove some of the deprecated API.
-------------- next part --------------
============================================================
--- finch/gntmedia.c a19aade6c6979fe4116584e957110ec9b830532c
+++ finch/gntmedia.c 43c53282dbb8bb48ff073f9c45b490d26264c7ff
@@ -359,7 +359,6 @@ call_cmd_cb(PurpleConversation *conv, co
if (!media)
return PURPLE_CMD_STATUS_FAILED;
- purple_media_wait(media);
return PURPLE_CMD_STATUS_OK;
}
============================================================
--- libpurple/media.c 606f9653f321d9fe3076606929967eece33f7f4d
+++ libpurple/media.c df0140f830b30870cdcb0c3374318563358c3d35
@@ -1215,18 +1215,6 @@ void
}
void
-purple_media_ready(PurpleMedia *media)
-{
-
-}
-
-void
-purple_media_wait(PurpleMedia *media)
-{
-
-}
-
-void
purple_media_accept(PurpleMedia *media)
{
GList *sessions;
@@ -1238,7 +1226,8 @@ purple_media_accept(PurpleMedia *media)
PurpleMediaSession *session = sessions->data;
session->accepted = TRUE;
- purple_media_emit_ready(media, session, NULL);
+ if (media->priv->initiator == FALSE)
+ purple_media_emit_ready(media, session, NULL);
}
streams = media->priv->streams;
@@ -1271,12 +1260,6 @@ void
}
void
-purple_media_got_request(PurpleMedia *media)
-{
-
-}
-
-void
purple_media_got_hangup(PurpleMedia *media)
{
g_signal_emit(media, purple_media_signals[STATE_CHANGED],
@@ -1284,26 +1267,6 @@ purple_media_got_hangup(PurpleMedia *med
NULL, NULL);
}
-void
-purple_media_got_accept(PurpleMedia *media)
-{
- GList *sessions;
- GList *streams;
-
- sessions = g_hash_table_get_values(media->priv->sessions);
-
- for (; sessions; sessions = g_list_delete_link(sessions, sessions)) {
- PurpleMediaSession *session = sessions->data;
- session->accepted = TRUE;
- }
-
- streams = media->priv->streams;
-
- for (; streams; streams = g_list_next(streams)) {
- purple_media_set_remote_candidates(streams->data);
- }
-}
-
GList*
purple_media_get_devices(const gchar *plugin)
{
@@ -1543,10 +1506,6 @@ purple_media_candidate_pair_established_
{
gchar *name;
FsParticipant *participant;
- PurpleMediaCandidate *local =
- purple_media_candidate_from_fs(native_candidate);
- PurpleMediaCandidate *remote =
- purple_media_candidate_from_fs(remote_candidate);
PurpleMediaStream *stream;
g_object_get(fsstream, "participant", &participant, NULL);
@@ -1559,9 +1518,6 @@ purple_media_candidate_pair_established_
stream->remote_candidate = fs_candidate_copy(remote_candidate);
purple_debug_info("media", "candidate pair established\n");
-
- purple_media_candidate_free(local);
- purple_media_candidate_free(remote);
}
static gboolean
============================================================
--- libpurple/media.h f36f4228fd2ed8c5a8b151a7876c5c89d488a347
+++ libpurple/media.h bc9c5718da5f8286d7ee861356d17addfc49d0be
@@ -380,20 +380,6 @@ void purple_media_error(PurpleMedia *med
void purple_media_error(PurpleMedia *media, const gchar *error, ...);
/**
- * Set the media session to the ready state.
- *
- * @param media The media object to set the state on.
- */
-void purple_media_ready(PurpleMedia *media);
-
-/**
- * Set the media session to the wait state.
- *
- * @param media The media object to set the state on.
- */
-void purple_media_wait(PurpleMedia *media);
-
-/**
* Set the media session to the accepted state.
*
* @param media The media object to set the state on.
@@ -415,13 +401,6 @@ void purple_media_hangup(PurpleMedia *me
void purple_media_hangup(PurpleMedia *media);
/**
- * Set the media session to the got_request state.
- *
- * @param media The media object to set the state on.
- */
-void purple_media_got_request(PurpleMedia *media);
-
-/**
* Set the media session to the got_hangup state.
*
* @param media The media object to set the state on.
@@ -429,13 +408,6 @@ void purple_media_got_hangup(PurpleMedia
void purple_media_got_hangup(PurpleMedia *media);
/**
- * Set the media session to the got_accept state.
- *
- * @param media The media object to set the state on.
- */
-void purple_media_got_accept(PurpleMedia *media);
-
-/**
* Enumerates a list of devices.
*
* @param plugin The name of the GStreamer plugin from which to enumerate devices.
============================================================
--- libpurple/protocols/jabber/google.c ff69ff89608fc741b080bf8c5a65236965be4c23
+++ libpurple/protocols/jabber/google.c 3887d48082256ecdc6430e1ae827bd7897d5199b
@@ -305,7 +305,6 @@ jabber_google_session_initiate(JabberStr
G_CALLBACK(google_session_ready), session);
g_signal_connect(G_OBJECT(session->media), "state-changed",
G_CALLBACK(google_session_state_changed_cb), session);
- purple_media_ready(session->media);
if (sessions == NULL)
sessions = g_hash_table_new(google_session_id_hash,
@@ -367,7 +366,6 @@ google_session_handle_initiate(JabberStr
G_CALLBACK(google_session_ready), session);
g_signal_connect(G_OBJECT(session->media), "state-changed",
G_CALLBACK(google_session_state_changed_cb), session);
- purple_media_ready(session->media);
purple_media_codec_list_free(codecs);
@@ -442,7 +440,7 @@ google_session_handle_accept(JabberStrea
purple_media_set_remote_codecs(session->media, "google-voice",
session->remote_jid, codecs);
- purple_media_got_accept(session->media);
+ purple_media_accept(session->media);
}
static void
============================================================
--- libpurple/protocols/jabber/jingle/rtp.c 3ff18322442d9a4161e9e859e88efffd3b2f6736
+++ libpurple/protocols/jabber/jingle/rtp.c 162f5f21ce6a7a7753f8c5945eb20b3ee5e43848
@@ -553,7 +553,7 @@ jingle_rtp_handle_action_internal(Jingle
/* This needs to be for the entire session, not a single content */
/* very hacky */
if (xmlnode_get_next_twin(xmlcontent) == NULL)
- purple_media_got_accept(jingle_rtp_get_media(session));
+ purple_media_accept(jingle_rtp_get_media(session));
g_object_unref(session);
break;
@@ -585,10 +585,6 @@ jingle_rtp_handle_action_internal(Jingle
candidates);
}
- /* very hacky */
- if (xmlnode_get_next_twin(xmlcontent) == NULL)
- purple_media_ready(jingle_rtp_get_media(session));
-
g_object_unref(session);
break;
}
@@ -696,9 +692,6 @@ jingle_rtp_initiate_media(JabberStream *
return NULL;
}
- purple_media_ready(media);
- purple_media_wait(media);
-
g_free(jid);
g_free(me);
============================================================
--- pidgin/gtkblist.c d2febd818b3dda2d26f212a3355eba59c94ceb6e
+++ pidgin/gtkblist.c 903b883e660c6abd83813146837feb2be2977b14
@@ -340,32 +340,22 @@ static void gtk_blist_menu_audio_call_cb
#ifdef USE_VV
static void gtk_blist_menu_audio_call_cb(GtkWidget *w, PurpleBuddy *b)
{
- PurpleMedia *media = purple_prpl_initiate_media(purple_buddy_get_account(b),
+ purple_prpl_initiate_media(purple_buddy_get_account(b),
purple_buddy_get_name(b), PURPLE_MEDIA_AUDIO);
-
- if (media) {
- purple_media_wait(media);
- }
}
static void gtk_blist_menu_video_call_cb(GtkWidget *w, PurpleBuddy *b)
{
- PurpleMedia *media = NULL;
-
/* if the buddy supports both audio and video, start a combined call,
otherwise start a pure video session */
if (purple_prpl_can_do_media(purple_buddy_get_account(b),
purple_buddy_get_name(b), PURPLE_MEDIA_AUDIO)) {
- media = purple_prpl_initiate_media(purple_buddy_get_account(b),
+ purple_prpl_initiate_media(purple_buddy_get_account(b),
purple_buddy_get_name(b), PURPLE_MEDIA_AUDIO | PURPLE_MEDIA_VIDEO);
} else {
- media = purple_prpl_initiate_media(purple_buddy_get_account(b),
+ purple_prpl_initiate_media(purple_buddy_get_account(b),
purple_buddy_get_name(b), PURPLE_MEDIA_VIDEO);
}
-
- if (media) {
- purple_media_wait(media);
- }
}
#endif
============================================================
--- pidgin/gtkconv.c f30ad0677acbbd99e4e285a42bc9660be5555ca8
+++ pidgin/gtkconv.c bdc996787c8fb4812ed6663b2dbd333fb7e231b6
@@ -7765,13 +7765,9 @@ menu_initiate_audio_call_cb(gpointer dat
PurpleConversation *conv = pidgin_conv_window_get_active_conversation(win);
PurpleAccount *account = purple_conversation_get_account(conv);
- PurpleMedia *media =
- purple_prpl_initiate_media(account,
- purple_conversation_get_name(conv),
- PURPLE_MEDIA_AUDIO);
-
- if (media)
- purple_media_wait(media);
+ purple_prpl_initiate_media(account,
+ purple_conversation_get_name(conv),
+ PURPLE_MEDIA_AUDIO);
}
static void
@@ -7781,13 +7777,9 @@ menu_initiate_video_call_cb(gpointer dat
PurpleConversation *conv = pidgin_conv_window_get_active_conversation(win);
PurpleAccount *account = purple_conversation_get_account(conv);
- PurpleMedia *media =
- purple_prpl_initiate_media(account,
- purple_conversation_get_name(conv),
- PURPLE_MEDIA_VIDEO);
-
- if (media)
- purple_media_wait(media);
+ purple_prpl_initiate_media(account,
+ purple_conversation_get_name(conv),
+ PURPLE_MEDIA_VIDEO);
}
static void
@@ -7797,13 +7789,9 @@ menu_initiate_audio_video_call_cb(gpoint
PurpleConversation *conv = pidgin_conv_window_get_active_conversation(win);
PurpleAccount *account = purple_conversation_get_account(conv);
- PurpleMedia *media =
- purple_prpl_initiate_media(account,
- purple_conversation_get_name(conv),
- PURPLE_MEDIA_AUDIO | PURPLE_MEDIA_VIDEO);
-
- if (media)
- purple_media_wait(media);
+ purple_prpl_initiate_media(account,
+ purple_conversation_get_name(conv),
+ PURPLE_MEDIA_AUDIO | PURPLE_MEDIA_VIDEO);
}
static void
More information about the Commits
mailing list