~prateek.karandikar/ubuntu/precise/pidgin/add_quicklist

« back to all changes in this revision

Viewing changes to libpurple/protocols/jabber/google/google_session.c

  • Committer: Bazaar Package Importer
  • Author(s): Micah Gersten
  • Date: 2011-04-11 03:27:22 UTC
  • mfrom: (2.3.17 sid)
  • Revision ID: james.westby@ubuntu.com-20110411032722-farsw08i6ouj5dnd
Tags: 1:2.7.11-1ubuntu1
* Merge from Debian unstable (LP: #757146), remaining changes:
  + debian/control:
    - Add libtool and liblaunchpad-integration-dev build depends
    - Bump standards version
    - Relax binary depends on pidgin versions
    - Add pidgin-libnotify as Recommends for pidgin binary
    - Fix description of pidgin binary
    - Don't have libpurple-bin depend on libpurple0
  + debian/libpurple0.symbols: add epoch to appropriate symbols
  + Add debian/patches:
    - 02_lpi.patch
    - 04_let_crasher_for_apport.patch
    - 05_default_to_irc_ubuntu_com.patch
    - 10_docklet_default_off.patch
    - 11_buddy_list_really_show.patch
    - 13_sounds_and_timers.patch
    - 60_1024x600_gtkpounce.c.patch
    - 60_1024x600_gtkprefs.c.patch
  + debian/prefs.xml: add notification prefs
  + debian/rules:
    - Add translation domain to desktop file with gettext
    - Add the launcher for pidgin

* Add configure check for launchpad integration attached to the gtk check since 
  upstream dropped the startup notification check which is where this check was 
  previously
  - update debian/patches/02_lpi.patch

Show diffs side-by-side

added added

removed removed

Lines of Context:
62
62
 
63
63
        if (session->description)
64
64
                xmlnode_free(session->description);
65
 
        
 
65
 
66
66
        g_free(session->session_data);
67
67
        g_free(session);
68
68
}
427
427
        session->remote_jid = jid;
428
428
        session_data = g_new0(GoogleAVSessionData, 1);
429
429
        session->session_data = session_data;
430
 
        
 
430
 
431
431
        if (type & PURPLE_MEDIA_VIDEO)
432
432
                session_data->video = TRUE;
433
433
 
440
440
                jabber_google_relay_response_session_initiate_cb(session, NULL, 0, 0, 0,
441
441
                        NULL, NULL);
442
442
        }
443
 
        
 
443
 
444
444
        /* we don't actually know yet wether it succeeded... maybe this is very
445
445
         wrong... */
446
446
        return TRUE;
464
464
                (GoogleAVSessionData *) session->session_data;
465
465
 
466
466
        params =
467
 
                jabber_google_session_get_params(js, relay_ip, relay_udp, relay_tcp, 
 
467
                jabber_google_session_get_params(js, relay_ip, relay_udp, relay_tcp,
468
468
                relay_ssltcp, relay_username, relay_password, &num_params);
469
469
 
470
470
        if (purple_media_add_stream(session_data->media, "google-voice",
483
483
 
484
484
                if (session_data->remote_audio_candidates) {
485
485
                        purple_media_add_remote_candidates(session_data->media,
486
 
                                "google-voice", session->remote_jid, 
 
486
                                "google-voice", session->remote_jid,
487
487
                            session_data->remote_audio_candidates);
488
488
                        purple_media_candidate_list_free(session_data->remote_audio_candidates);
489
489
                        session_data->remote_audio_candidates = NULL;
490
490
                }
491
491
                if (session_data->remote_video_candidates) {
492
492
                        purple_media_add_remote_candidates(session_data->media,
493
 
                                "google-video", session->remote_jid, 
 
493
                                "google-video", session->remote_jid,
494
494
                            session_data->remote_video_candidates);
495
495
                        purple_media_candidate_list_free(session_data->remote_video_candidates);
496
496
                        session_data->remote_video_candidates = NULL;
497
497
                }
498
498
        }
499
 
                
 
499
 
500
500
        g_free(params);
501
501
 
502
502
        for (codec_element = xmlnode_get_child(session->description, "payload-type");
561
561
        const gchar *xmlns;
562
562
        GoogleAVSessionData *session_data =
563
563
                (GoogleAVSessionData *) session->session_data;
564
 
        
 
564
 
565
565
        if (session->state != UNINIT) {
566
566
                purple_debug_error("jabber", "Received initiate for active session.\n");
567
567
                return FALSE;
598
598
                        G_CALLBACK(google_session_stream_info_cb), session);
599
599
 
600
600
        session->iq_id = g_strdup(iq_id);
601
 
        
 
601
 
602
602
        if (js->google_relay_host && js->google_relay_token) {
603
 
                jabber_google_do_relay_request(js, session, 
 
603
                jabber_google_do_relay_request(js, session,
604
604
                        jabber_google_relay_response_session_handle_initiate_cb);
605
605
        } else {
606
606
                jabber_google_relay_response_session_handle_initiate_cb(session, NULL,
621
621
        char n[4];
622
622
        GoogleAVSessionData *session_data =
623
623
                (GoogleAVSessionData *) session->session_data;
624
 
        
 
624
 
625
625
        for (cand = xmlnode_get_child(sess, "candidate"); cand;
626
626
                        cand = xmlnode_get_next_twin(cand)) {
627
627
                PurpleMediaCandidate *info;
636
636
                if (cname && type && address && port) {
637
637
                        PurpleMediaCandidateType candidate_type;
638
638
                        guint prio = preference ? g_ascii_strtod(preference, NULL) * 1000 : 0;
639
 
                        
 
639
 
640
640
                        g_snprintf(n, sizeof(n), "S%d", name++);
641
 
                        
 
641
 
642
642
                        if (g_str_equal(type, "local"))
643
643
                                candidate_type = PURPLE_MEDIA_CANDIDATE_TYPE_HOST;
644
644
                        else if (g_str_equal(type, "stun"))
713
713
        gboolean video = (xmlns && !strcmp(xmlns, NS_GOOGLE_SESSION_VIDEO));
714
714
        GoogleAVSessionData *session_data =
715
715
                (GoogleAVSessionData *) session->session_data;
716
 
        
 
716
 
717
717
        for (; codec_element; codec_element = codec_element->next) {
718
718
                const gchar *xmlns, *encoding_name, *id,
719
719
                                *clock_rate, *width, *height, *framerate;