RESOLVED FIXED 175259
[GTK] Implement JavaScript dialog methods of API::AutomationSessionClient
https://bugs.webkit.org/show_bug.cgi?id=175259
Summary [GTK] Implement JavaScript dialog methods of API::AutomationSessionClient
Carlos Garcia Campos
Reported 2017-08-07 03:15:38 PDT
Needed for the web driver prompt commands. See bug #174614
Attachments
Patch (28.45 KB, patch)
2017-08-07 03:29 PDT, Carlos Garcia Campos
mcatanzaro: review+
Carlos Garcia Campos
Comment 1 2017-08-07 03:29:16 PDT
Blaze Burg
Comment 2 2017-08-07 10:06:56 PDT
Comment on attachment 317408 [details] Patch WebDriver related parts look good to me. I'd like Michael or another GTK reviewer to look too.
Michael Catanzaro
Comment 3 2017-08-07 12:05:16 PDT
Comment on attachment 317408 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=317408&action=review > Source/WebCore/platform/gtk/po/POTFILES.in:33 > +../../../WebKit/UIProcess/API/gtk/WebKitScriptDialogGtk.cpp Do we have a script that reminds you to do this, or are you the hero of the translators? > Source/WebKit/ChangeLog:11 > + files. Implement all JavaScript dialog methods of API::AutomationSessionClient in WebKitAutomationSession. For > + now it only works when the user doesn't override WebKitWebView::script-dialog signal and default implementation > + is used. Well that's a significant limitation. > Source/WebKit/UIProcess/API/glib/WebKitWebView.cpp:2051 > + // FIXME: Add API to ask the user in case default implementation is not being used. What should that API look like?
Carlos Garcia Campos
Comment 4 2017-08-07 22:42:25 PDT
(In reply to Michael Catanzaro from comment #3) > Comment on attachment 317408 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=317408&action=review > > > Source/WebCore/platform/gtk/po/POTFILES.in:33 > > +../../../WebKit/UIProcess/API/gtk/WebKitScriptDialogGtk.cpp > > Do we have a script that reminds you to do this, or are you the hero of the > translators? Not that I know of, I guess I'm the hero of the translators, then :-D > > Source/WebKit/ChangeLog:11 > > + files. Implement all JavaScript dialog methods of API::AutomationSessionClient in WebKitAutomationSession. For > > + now it only works when the user doesn't override WebKitWebView::script-dialog signal and default implementation > > + is used. > > Well that's a significant limitation. It would be significant if applications actually overrode the default implementation, but I bet nobody is doing that (I don't really know, though). > > Source/WebKit/UIProcess/API/glib/WebKitWebView.cpp:2051 > > + // FIXME: Add API to ask the user in case default implementation is not being used. > > What should that API look like? I don't know, but more or less the same we are currently using internally, but using signals to ask the user about the js dialogs. Or we could add a WebKitScriptDialogManager or something like that, to not add more signals to the WebKitWebView. I don't know i haven't thought about it yet.
Carlos Garcia Campos
Comment 5 2017-08-07 23:25:34 PDT
Note You need to log in before you can comment on or make changes to this bug.