2007-06-27 Murray Cumming <murrayc@murrayc.com
authorMurray Cumming <murrayc@murrayc.com>
Wed, 27 Jun 2007 12:16:09 +0000 (12:16 +0000)
committerMurray Cumming <murrayc@murrayc.com>
Wed, 27 Jun 2007 12:16:09 +0000 (12:16 +0000)
* src/maemo/modest-maemo-global-settings-dialog.c:
(idle_select_default_focus):
* src/modest-mail-operation.c: (idle_notify_progress),
(idle_notify_progress_once), (set_last_updated_idle),
(update_account_thread), (get_msgs_full_thread):
* src/widgets/modest-attachment-view.c: (get_size_idle_func):
* src/widgets/modest-header-view.c:
(idle_notify_headers_count_changed_destroy),
(idle_notify_headers_count_changed):
Reverted the additions of gdk_threads_enter/leave(), in case this
helps with a startup hang on the device.

pmo-trunk-r2456

ChangeLog2
src/maemo/modest-maemo-global-settings-dialog.c
src/modest-mail-operation.c
src/widgets/modest-attachment-view.c
src/widgets/modest-header-view.c

index 4905ef2..0c1f661 100644 (file)
@@ -1,3 +1,17 @@
+2007-06-27  Murray Cumming  <murrayc@murrayc.com
+
+       * src/maemo/modest-maemo-global-settings-dialog.c:
+       (idle_select_default_focus):
+       * src/modest-mail-operation.c: (idle_notify_progress),
+       (idle_notify_progress_once), (set_last_updated_idle),
+       (update_account_thread), (get_msgs_full_thread):
+       * src/widgets/modest-attachment-view.c: (get_size_idle_func):
+       * src/widgets/modest-header-view.c:
+       (idle_notify_headers_count_changed_destroy),
+       (idle_notify_headers_count_changed):
+       Reverted the additions of gdk_threads_enter/leave(), in case this 
+       helps with a startup hang on the device.
+
 2007-06-26  Armin Burgmeier  <armin@openismus.com>
 
        * src/maemo/modest-maemo-utils.c: Replaced a busy wait while waiting
index 5b967bb..a6d1601 100644 (file)
@@ -151,8 +151,6 @@ typedef struct {
 static gboolean
 idle_select_default_focus (gpointer data) 
 {
-       gdk_threads_enter ();
-
        ModestGlobalSettingsDialogPrivate *ppriv;
        ModestMaemoGlobalSettingsDialogPrivate *priv;
        SwitchPageHelper *helper;
@@ -169,8 +167,6 @@ idle_select_default_focus (gpointer data)
 
        g_free (helper);
 
-       gdk_threads_leave ();
-
        return FALSE;
 }
 
index f88ff79..0862a68 100644 (file)
@@ -795,8 +795,6 @@ recurse_folders (TnyFolderStore *store, TnyFolderStoreQuery *query, TnyList *all
 static gboolean
 idle_notify_progress (gpointer data)
 {
-       gdk_threads_enter ();
-
        ModestMailOperation *mail_op = MODEST_MAIL_OPERATION (data);
        ModestMailOperationState *state;
 
@@ -804,8 +802,6 @@ idle_notify_progress (gpointer data)
        g_signal_emit (G_OBJECT (mail_op), signals[PROGRESS_CHANGED_SIGNAL], 0, state, NULL);
        g_slice_free (ModestMailOperationState, state);
        
-       gdk_threads_leave ();
-
        return TRUE;
 }
 
@@ -817,8 +813,6 @@ idle_notify_progress (gpointer data)
 static gboolean
 idle_notify_progress_once (gpointer data)
 {
-       gdk_threads_enter ();
-
        ModestPair *pair;
 
        pair = (ModestPair *) data;
@@ -829,8 +823,6 @@ idle_notify_progress_once (gpointer data)
        g_slice_free (ModestMailOperationState, (ModestMailOperationState*)pair->second);
        g_object_unref (pair->first);
 
-       gdk_threads_leave ();
-
        return FALSE;
 }
 
@@ -888,8 +880,6 @@ set_last_updated_idle (gpointer data)
                                    time(NULL), 
                                    TRUE);
 
-       gdk_threads_leave ();
-
        return FALSE;
 }
 
@@ -1103,7 +1093,7 @@ update_account_thread (gpointer thr_user_data)
        /* Notify about operation end. Note that the info could be
           freed before this idle happens, but the mail operation will
           be still alive */
-       g_idle_add (idle_notify_update_account_queue, g_object_ref (info->mail_op));
+       g_idle_add (notify_update_account_queue, g_object_ref (info->mail_op));
 
        if (info->callback) {
                /* This thread is not in the main lock */
@@ -1760,7 +1750,7 @@ get_msgs_full_thread (gpointer thr_user_data)
                priv->status = MODEST_MAIL_OPERATION_STATUS_SUCCESS;
 
        /* Notify about operation end */
-       g_idle_add (idle_notify_update_account_queue, g_object_ref (info->mail_op));
+       g_idle_add (notify_update_account_queue, g_object_ref (info->mail_op));
 
        /* Free thread resources. Will be called after all previous idles */
        g_idle_add_full (G_PRIORITY_DEFAULT_IDLE + 1, get_msgs_full_destroyer, info, NULL);
index b76fa17..b89bc5e 100644 (file)
@@ -160,9 +160,8 @@ get_size_idle_func (gpointer data)
                priv->get_size_idle_id = 0;
        }
 
-       gdk_threads_leave ();
-
        return (priv->get_size_stream != NULL);
+       
 }
 
 static void
index acf8f72..ed2d8ec 100644 (file)
@@ -1397,8 +1397,6 @@ on_focus_in (GtkWidget     *self,
 static void
 idle_notify_headers_count_changed_destroy (gpointer data)
 {
-       gdk_threads_enter ();
-
        HeadersCountChangedHelper *helper = NULL;
 
        g_return_if_fail (data != NULL);
@@ -1406,15 +1404,11 @@ idle_notify_headers_count_changed_destroy (gpointer data)
 
        g_object_unref (helper->change);
        g_slice_free (HeadersCountChangedHelper, helper);
-
-       gdk_threads_leave ();
 }
 
 static gboolean
 idle_notify_headers_count_changed (gpointer data)
 {
-       gdk_threads_enter ();
-
        TnyFolder *folder = NULL;
        ModestHeaderViewPrivate *priv = NULL;
        HeadersCountChangedHelper *helper = NULL;
@@ -1438,8 +1432,6 @@ idle_notify_headers_count_changed (gpointer data)
            
        g_mutex_unlock (priv->observers_lock);
 
-       gdk_threads_leave ();
-
        return FALSE;
 }