xbmc/xbmc — pull request #1097 by pieh (2012-06-21 16:20:10+00:00)
Title: Fix deadlock when using xbmcgui.DialogProgress in plugin

This fixes http://trac.xbmc.org/ticket/13113

Currently xbmc deadlocks when using xbmcgui.DialogProgress in plugin before we setup DialogProgress in https://github.com/xbmc/xbmc/blob/master/xbmc/filesystem/PluginDirectory.cpp#L481 :
- CPluginDirectory::WaitOnScriptResult is blocking GUI thread while waiting for plugin results and it will only run render loop (progressBar->Progress(); on L518) if we wait 1500 ms and don't have active DialogProgress
- script can't finish because closing ProcessDialog (from python: either directly via xbmcgui.DialogProgress.close() or on python's obj dealloc) needs running render loop

This commit simply adds processing render loop while waiting for plugin results even if we don't show DialogProgress from CPluginDirectory::WaitOnScriptResult.