[maemo-commits] [maemo-commits] r15355 - in projects/haf/trunk/gail: . debian gail
From: subversion at stage.maemo.org subversion at stage.maemo.orgDate: Tue Apr 8 12:11:02 EEST 2008
- Previous message: [maemo-commits] r15354 - in projects/haf/trunk/hildon-1: . src
- Next message: [maemo-commits] r15356 - projects/haf/tags/gail
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Author: atdomoko Date: 2008-04-08 12:11:00 +0300 (Tue, 08 Apr 2008) New Revision: 15355 Modified: projects/haf/trunk/gail/ChangeLog projects/haf/trunk/gail/debian/changelog projects/haf/trunk/gail/gail/gailtextview.c Log: fixing bug 82253 Modified: projects/haf/trunk/gail/ChangeLog =================================================================== --- projects/haf/trunk/gail/ChangeLog 2008-04-07 11:33:29 UTC (rev 15354) +++ projects/haf/trunk/gail/ChangeLog 2008-04-08 09:11:00 UTC (rev 15355) @@ -1,3 +1,15 @@ +2008-04-01 Attila Domokos <attila.domokos at nokia.com> + + * gail/gailtextview.c + (insert_handler): refactoring insert_idle_handler in order to use + this functionality in two different ways, with the GDK_THREADS_ENTER + and without the GDK_THREADS_LEAVE + (_gail_text_view_insert_text_cb): + (_gail_text_view_delete_range_cb): + (emit_text_caret_moved): + use insert_handler instead insert_idle_handler to avoid a lock + * Fixes: NB#82253 + 2008-01-15 Attila Domokos <attila.domokos at nokia.com> * gail/gailwidget.c: Modified: projects/haf/trunk/gail/debian/changelog =================================================================== --- projects/haf/trunk/gail/debian/changelog 2008-04-07 11:33:29 UTC (rev 15354) +++ projects/haf/trunk/gail/debian/changelog 2008-04-08 09:11:00 UTC (rev 15355) @@ -1,3 +1,17 @@ +gail (1.18.0-osso13) unstable; urgency=low + + * gail/gailtextview.c + (insert_handler): refactoring insert_idle_handler in order to use + this functionality in two different ways, with the GDK_THREADS_ENTER + and without the GDK_THREADS_LEAVE + (_gail_text_view_insert_text_cb): + (_gail_text_view_delete_range_cb): + (emit_text_caret_moved): + use insert_handler instead insert_idle_handler to avoid a lock + * Fixes: NB#82253 + + -- Attila Domokos <attila.domokos at nokia.com> Tue, 8 Apr 2008 12:06:48 +0200 + gail (1.18.0-osso12) unstable; urgency=low * gail/gailwidget.c: Modified: projects/haf/trunk/gail/gail/gailtextview.c =================================================================== --- projects/haf/trunk/gail/gail/gailtextview.c 2008-04-07 11:33:29 UTC (rev 15354) +++ projects/haf/trunk/gail/gail/gailtextview.c 2008-04-08 09:11:00 UTC (rev 15355) @@ -166,6 +166,7 @@ static gint get_selection_bound (GtkTextBuffer *buffer); static void emit_text_caret_moved (GailTextView *gail_text_view, gint insert_offset); +static gint insert_handler (gpointer data); static gint insert_idle_handler (gpointer data); static GailWidgetClass *parent_class = NULL; @@ -1465,7 +1466,7 @@ g_source_remove (gail_text_view->insert_notify_handler); } gail_text_view->insert_notify_handler = 0; - insert_idle_handler (gail_text_view); + insert_handler (gail_text_view); gail_text_view->position = position; gail_text_view->length = length; } @@ -1510,7 +1511,7 @@ return; } - insert_idle_handler (gail_text_view); + insert_handler (gail_text_view); } g_signal_emit_by_name (accessible, "text_changed::delete", offset, length); @@ -1658,7 +1659,7 @@ { g_source_remove (gail_text_view->insert_notify_handler); gail_text_view->insert_notify_handler = 0; - insert_idle_handler (gail_text_view); + insert_handler (gail_text_view); } if (insert_offset != gail_text_view->previous_insert_offset) @@ -1674,14 +1675,25 @@ } } -static gint +static gint insert_idle_handler (gpointer data) { + /* On the idle we're out the main lock */ + GDK_THREADS_ENTER(); + + insert_handler(data); + + GDK_THREADS_LEAVE(); + + return FALSE; +} + +static gint +insert_handler (gpointer data) +{ GailTextView *gail_text_view; GtkTextBuffer *buffer; - GDK_THREADS_ENTER (); - gail_text_view = GAIL_TEXT_VIEW (data); g_signal_emit_by_name (data, @@ -1703,8 +1715,6 @@ gail_text_view->previous_selection_bound = get_selection_bound (buffer); } - GDK_THREADS_LEAVE (); - return FALSE; }
- Previous message: [maemo-commits] r15354 - in projects/haf/trunk/hildon-1: . src
- Next message: [maemo-commits] r15356 - projects/haf/tags/gail
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]