[Webkit-unassigned] [Bug 86254] Web Inspector: Timeline panel "Load Timeline data" broken

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon May 14 08:02:44 PDT 2012


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





--- Comment #1 from Vivek Galatage <vivekgalatage at gmail.com>  2012-05-14 08:01:48 PST ---
This is my preliminary analysis:

The TimelinePanel::_contextMenu() (TimelinePanel.js), adds the menu items in the context menu for "Load Timeline data" specifying this._fileSelectorElement.click as the context menu click handler.

This context menu is displayed by InspectorFrontendHost::showContextMenu() and even the event associated with the menu item is handled in FrontendMenuProvider::contextMenuItemSelected() method (both these are there in Source\WebCore\inspector\InspectorFrontendHost.cpp). 

So now in this method there is an explicit call to WebInspector.contextMenuItemSelected (ContextMenu.js) using the ScriptFunctionCall object upon clicking this menu item.

As per the invocation, the JS call to WebInspector.contextMenuItemSelected is invoked and it tries to invoke the this._fileSelectorElement.click

This call is running in what I call as Script Running Context than the User Running Context. So I guess in this mode, the call to click() on File Input will not have any effect. And hence the File dialog is not displayed.

To demonstrate this I have created a html snippet here: http://pastebin.com/3JV2jgtM 
So in this code snippet, the call to fileSelectorElement.click(); works only from the button's onClick handler i.e. f()

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