| 38389:36e7d457c3d1 | 38390:44e088051f69 |
|---|---|
| 432 G_SIGNAL_ACTION, | 432 G_SIGNAL_ACTION, |
| 433 0, | 433 0, |
| 434 NULL, NULL, NULL, | 434 NULL, NULL, NULL, |
| 435 G_TYPE_NONE, | 435 G_TYPE_NONE, |
| 436 1, FB_TYPE_ID); | 436 1, FB_TYPE_ID); |
| 437 | |
| 438 /** | |
| 439 * FbApi::thread-kicked: | |
| 440 * @api: The #FbApi. | |
| 441 * @thrd: The #FbApiThread. | |
| 442 * | |
| 443 * Emitted upon the reply of a thread request when the user is no longer | |
| 444 * part of that thread. This is emitted as a result of #fb_api_thread(). | |
| 445 */ | |
| 446 g_signal_new("thread-kicked", | |
| 447 G_TYPE_FROM_CLASS(klass), | |
| 448 G_SIGNAL_ACTION, | |
| 449 0, | |
| 450 NULL, NULL, NULL, | |
| 451 G_TYPE_NONE, | |
| 452 1, G_TYPE_POINTER); | |
| 437 | 453 |
| 438 /** | 454 /** |
| 439 * FbApi::threads: | 455 * FbApi::threads: |
| 440 * @api: The #FbApi. | 456 * @api: The #FbApi. |
| 441 * @thrds: The #GSList of #FbApiThread's. | 457 * @thrds: The #GSList of #FbApiThread's. |
| 2654 g_object_unref(values); | 2670 g_object_unref(values); |
| 2655 return FALSE; | 2671 return FALSE; |
| 2656 } | 2672 } |
| 2657 | 2673 |
| 2658 if (num_users < 2 || !haself) { | 2674 if (num_users < 2 || !haself) { |
| 2659 fb_api_thread_reset(thrd, TRUE); | |
| 2660 g_object_unref(values); | 2675 g_object_unref(values); |
| 2661 return FALSE; | 2676 return FALSE; |
| 2662 } | 2677 } |
| 2663 | 2678 |
| 2664 g_object_unref(values); | 2679 g_object_unref(values); |
| 2690 | 2705 |
| 2691 fb_api_thread_reset(&thrd, FALSE); | 2706 fb_api_thread_reset(&thrd, FALSE); |
| 2692 | 2707 |
| 2693 if (!fb_api_thread_parse(api, &thrd, node, &err)) { | 2708 if (!fb_api_thread_parse(api, &thrd, node, &err)) { |
| 2694 if (G_LIKELY(err == NULL)) { | 2709 if (G_LIKELY(err == NULL)) { |
| 2695 fb_api_error(api, FB_API_ERROR_GENERAL, | 2710 if (thrd.tid) { |
| 2696 _("Failed to parse thread information")); | 2711 g_signal_emit_by_name(api, "thread-kicked", &thrd); |
| 2712 } else { | |
| 2713 fb_api_error(api, FB_API_ERROR_GENERAL, | |
| 2714 _("Failed to parse thread information")); | |
| 2715 } | |
| 2697 } else { | 2716 } else { |
| 2698 fb_api_error_emit(api, err); | 2717 fb_api_error_emit(api, err); |
| 2699 } | 2718 } |
| 2700 } else { | 2719 } else { |
| 2701 g_signal_emit_by_name(api, "thread", &thrd); | 2720 g_signal_emit_by_name(api, "thread", &thrd); |