Bug 143793 - Web Inspector: "Log Value" of a value inside of an array, does not log the innermost value
Summary: Web Inspector: "Log Value" of a value inside of an array, does not log the in...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2015-04-15 13:06 PDT by Joseph Pecoraro
Modified: 2015-04-16 13:55 PDT (History)
8 users (show)

See Also:


Attachments
[PATCH] Proposed Fix (5.43 KB, patch)
2015-04-15 21:32 PDT, Joseph Pecoraro
burg: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Joseph Pecoraro 2015-04-15 13:06:08 PDT
* SUMMARY
"Log Value" of a value inside of an array, does not log the innermost value.

* STEPS TO REPRODUCE
1. js> myObject = { array: [1, {name:"Joe", age:123}] }; dir(myObject)
2. Expand all the way to the inner object
3. Right click "name" and choose "Log Value"
  => Expected "Joe", but got the containing object {name: "Joe", age: 123}
Comment 1 Radar WebKit Bug Importer 2015-04-15 13:06:45 PDT
<rdar://problem/20558139>
Comment 2 Joseph Pecoraro 2015-04-15 13:18:51 PDT
This happens because the GeneralTreeElement event handlers are "useCapture" and thus capture top down. Removing capture mode things work as expected.
Comment 3 Joseph Pecoraro 2015-04-15 21:08:13 PDT
Reusing this to improve context menus in the console in general.
Comment 4 Joseph Pecoraro 2015-04-15 21:32:29 PDT
Created attachment 250898 [details]
[PATCH] Proposed Fix
Comment 5 Brian Burg 2015-04-16 08:08:31 PDT
Comment on attachment 250898 [details]
[PATCH] Proposed Fix

r=me

Any intuition for why this used to be a capturing handler?
Comment 6 Timothy Hatcher 2015-04-16 10:18:04 PDT
(In reply to comment #5)
> Comment on attachment 250898 [details]
> [PATCH] Proposed Fix
> 
> r=me
> 
> Any intuition for why this used to be a capturing handler?

Joe asked me about it before posting this and I had no clue. Likely legacy and a mistake.
Comment 7 Joseph Pecoraro 2015-04-16 13:55:55 PDT
http://trac.webkit.org/changeset/182909