[Webkit-unassigned] [Bug 88473] Web Inspector: Implement ExtensionPanel.show() method

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Jun 7 07:22:53 PDT 2012


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





--- Comment #2 from Andrey Kosyakov <caseq at chromium.org>  2012-06-07 07:22:52 PST ---
(From update of attachment 146167)
View in context: https://bugs.webkit.org/attachment.cgi?id=146167&action=review

We're somewhat wary of the extensions switching focus unexpectedly for the user. So it would be good idea to add a check that only allows panel.show() to be called in response to a user action (I can only think of one so far -- open resource handler). So the idea is to set a flag upon invoking the handler, clearing it upon exit from the handle and checking it in show(). Unfortunately, with server-to-client callback being async, this would have to be done on the client side -- but it's still better than nothing :)

> Source/WebCore/inspector/front-end/ExtensionAPI.js:399
> +    },
> +    show: function()

please add empty line before show.

> Source/WebCore/inspector/front-end/ExtensionServer.js:210
> +        WebInspector.showPanel(message.id);

Please add a check for id to be the extension panel (i.e. id in this._clientObjects). It wouldn't be possible to pass incorrect panel id through an API call, but we're trying to also protect from direct messages sent to the extension server. Also very unlikely, but just in case :)

> LayoutTests/inspector/extensions/extensions-panel.html:74
> +        panel.onSearch.addListener(function(action, query) {
> +            output("Panel searched");
> +        });

This does not seem to have any effect on the test output, so please remove it for now.

-- 
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