Il 10/02/2016 21:13, Giuliano Colla ha scritto:
I don't believe that there's an easy way to protect Application.ProcessMessages from recursion unless someone is willing to debug and patch Glib (which is used not only by Qt, but also from GTK, if I'm not wrong).

A snippet from gmain.c:
#if 0
  /* If recursing, finish up current dispatch, before starting over */
  if (context->pending_dispatches)
    {
      if (dispatch)
    g_main_dispatch (context, &current_time);

      UNLOCK_CONTEXT (context);
      return TRUE;
    }
#endif


It would appear that they realized the dispatch recursion problems but where unable to find a clean solution! This code appears both in glib-2.28.8 (the one coming with CentOs 6, which I've been using) and in the current version i.e. glib-2.47.5. My feeling is that it's been left there as a reminder that the matter is still pending.
I'm afraid we must live with it.

Giuliano



--
_______________________________________________
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to