Summary: | Put Web Inspector's JS debugger hooks under ENABLE(JAVASCRIPT_DEBUGGER) | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Peter Kasting <pkasting> | ||||
Component: | Web Inspector (Deprecated) | Assignee: | Peter Kasting <pkasting> | ||||
Status: | RESOLVED FIXED | ||||||
Severity: | Normal | ||||||
Priority: | P2 | ||||||
Version: | 528+ (Nightly build) | ||||||
Hardware: | PC | ||||||
OS: | All | ||||||
Attachments: |
|
Description
Peter Kasting
2008-10-23 11:31:13 PDT
Created attachment 24605 [details]
patch v1
Notable points to review:
* Make sure I didn't erroneously cover any non-debugger functions.
* If there are more helper functions, #includes, etc. that can also go under this #if, I may have missed them; feel free to point that out.
Comment on attachment 24605 [details] patch v1 > @@ -1114,12 +1125,16 @@ void InspectorController::setWindowVisib > populateScriptObjects(); > if (m_nodeToFocus) > focusNode(); > +#if ENABLE(JAVASCRIPT_DEBUGGER) > if (m_attachDebuggerWhenShown) > startDebugging(); > +#endif > if (m_showAfterVisible != CurrentPanel) > showPanel(m_showAfterVisible); > } else { > +#if ENABLE(JAVASCRIPT_DEBUGGER) > stopDebugging(); > +#endif I wonder if it would be better to make startDebugging() and stopDebugging() (and probably some of the other InspectorController functions) be no-ops when the debugger is disabled. That would allow us to add fewer #ifdefs, I think. But I guess that's inconsistent with how we normally use the ENABLE() macro. r=me |