EXT-7889 PARTIAL Linux fails to load splash screen and side panel home tab.

Start to restore manual glib handling.

Backed out changeset ff86a9f5b917
meow-7.2.2
Tofu Linden 2010-06-22 11:07:35 +01:00
parent b0791c3001
commit 7295e1ee03
3 changed files with 31 additions and 6 deletions

View File

@ -1617,7 +1617,7 @@ void LLWindowSDL::processMiscNativeEvents()
pump_timer.setTimerExpirySec(1.0f / 15.0f);
do {
// Always do at least one non-blocking pump
gtk_main_iteration_do(0);
gtk_main_iteration_do(FALSE);
} while (gtk_events_pending() &&
!pump_timer.hasExpired());

View File

@ -9,6 +9,7 @@ include(LLPlugin)
include(LLMath)
include(LLRender)
include(LLWindow)
include(UI)
include(Linking)
include(PluginAPI)
include(MediaPluginBase)
@ -38,7 +39,7 @@ add_library(media_plugin_webkit
${media_plugin_webkit_SOURCE_FILES}
)
target_link_libraries(media_plugin_webkit
set(media_plugin_webkit_LINK_LIBRARIES
${LLPLUGIN_LIBRARIES}
${MEDIA_PLUGIN_BASE_LIBRARIES}
${LLCOMMON_LIBRARIES}
@ -46,6 +47,14 @@ target_link_libraries(media_plugin_webkit
${PLUGIN_API_WINDOWS_LIBRARIES}
)
if (LINUX)
list(APPEND media_plugin_webkit_LINK_LIBRARIES
${UI_LIBRARIES} # for glib/GTK
)
endif (LINUX)
target_link_libraries(media_plugin_webkit ${media_plugin_webkit_LINK_LIBRARIES})
add_dependencies(media_plugin_webkit
${LLPLUGIN_LIBRARIES}
${MEDIA_PLUGIN_BASE_LIBRARIES}

View File

@ -43,15 +43,21 @@
#include "llpluginmessageclasses.h"
#include "media_plugin_base.h"
#if LL_LINUX
extern "C" {
# include <glib.h>
}
#endif // LL_LINUX
#if LL_WINDOWS
#include <direct.h>
# include <direct.h>
#else
#include <unistd.h>
#include <stdlib.h>
# include <unistd.h>
# include <stdlib.h>
#endif
#if LL_WINDOWS
// *NOTE:Mani - This captures the module handle fo rthe dll. This is used below
// *NOTE:Mani - This captures the module handle for the dll. This is used below
// to get the path to this dll for webkit initialization.
// I don't know how/if this can be done with apr...
namespace { HMODULE gModuleHandle;};
@ -112,6 +118,16 @@ private:
//
void update(int milliseconds)
{
#if LL_LINUX
// pump glib generously, as Linux browser plugins are on the
// glib main loop, even if the browser itself isn't - ugh
//*TODO: shouldn't this be transparent if Qt was compiled with
// glib mainloop integration? investigate.
GMainContext *mainc = g_main_context_default();
while(g_main_context_iteration(mainc, FALSE));
#endif // LL_LINUX
// pump qt
LLQtWebKit::getInstance()->pump( milliseconds );
checkEditState();