[
https://issues.apache.org/jira/browse/CB-540?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13257253#comment-13257253
]
Patrick Mueller commented on CB-540:
------------------------------------
Pamela, thx for the bug report.
There are two ways I know of that real Web Inspector does this.
First is the little magnifying glass icon at the bottom of the Elements panel.
When you click it, it puts the mouse in a capture mode in the target browser,
such that when you click on something in the target window, it "selects" that
element in the element browser and expands the element tree to make it visible.
Second is the console command {{inspect(element)}}. Not entirely clear to me
what you are supposed to pass to {{inspect()}}. Maybe a jQuery-esque selector
or something. One thing I got to work is to run the following from the console
(in real web inspector): {{inspect($("credits"))}}. Note this uses Web
Inspector's cheap-o {{$}} function (which sadly masks jQuery, if you're using
it) to expand a node with an id of "credits".
The first method - 'mouse capture' - may be difficult to do, in general, for
mobile, though might end up working out good enough for touch devices. I'll
prolly see if I can implement it, and if it just doesn't work in some
environments, the solution is: DON'T PRESS THE MAGNIFYING GLASS BUTTON ICON.
I'll try to figure out what the argument to inspect() is supposed to be;
apparently you can pass it a DOM node you captured in a variable or expression
anyway.
Will either of those work for you?
I also noticed that real Web Inspector will "remember" the node you currently
have "selected" in the Elements panel when you reload, and expand out to it
when the elements are reloaded. That would be a nice thing to support as well.
Other thoughts?
> Feature Request: ability to easily navigate to particular place in DOM via
> bookmarks/jump to selector
> -----------------------------------------------------------------------------------------------------
>
> Key: CB-540
> URL: https://issues.apache.org/jira/browse/CB-540
> Project: Apache Callback
> Issue Type: Bug
> Components: weinre
> Reporter: Pamela Fox
> Assignee: Patrick Mueller
>
> I often use weinre to debug a particular element in the DOM and CSS changes
> to that element, which means that I'm constantly making new changes and
> re-navigating to that element in the DOM (since the Elements console loses
> its place between reloads). It'd be nice if I could either jump to an element
> by CSS selector or bookmark it somehow, for quicker debugging.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira