Bug 151132 - [GTK] Runtime critical warnings when closing a page containing windowed plugins
Summary: [GTK] Runtime critical warnings when closing a page containing windowed plugins
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKitGTK (show other bugs)
Version: WebKit Local Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: Gtk
Depends on:
Blocks:
 
Reported: 2015-11-11 03:12 PST by Carlos Garcia Campos
Modified: 2015-11-11 08:36 PST (History)
4 users (show)

See Also:


Attachments
Patch (2.35 KB, patch)
2015-11-11 03:16 PST, Carlos Garcia Campos
mrobinson: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Carlos Garcia Campos 2015-11-11 03:12:38 PST
(WebKitPluginProcess:31915): Gtk-CRITICAL **: gtk_widget_destroy: assertion 'GTK_IS_WIDGET (widget)' failed

This is because our plugin widget that is a GtkPlug (derived from GtkWindow) can receive the delete-event signal before NetscapePlugin::platformDestroy is called. The delete-event signal, by default, destroys the window when the signal is not handled. So after the delete-event the GtkPlug is destroyed, but our pointer hasn't been reset. We can handle the delete-event using gtk_widget_hide_on_delete as callback, so that the plugin widget is hidden instead of destroyed.
Comment 1 Carlos Garcia Campos 2015-11-11 03:16:20 PST
Created attachment 265280 [details]
Patch
Comment 2 Carlos Garcia Campos 2015-11-11 08:36:34 PST
Committed r192311: <http://trac.webkit.org/changeset/192311>