static void mex_content_tile_dispose (GObject *object) { MexContentTilePrivate *priv = MEX_CONTENT_TILE (object)->priv; if (priv->content) { /* remove the reference to the MexContent and also disconnect the signal * handlers */ mex_content_tile_set_content (MEX_CONTENT_VIEW (object), NULL); } if (priv->model) { g_object_unref (priv->model); priv->model = NULL; } if (priv->download_id) { MexDownloadQueue *dl_queue = mex_download_queue_get_default (); mex_download_queue_cancel (dl_queue, priv->download_id); priv->download_id = NULL; } G_OBJECT_CLASS (mex_content_tile_parent_class)->dispose (object); }
static void mex_content_tile_dispose (GObject *object) { MexContentTilePrivate *priv = MEX_CONTENT_TILE (object)->priv; if (priv->content) { /* remove the reference to the MexContent and also disconnect the signal * handlers */ mex_content_tile_set_content (MEX_CONTENT_VIEW (object), NULL); } if (priv->model) { g_object_unref (priv->model); priv->model = NULL; } if (priv->download_id) { MexDownloadQueue *dl_queue = mex_download_queue_get_default (); mex_download_queue_cancel (dl_queue, priv->download_id); priv->download_id = NULL; } if (priv->start_video_preview > 0) g_source_remove (priv->start_video_preview); if (priv->stop_video_preview > 0) g_source_remove (priv->stop_video_preview); /* This may or may not be parented so explicitly mark for destroying */ if (priv->video_preview) { clutter_actor_destroy (CLUTTER_ACTOR (priv->video_preview)); priv->video_preview = NULL; } G_OBJECT_CLASS (mex_content_tile_parent_class)->dispose (object); }