[webkit-gtk] Problem with webkit_web_view_new with gtk port

Monil Parmar monil.parmar at gmail.com
Fri Feb 25 01:39:58 PST 2011


Hi,


Thanks for your suggestions. I used the webkit_web_view_new with gtk_main
and it works.

But when iam trying to hide the web view. It crashes.
sample is attached.
Where *test_gtk_launcher()* is entry function
and on calling *test_gtkapp_quit()* it hide the webview. but crashes (on
using pthread). (works fine when using g_timeout_add()).
Can you plz suggest what is wrong with sample.


Monil

On Tue, Feb 1, 2011 at 2:09 PM, Sergio Villar Senin <svillar at igalia.com>wrote:

> En 01/02/11 05:44, Monil Parmar escribiu:
> > yes as per current design webkit_web_view_new should be with gtk_mail.
> > But what is reason behind this?
> >
> > Just brief about the scenario iam running:
> > As in application gtk_main will be called at the start. And later on
> > application will parse the html tags and create the webveiw in another
> > thread.
> > So looking for any way to create webview in gtk_main loop.
> >
> > I tried to use the gdk threads and g_signal_connect to put the create
> > the webview in gtk_main thread, but no success.
> > Idea was by call back function of g_signal_connect ill be able to create
> > the webview in gtk_main loop.
> > Initially i put gtk_main in different thread. Then by g_singal_connect i
> > tried to create webview in call back function.
>
> If you want to create the webview from another thread then you have to
> use gdk_threads_add_timeout or gdk_threads_add_idle. The callbacks of
> those functions will be called inside the main look and the gtk lock so
> there you could safely create and show a webview.
>
> Br
> _______________________________________________
> webkit-gtk mailing list
> webkit-gtk at lists.webkit.org
> http://lists.webkit.org/mailman/listinfo.cgi/webkit-gtk
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-gtk/attachments/20110225/ac0d3628/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: html.cpp
Type: text/x-c++src
Size: 2632 bytes
Desc: not available
URL: <http://lists.webkit.org/pipermail/webkit-gtk/attachments/20110225/ac0d3628/attachment.bin>


More information about the webkit-gtk mailing list