MODEST_TYPE_MSG_VIEW_WINDOW, \
ModestMsgViewWindowPrivate))
/* globals */
-static GtkWindowClass *parent_class = NULL;
+static ModestWindowParentClass *parent_class = NULL;
/* uncomment the following if you have defined any signals */
static guint signals[LAST_SIGNAL] = {0};
modest_window_mgr_unregister_header (modest_runtime_get_window_mgr (), header);
row_reference = (GtkTreeRowReference *) user_data;
- if (canceled) {
+ self = (ModestMsgViewWindow *) modest_mail_operation_get_source (mail_op);
+ if (canceled || !self || MODEST_MSG_VIEW_WINDOW_GET_PRIVATE (self)->msg_view == NULL ) {
if (row_reference)
gtk_tree_row_reference_free (row_reference);
- self = (ModestMsgViewWindow *) modest_mail_operation_get_source (mail_op);
if (self) {
/* Restore window title */
update_window_title (self);
if (!modest_ui_actions_msg_retrieval_check (mail_op, header, msg)) {
if (row_reference)
gtk_tree_row_reference_free (row_reference);
- self = (ModestMsgViewWindow *) modest_mail_operation_get_source (mail_op);
if (self) {
priv = MODEST_MSG_VIEW_WINDOW_GET_PRIVATE (self);
/* First we check if the parent is a folder window */
}
/* Get the window */
- self = (ModestMsgViewWindow *) modest_mail_operation_get_source (mail_op);
g_return_if_fail (MODEST_IS_MSG_VIEW_WINDOW (self));
priv = MODEST_MSG_VIEW_WINDOW_GET_PRIVATE (self);
account = modest_account_mgr_get_default_account (modest_runtime_get_account_mgr ());
msg = tny_camel_msg_new ();
- tny_camel_msg_parse (TNY_CAMEL_MSG (msg), file_stream);
+ tny_camel_msg_parse (msg, file_stream);
if (priv->top_msg)
top_msg = g_object_ref (priv->top_msg);