Bug 17980

Summary: REGRESSION (r31177): Inspector highlighting of webpage not cleared when going to new URL
Product: WebKit Reporter: Gavin Sherlock <gsherloc>
Component: Web Inspector (Deprecated)Assignee: Timothy Hatcher <timothy>
Status: RESOLVED FIXED    
Severity: Normal CC: aroben, timothy
Priority: P1 Keywords: Regression
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: OS X 10.5   
Attachments:
Description Flags
Patch aroben: review+

Description Gavin Sherlock 2008-03-20 23:38:34 PDT
Steps to reproduce:

1.  Go to any webpage, right click and Inspect Element.
2.  Arrange windows to make Inspector and web page both visible.
3.  Select DOM node, so corresponding part of web page is highlighted
4.  Switch to web page, and go to new url (e.g. clicking on link).

Expected results:

Highlighting on page will clear

Actual Results:

Highlighting on page persists

Regression:  Not present in Safari 3.1, present in r31201.  Tested on 10.5.2 on dual G5
Comment 1 Gavin Sherlock 2008-03-20 23:41:16 PDT
I should also note that you can resize the webpage, and the highlighting will stay where it is, even to the point that it can no longer overlap the page that it was originally highlighting.
Comment 2 Adam Roben (:aroben) 2008-03-21 07:41:04 PDT
I can't reproduce this in ToT on Windows. Maybe it's a Mac-only issue? I think Tim was seeing something similar.
Comment 3 Timothy Hatcher 2008-03-21 07:59:16 PDT
I know what caused this. When the drawing code was moved to WebCore the fade value is ignored in WebNodeHighlightView. We should just remove the fade.
Comment 4 Timothy Hatcher 2008-03-21 08:48:19 PDT
Created attachment 19927 [details]
Patch

 WebKit/mac/ChangeLog                            |   28 ++++++++
 WebKit/mac/WebCoreSupport/WebInspectorClient.mm |   25 +++-----
 WebKit/mac/WebInspector/WebNodeHighlight.h      |   14 +---
 WebKit/mac/WebInspector/WebNodeHighlight.m      |   77 +++--------------------
 WebKit/mac/WebInspector/WebNodeHighlightView.h  |    8 ---
 WebKit/mac/WebInspector/WebNodeHighlightView.m  |   28 ++-------
 6 files changed, 53 insertions(+), 127 deletions(-)
Comment 5 Adam Roben (:aroben) 2008-03-21 08:50:39 PDT
Comment on attachment 19927 [details]
Patch

 11         how just detaches when it is hidden.

Typo: how -> now

r=me
Comment 6 Timothy Hatcher 2008-03-21 09:39:23 PDT
Landed in r31209.