Bug 41230 - windows.forms/mono-webbrowser hangs on shutting down.
Summary: windows.forms/mono-webbrowser hangs on shutting down.
Status: NEW
Alias: None
Product: Class Libraries
Classification: Mono
Component: Windows.Forms ()
Version: 4.2.0 (C6)
Hardware: PC Linux
: --- normal
Target Milestone: Community
Assignee: Bugzilla
Depends on:
Reported: 2016-05-21 01:51 UTC by Hin-Tak Leung
Modified: 2017-09-01 11:55 UTC (History)
1 user (show)

Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report for Bug 41230 on GitHub or Developer Community if you have new information to add and do not yet see a matching new report.

If the latest results still closely match this report, you can use the original description:

  • Export the original title and description: GitHub Markdown or Developer Community HTML
  • Copy the title and description into the new report. Adjust them to be up-to-date if needed.
  • Add your new information.

In special cases on GitHub you might also want the comments: GitHub Markdown with public comments

Related Links:

Description Hin-Tak Leung 2016-05-21 01:51:44 UTC
Most of the background information is the same as:

Besides the graphics appearance issue in bug 41228, the simple demo code (
https://bugzilla.xamarin.com/show_bug.cgi?id=4155 ) opens and closes correctly under wine + dotnet2 + ie8, but hangs on clicking on closing the win form from the corner button.

I tried adding an explicit this.webBrowser1.Dispose(); from the form closed event, but it results in 

(attachment:23620): Gdk-WARNING **: GdkWindow 0x2c0001e unexpectedly destroyed

and the demo app still hangs on shutting down, and needs to be force-closed by OS means.
Comment 1 Hin-Tak Leung 2016-05-21 01:53:20 UTC
Again, this could be either SWF or mono-webbrowser's problem, but there is no filing at https://github.com/mono/mono-webbrowser , and besides, it might need to resurrecting libgluezilla to narrow it down...
Comment 2 Hin-Tak Leung 2016-05-21 09:32:18 UTC
Another related issue with the shutting down issue, is that scrolling by the enclosing scrolledwindow does not work. Also, the content is not too responsive to resizing of the scrolledwindow - it is responsive to some extent, but not fully. As for scrolling, it simply does not scroll.

I put this here since this seems to be a generic events-from-container-passing-to-webview issue, unlike the other one I filed which is about rendering.
Comment 3 Hin-Tak Leung 2016-05-27 05:23:54 UTC
Somewhat similar issue reported in 2010:

So perhaps the code has never worked correcly in this respect. :-(.
Comment 4 Hin-Tak Leung 2016-05-27 22:32:31 UTC
Have a fix to the shutdown problem:

Let's see if I can make any headway with the scrolling also...
Comment 5 Hin-Tak Leung 2016-06-06 09:10:25 UTC
Fixed the re-size/scrolling problems also - in the end they are all event-loop ones. The shutdown issue is genuine, as described above, and separate.

Please pull: