[Webkit-unassigned] [Bug 115014] Web Inspector: Add page number to list from remote web inspector.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Apr 23 18:31:06 PDT 2013


https://bugs.webkit.org/show_bug.cgi?id=115014





--- Comment #5 from Joseph Pecoraro <joepeck at webkit.org>  2013-04-23 18:29:25 PST ---
(From update of attachment 199151)
View in context: https://bugs.webkit.org/attachment.cgi?id=199151&action=review

> Source/WebKit2/UIProcess/InspectorServer/front-end/inspectorPageIndex.html:16
> +                link.appendChild(document.createTextNode("[" + i + "] " + title + (url ? (" [" + url + "]") : "" )));

The for loop is currently "for (var i in pages)". However, "pages" in an array. The for loop should be a regular for loop, not a for..in loop.

    for (var i = 0; i < pages.length; ++i) { ... }

Are the #s important? It looks like the backend generates this array from HashMap iterators. I don't think that guarantees the order of items. Should the items be sorted somewhere here so the numbers don't change seemingly randomly if the Hashmap changes its size?

This change is simple and harmless however, so if it helps it looks good to me.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the webkit-unassigned mailing list