278
static gpointer _json_object_ref0 (gpointer self) {
279
return self ? json_object_ref (self) : NULL;
275
283
static void _lambda0_ (GwibberGtkActionBoxItem* self) {
276
g_signal_emit_by_name (self, "reply", self->priv->_mid, self->priv->_account, self->priv->_sender);
287
JsonObject* sender_obj;
288
GwibberMessages* _tmp1_ = NULL;
289
GwibberMessages* messages;
290
gchar* _tmp2_ = NULL;
292
JsonParser* _tmp3_ = NULL;
294
JsonNode* _tmp4_ = NULL;
295
JsonObject* _tmp5_ = NULL;
298
GError * _inner_error_ = NULL;
299
_tmp0_ = g_strdup ("");
303
_tmp1_ = gwibber_messages_new ();
305
_tmp2_ = gwibber_messages_get_message (messages, self->priv->_mid);
307
_tmp3_ = json_parser_new ();
309
json_parser_load_from_data (parser, msg, (gssize) (-1), &_inner_error_);
310
if (_inner_error_ != NULL) {
311
_g_object_unref0 (parser);
313
_g_object_unref0 (messages);
314
if (_inner_error_->domain == G_IO_ERROR) {
315
goto __catch1_g_io_error;
319
_tmp4_ = json_parser_get_root (parser);
320
_tmp5_ = json_node_get_object (_tmp4_);
321
_tmp6_ = _json_object_ref0 (_tmp5_);
322
_json_object_unref0 (obj);
326
_tmp7_ = json_object_has_member (obj, "sender");
328
JsonObject* _tmp8_ = NULL;
330
_tmp8_ = json_object_get_object_member (obj, "sender");
331
_tmp9_ = _json_object_ref0 (_tmp8_);
332
_json_object_unref0 (sender_obj);
334
if (sender_obj != NULL) {
336
_tmp10_ = json_object_has_member (sender_obj, "nick");
338
const gchar* _tmp11_ = NULL;
340
_tmp11_ = json_object_get_string_member (sender_obj, "nick");
341
_tmp12_ = g_strdup (_tmp11_);
348
_g_object_unref0 (parser);
350
_g_object_unref0 (messages);
356
_inner_error_ = NULL;
357
g_warning ("action-box.vala:175: %s", e->message);
361
if (_inner_error_ != NULL) {
362
_json_object_unref0 (sender_obj);
363
_json_object_unref0 (obj);
365
g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
366
g_clear_error (&_inner_error_);
369
_tmp13_ = strlen (nick);
372
_tmp14_ = g_strconcat ("@", nick, NULL);
376
g_signal_emit_by_name (self, "reply", self->priv->_mid, self->priv->_account, nick);
377
_json_object_unref0 (sender_obj);
378
_json_object_unref0 (obj);
289
392
_tmp0_ = gwibber_gtk_action_box_item_like (self, self->priv->_mid, self->priv->_account);
292
const gchar* _tmp1_ = NULL;
293
const gchar* _tmp2_ = NULL;
296
NotifyNotification* _tmp5_ = NULL;
297
NotifyNotification* _tmp6_;
400
JsonObject* sender_obj;
401
GwibberMessages* _tmp3_ = NULL;
402
GwibberMessages* messages;
403
gchar* _tmp4_ = NULL;
405
JsonParser* _tmp5_ = NULL;
407
JsonNode* _tmp6_ = NULL;
408
JsonObject* _tmp7_ = NULL;
411
const gchar* _tmp20_ = NULL;
412
const gchar* _tmp21_ = NULL;
415
NotifyNotification* _tmp24_ = NULL;
416
NotifyNotification* _tmp25_;
298
417
NotifyNotification* notification;
299
_tmp1_ = _ ("Liked");
300
_tmp2_ = _ ("Liked post from ");
301
_tmp3_ = g_strconcat (_tmp2_, self->priv->_sender, NULL);
303
_tmp5_ = notify_notification_new (_tmp1_, _tmp4_, self->priv->_scalable_icon);
306
notification = _tmp6_;
418
_tmp1_ = g_strdup ("");
420
_tmp2_ = g_strdup ("");
424
_tmp3_ = gwibber_messages_new ();
426
_tmp4_ = gwibber_messages_get_message (messages, self->priv->_mid);
428
_tmp5_ = json_parser_new ();
430
json_parser_load_from_data (parser, msg, (gssize) (-1), &_inner_error_);
431
if (_inner_error_ != NULL) {
432
_g_object_unref0 (parser);
434
_g_object_unref0 (messages);
435
if (_inner_error_->domain == G_IO_ERROR) {
436
goto __catch2_g_io_error;
440
_tmp6_ = json_parser_get_root (parser);
441
_tmp7_ = json_node_get_object (_tmp6_);
442
_tmp8_ = _json_object_ref0 (_tmp7_);
443
_json_object_unref0 (obj);
447
_tmp9_ = json_object_has_member (obj, "sender");
449
JsonObject* _tmp10_ = NULL;
451
_tmp10_ = json_object_get_object_member (obj, "sender");
452
_tmp11_ = _json_object_ref0 (_tmp10_);
453
_json_object_unref0 (sender_obj);
454
sender_obj = _tmp11_;
455
if (sender_obj != NULL) {
458
_tmp12_ = json_object_has_member (sender_obj, "nick");
460
const gchar* _tmp13_ = NULL;
462
_tmp13_ = json_object_get_string_member (sender_obj, "nick");
463
_tmp14_ = g_strdup (_tmp13_);
467
_tmp15_ = json_object_has_member (sender_obj, "name");
469
const gchar* _tmp16_ = NULL;
471
_tmp16_ = json_object_get_string_member (sender_obj, "name");
472
_tmp17_ = g_strdup (_tmp16_);
479
_g_object_unref0 (parser);
481
_g_object_unref0 (messages);
487
_inner_error_ = NULL;
488
g_warning ("action-box.vala:218: %s", e->message);
492
if (_inner_error_ != NULL) {
493
_json_object_unref0 (sender_obj);
494
_json_object_unref0 (obj);
497
g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
498
g_clear_error (&_inner_error_);
501
_tmp18_ = strlen (name);
504
_tmp19_ = g_strdup (name);
508
_tmp20_ = _ ("Liked");
509
_tmp21_ = _ ("Liked post from ");
510
_tmp22_ = g_strconcat (_tmp21_, nick, NULL);
512
_tmp24_ = notify_notification_new (_tmp20_, _tmp23_, self->priv->_scalable_icon);
515
notification = _tmp25_;
307
516
notify_notification_show (notification, &_inner_error_);
308
517
if (_inner_error_ != NULL) {
309
518
_g_object_unref0 (notification);
519
_json_object_unref0 (sender_obj);
520
_json_object_unref0 (obj);
310
523
g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
311
524
g_clear_error (&_inner_error_);
314
527
_g_object_unref0 (notification);
528
_json_object_unref0 (sender_obj);
529
_json_object_unref0 (obj);