Changeset 200959 in webkit
- Timestamp:
- May 16, 2016 12:53:00 PM (8 years ago)
- Location:
- trunk/Source/WebKit2
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit2/ChangeLog
r200957 r200959 1 2016-05-16 Brian Burg <bburg@apple.com> 2 3 Web Automation: Automation.inspectBrowsingContext should automatically start page profiling 4 https://bugs.webkit.org/show_bug.cgi?id=157739 5 6 Reviewed by Timothy Hatcher. 7 8 * UIProcess/API/C/WKInspector.cpp: 9 (WKInspectorTogglePageProfiling): 10 Implicitly show the Web Inspector in the C API command to preserve existing behavior. 11 12 * UIProcess/Automation/WebAutomationSession.cpp: 13 (WebKit::WebAutomationSession::inspectorFrontendLoaded): 14 If the frontend loaded, it was either because the user opened Web Inspector (and 15 turning on page profiling is harmless), or it was loaded but not shown by the 16 inspectBrowsingContext command. For the latter, we want to start page profiling 17 before processing any additional commands so subsequent execution is captured. 18 19 * UIProcess/WebInspectorProxy.cpp: 20 (WebKit::WebInspectorProxy::togglePageProfiling): 21 Send the start/stop profiling messages directly to the WebInspectorUI process instead of 22 bouncing through the inspected page's process, which does an implicit show() we don't want. 23 24 * UIProcess/WebPageProxy.cpp: 25 (WebKit::WebPageProxy::inspector): Make it const. 26 * UIProcess/WebPageProxy.h: 27 1 28 2016-05-16 Conrad Shultz <conrad_shultz@apple.com> 2 29 -
trunk/Source/WebKit2/UIProcess/API/C/WKInspector.cpp
r199380 r200959 118 118 void WKInspectorTogglePageProfiling(WKInspectorRef inspectorRef) 119 119 { 120 toImpl(inspectorRef)->show(); 120 121 toImpl(inspectorRef)->togglePageProfiling(); 121 122 } -
trunk/Source/WebKit2/UIProcess/Automation/WebAutomationSession.cpp
r200702 r200959 460 460 if (auto callback = m_pendingInspectorCallbacksPerPage.take(page.pageID())) 461 461 callback->sendSuccess(InspectorObject::create()); 462 463 // Start collecting profile information immediately so the entire session is captured. 464 page.inspector()->togglePageProfiling(); 462 465 } 463 466 -
trunk/Source/WebKit2/UIProcess/WebInspectorProxy.cpp
r200702 r200959 297 297 298 298 if (m_isProfilingPage) 299 m_inspect edPage->process().send(Messages::WebInspector::StopPageProfiling(), m_inspectedPage->pageID());299 m_inspectorPage->process().send(Messages::WebInspectorUI::StopPageProfiling(), m_inspectorPage->pageID()); 300 300 else 301 m_inspect edPage->process().send(Messages::WebInspector::StartPageProfiling(), m_inspectedPage->pageID());301 m_inspectorPage->process().send(Messages::WebInspectorUI::StartPageProfiling(), m_inspectorPage->pageID()); 302 302 303 303 // FIXME: have the WebProcess notify us on state changes. -
trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp
r200611 r200959 4035 4035 4036 4036 // Inspector 4037 WebInspectorProxy* WebPageProxy::inspector() 4037 WebInspectorProxy* WebPageProxy::inspector() const 4038 4038 { 4039 4039 if (isClosed() || !isValid()) -
trunk/Source/WebKit2/UIProcess/WebPageProxy.h
r200660 r200959 311 311 void didExitFullscreen(); 312 312 313 WebInspectorProxy* inspector() ;313 WebInspectorProxy* inspector() const; 314 314 315 315 bool isControlledByAutomation() const { return m_controlledByAutomation; }
Note: See TracChangeset
for help on using the changeset viewer.