Bug 29769

Summary: Web Inspector: Do not track DOM changes while inspector window is closed.
Product: WebKit Reporter: Pavel Feldman <pfeldman>
Component: Web Inspector (Deprecated)Assignee: Pavel Feldman <pfeldman>
Severity: Normal CC: timothy
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Description Flags
patch timothy: review+

Description Pavel Feldman 2009-09-26 11:25:57 PDT
- There is no need to track DOM changes while inspector window is hidden. This is different from the way it was working before the dom agent refactoring.
- There is a following bug:
1. Open web inspector for some page
2. Close web inspector
3. Reload the page
4. Open web inspector

Expected: Elements panel showing the DOM tree
Actual: Empty panel

The reason for a bug is that page reload pushes document's representation into the frontend and calls ElementsPanel's refresh. ElementsPanel is trying to be smart and is not processing refreshes while inspector window is hidden. Keeping dom agent operational only while inspector is visible solves both problems.
Comment 1 Pavel Feldman 2009-09-26 11:32:00 PDT
Created attachment 40175 [details]

Note that I needed to restore WebCore::InspectorController::inspectedWindowScriptObjectCleared callback in order to clear injected script properly.
Comment 2 Timothy Hatcher 2009-09-26 12:49:35 PDT
Sounds like bug 28903.
Comment 3 Pavel Feldman 2009-09-27 00:02:44 PDT

*** This bug has been marked as a duplicate of bug 28903 ***