[Webkit-unassigned] [Bug 63009] New: Web Inspector: [WebKit2] Do not access InspectorController from the "Develop" menu code.
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Mon Jun 20 13:34:31 PDT 2011
https://bugs.webkit.org/show_bug.cgi?id=63009
Summary: Web Inspector: [WebKit2] Do not access
InspectorController from the "Develop" menu code.
Product: WebKit
Version: 528+ (Nightly build)
Platform: All
OS/Version: All
Status: UNCONFIRMED
Severity: Normal
Priority: P2
Component: Web Inspector
AssignedTo: webkit-unassigned at lists.webkit.org
ReportedBy: pfeldman at chromium.org
CC: timothy at apple.com, joepeck at webkit.org,
yurys at chromium.org
TL/DR:
Upon "Develop" menu action (say "Start JavaScript Debugging"), do not call inspectorController, but rather evaluate "InspectorFrontendAPI.startDebugging" in the front-end page.
I prepared a fix for WebKit in https://bugs.webkit.org/show_bug.cgi?id=62985, but I need your help with WebKit2 implementation.
Background:
I'm currently working on eliminating unnecessary methods from InspectorController.h:
bool profilerEnabled();
void enableProfiler();
void startUserInitiatedProfiling();
bool isRecordingUserInitiatedProfile() const;
void stopUserInitiatedProfiling();
void disableProfiler();
void showAndEnableDebugger();
bool debuggerEnabled();
void disableDebugger();
void startTimelineProfiler();
void stopTimelineProfiler();
bool timelineProfilerEnabled();
void showConsole();
WebCore does not use them, pretty much all of these are used from WebKit's support for "Develop" menu.
Today, enabling debugging goes all the way:
[EXISTING CONTROL FLOW] Action handler -> (via WebCore API above) -> InspectorController -> InspectorDebuggerAgent -> (via Inspector protocol) -> Front-end
As a result, it looks like inspector backend has two client: 1) actual front-end and 2) develop menu implementation. Hence, we have methods such as "debuggerWasEnabled" in the protocol and "showAndEnableDebugger" in InspectorController that make sure things are in sync.
It would be more straightforward if we could make "Develop" menu actions implementation talk to the backend via the front-end. I.e.
[PROPOSED CONTROL FLOW] Action handler -> Open Front-end, then -> (via Frontend API) -> Front-end -> (make all calls against backend as the front-end would have)
As a result
- everything goes over single channel
- backend and front-end are talking to each other only, there is no need to sync "Develop" menu state with the front-end via the backend
- all methods above + some weird methods from the protocol vanish
--
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