[Webkit-unassigned] [Bug 53600] [GTK] Add support for window.runModalDialog

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Feb 22 10:40:23 PST 2012


https://bugs.webkit.org/show_bug.cgi?id=53600





--- Comment #32 from Carlos Garcia Campos <cgarcia at igalia.com>  2012-02-22 10:40:23 PST ---
(In reply to comment #22)
> (From update of attachment 126324 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=126324&action=review
> 
> >>> Tools/DumpRenderTree/gtk/DumpRenderTree.cpp:962
> >>> +    GtkWindow* viewTopLevel = GTK_WINDOW(gtk_widget_get_toplevel(GTK_WIDGET(view)));
> >> 
> >> You should check that returned widget is actually a toplevel and a GdkWindow. We have a method in GtkUtilities to check this properly.
> > 
> > I'll put a similar check in both DRT and GtkLauncher.
> 
> Unfortunately this check is not possible here, because the dialog web view is not a child of a GtkWindow since a newly-created web view is not packed into anything. Because the dialog web view doesn't have any parents, gtk_widget_get_toplevel returns a pointer to the dialog web view itself. The check would then fail because the pointer does not represent neither a toplevel nor a GtkWindow, causing test failures.

But you are using the toplevel as a GtkWindow without checking neither it's a toplevel nor a GtkWindow.

gtk_window_set_transient_for(GTK_WINDOW(viewTopLevel), GTK_WINDOW(window));
gtk_window_set_modal(GTK_WINDOW(viewTopLevel), TRUE);

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list