Misc Uncaught TypeError when trying to inspect elements in the New 3DS browser’s developer mode

Nightcat

New Member
OP
Newbie
Joined
Mar 15, 2017
Messages
4
Trophies
1
Location
United States
Website
nightc.at
XP
110
Country
United States
The New 3DS browser contains a hidden mode that allows you to remotely debug webpages from your computer by holding X+Y while launching the browser. However, the element tree is busted. Trying to inspect anything throws an error:
JavaScript:
treeoutline.js:1120 Uncaught TypeError: window.getComputedStyle(...).getPropertyCSSValue is not a function
    at WebInspector.ElementsTreeElement.TreeElement.isEventWithinDisclosureTriangle (treeoutline.js:1120)
    at HTMLLIElement.TreeElement.treeElementMouseDown (treeoutline.js:806)
I’ve tried the latest Chrome and Firefox as well as Chrome 49 and 69 all with no success.

Digging into treeoutline.js shows a comment explaining that this code is not okay:
JavaScript:
TreeElement.prototype.isEventWithinDisclosureTriangle = function(event)
{
    // FIXME: We should not use getComputedStyle(). For that we need to get rid of using ::before for disclosure triangle.
    var computedLeftPadding = window.getComputedStyle(this._listItemNode).getPropertyCSSValue("padding-left").getFloatValue(CSSPrimitiveValue.CSS_PX);
    var left = this._listItemNode.totalOffsetLeft() + computedLeftPadding;
    return event.pageX >= left && event.pageX <= left + this.arrowToggleWidth && this.hasChildren;
}
This issue was marked as RESOLVED WONTFIX on WebKit Bugzilla in June 2016. I can’t fix this myself and Nintendo definitely won’t, so where do I go from here?
 
  • Like
Reactions: jeffyTheHomebrewer

Nightcat

New Member
OP
Newbie
Joined
Mar 15, 2017
Messages
4
Trophies
1
Location
United States
Website
nightc.at
XP
110
Country
United States
Ran into a need to try this again and I kinda assumed this months ago given how many connectivity issues I was having in my basement, but it works on an iMac running Safari closer to my router so I’m assuming it was just my poor/dropped connection.
 
  • Like
Reactions: jeffyTheHomebrewer

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    Psionic Roshambo @ Psionic Roshambo: Even has a slide cover to protect the lenses, was concerned about it how it would work but not...