-
Notifications
You must be signed in to change notification settings - Fork 11
/
attrsInspector.html
35 lines (33 loc) · 109 KB
/
attrsInspector.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<!DOCTYPE HTML>
<meta charset="utf-8"/>
<title>Attributes Inspector [0.6.5pre4 - 2024-02-27]</title>
<body>
<a href="custombutton://%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%0D%0A%3Ccustombutton%20xmlns%3Acb%3D%22http%3A//xsms.nm.ru/custombuttons/%22%3E%0A%20%20%3Cname%3EAttributes%20Inspector%3C/name%3E%0A%20%20%3Cimage%3E%3C%21%5BCDATA%5Bdata%3Aimage/png%3Bbase64%2CiVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAACW0lEQVQ4jW2SP0tbURjGf+fc6/US0iHcRLA4xTpI45/BwX6BKuIkFHF2KH4AdXTxE7RD184uJdLFJRmtdpCSOlQUihGRIphokhPvzT1vh5irpn3h5XDgPM/7PM95lYiwvr7ura2tvddaaxFRAP85hYeK41iWlpY+Hh8fxy7A0NBQKpPJfNBaE0UR1locx6GHUUqhlEJrjVIKay1BEHwCugS+7+tarUa1WiWVSqGUotFokM1myeVyCVBEErLJyUkXuHcBPM8PqtULZmffJBPi2HJy8ot6vU4mk6G/hoeHXQANUK2ez01NTSEiWGsBcBzN6Ogrrq6u/gErpchmsy6A22V7ORZ1LCoM0Uo/exhFnWf3XqXT6YFEQaVSuRBraTXbNJsGY+4x7XsaTcPt7W3i+2mgvu87CcHdXf1rqVQmijrchyGtlqHZaPGzUiEIgiTEpySe5zmJheXlZZPL5djdLZIfHWPAdTk9PeHo6DszMzNMTBQSgh6J67qPCkREFQoFVlbe8SLtoVTE4uI8GxsblEolisXiM4KHndCJgq4qhed5TE9PIyLJEm1tbbG9vY3v+ywsLNAdqLqAngJA93vUWqO1ZmRkhM3NTcrlMuVyGWuF2Nrku3X3zx33aVD9nc/nWV1d5eDggP39b4iNCcPwUYHW2unf9/4eH3/N27l5zs9/47oOh4eHjQc/wt7e3lS73RZjjBhjpNVqPetGoyk3N3W5uamJMUbOzs5+BEHgi0g3RGNM7fLy8rOIWMCKiFVKWRGxItjYStzphNYfHAzr9fqfnZ2dL9fX122Av72HMgq8RKT9AAAAAElFTkSuQmCC%5D%5D%3E%3C/image%3E%0A%20%20%3Cmode%3E2%3C/mode%3E%0A%20%20%3Cinitcode%3E%3C%21%5BCDATA%5Bthis.onmouseover%20%3D%20function%28e%29%20%7B%0A%09var%20wm%20%3D%20window.Services%20%26%26%20Services.wm%0A%09%09%7C%7C%20Components.classes%5B%[email protected]/appshell/window-mediator%3B1%22%5D%0A%09%09%09.getService%28Components.interfaces.nsIWindowMediator%29%3B%0A%09this.focusedWindow%20%3D%20wm.getMostRecentWindow%28null%29%3B%0A%7D%3B%0Athis.onmouseout%20%3D%20function%28e%29%20%7B%0A%09this.focusedWindow%20%3D%20null%3B%0A%7D%3B%0Athis.setAttribute%28%22oncommand%22%2C%20%22this.focusedWindow%20%26%26%20this.focusedWindow.focus%28%29%3B%22%29%3B%5D%5D%3E%3C/initcode%3E%0A%20%20%3Ccode%3E%3C%21%5BCDATA%5B//%20http%3A//infocatcher.ucoz.net/js/cb/attrsInspector.js%0A//%20https%3A//forum.mozilla-russia.org/viewtopic.php%3Fid%3D56041%0A//%20https%3A//github.com/Infocatcher/Custom_Buttons/tree/master/Attributes_Inspector%0A%0A//%20%28c%29%20Infocatcher%202010-2024%0A//%20version%200.6.5pre4%20-%202024-02-27%0A%0A//%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%0A//%20Attributes%20Inspector%20button%20for%20Custom%20Buttons%0A//%20%28for%20%22code%22%20section%29%0A//%20Also%20the%20code%20can%20be%20used%20from%20main%20window%20context%20%28as%20Mouse%20Gestures%20code%2C%20for%20example%29%0A%0A//%20Usage%3A%0A//%20%20%20Use%20middle-click%20or%20Ctrl%20+%20left-click%20%28or%20press%20Ctrl+I%29%20to%20inspect%20node%20in%20DOM%20Inspector%0A//%20%20%20%28additionally%20hold%20Shift%20key%20to%20enable%20popup%20locker%29%0A//%20%20%20Hold%20Shift%20key%20to%20show%20and%20don%27t%20hide%20tooltips%20and%20popups%0A//%20Hotkeys%3A%0A//%20%20%20Escape%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20-%20cancel%20or%20disable%20popup%20locker%0A//%20%20%20Ctrl+Up%2C%20Ctrl+Down%20%20%20%20-%20navigate%20to%20parent/child%20node%0A//%20%20%20Ctrl+Left%2C%20Ctrl+Right%20-%20navigate%20to%20previous/next%20sibling%20node%0A//%20%20%20Ctrl+Shift+C%20%20%20%20%20%20%20%20%20%20-%20copy%20tooltip%27s%20contents%0A//%20%20%20Ctrl+Shift+W%20%20%20%20%20%20%20%20%20%20-%20inspect%20node%27s%20window%20object%20in%20DOM%20Inspector%0A%0A//%20For%20more%20developer%20tools%20see%20Extensions%20Developer%20Tools%20button%3A%0A//%20%20%20http%3A//infocatcher.ucoz.net/js/cb/extDevTools.js%0A//%20%20%20https%3A//forum.mozilla-russia.org/viewtopic.php%3Fid%3D57296%0A//%20%20%20https%3A//github.com/Infocatcher/Custom_Buttons/tree/master/Extensions_Developer_Tools%0A%0A//%20Icon%3A%20http%3A//www.iconsearch.ru/detailed/278/2/%0A//%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%3D%0A%0A%28function%28%29%20%7B%0Avar%20_highlight%20%3D%20true%3B%20//%20Hightlight%20current%20node%0Avar%20_highlightUsingFlasher%20%3D%20false%3B%20//%20Don%27t%20modify%20DOM%2C%20but%20has%20some%20side%20effects%20%28and%20slower%29%0A//%20Note%3A%20inIFlasher%20works%20in%20Firefox%204+%20only%20with%20disabled%20hardware%20acceleration%21%0A//%20See%20https%3A//bugzilla.mozilla.org/show_bug.cgi%3Fid%3D368608%20and%20https%3A//bugzilla.mozilla.org/show_bug.cgi%3Fid%3D594299%0A//%20Also%20inIFlasher%20not%20available%20in%20Firefox%2033+%2C%20see%20https%3A//bugzilla.mozilla.org/show_bug.cgi%3Fid%3D1018324%0Avar%20_borderColor%20%3D%20%22red%22%3B%20//%20Any%20valid%20CSS%20color%0Avar%20_borderWidth%20%3D%201%3B%20//%20Border%20width%20in%20pixels%0Avar%20_borderStyle%20%3D%20%22solid%22%3B%20//%20border-style%20property%20in%20CSS%0A//%20Note%3A%20doesn%27t%20work%20with%20_highlightUsingFlasher%20%3D%20true%0A%0A//%20Highlight%20added/removed/changed%20attributes%2C%20any%20valid%20CSS%20color%3A%0Avar%20_addedColor%20%3D%20%22-moz-hyperlinktext%22%3B%0Avar%20_removedColor%20%3D%20%22grayText%22%3B%0Avar%20_changedColor%20%3D%20%22-moz-visitedhyperlinktext%22%3B%0A%0Avar%20_maxTooltipWidth%20%3D%20600%3B%20//%20Max%20width%20in%20px%2C%200%20to%20not%20force%20limits%0A%0Avar%20_excludeChildTextNodes%20%3D%201%3B%0A//%200%20-%20don%27t%20exclude%0A//%201%20-%20exclude%2C%20if%20found%20element%20node%0A//%202%20-%20always%20exclude%0Avar%20_excludeSiblingTextNodes%20%3D%20false%3B%0A%0Avar%20_useCycleNavigation%20%3D%20false%3B%0A//%20Use%20cycle%20navigation%20for%20sibling%20nodes%3A%20first%20-%3E%20second%20-%3E%20...%20-%3E%20last%20--%3E%20first%0A%0Avar%20_preferNotAnonymousChildNodes%20%3D%20false%3B%0A//%20true%20%20-%20use%20not%20anonymous%20child%20nodes%2C%20if%20any%20%28as%20in%20version%200.6.1pre%20and%20older%29%0A//%20false%20-%20always%20try%20get%20real%20child%20nodes%20%28may%20work%20wrong%20in%20Gecko%20%3C%207.0%29%0A%0Avar%20_forbidTooltips%20%3D%20true%3B%20//%20Prevent%20all%20other%20tooltips%0Avar%20_popupLocker%20%3D%201%3B%0A//%20Lock%20all%20popups%20in%20window%20while%20DOM%20Inspector%20is%20opened%20%28or%20until%20Escape%20was%20not%20pressed%29%0A//%20Values%3A%200%20-%20disable%2C%201%20-%20only%20if%20Shift%20pressed%2C%202%20-%20always%20enable%0Avar%20_showNamespaceURI%20%3D%202%3B%20//%200%20-%20don%27t%20show%2C%201%20-%20show%20as%20is%2C%202%20-%20show%20pretty%20name%20instead%20of%20URI%0Avar%20_showMargins%20%3D%203%3B%20//%200%20-%20don%27t%20show%2C%201%20-%20only%20if%20Shift%20pressed%2C%202%20-%20only%20if%20Shift%20pressed%20+%20auto%20update%2C%203%20-%20always%20show%0Avar%20_showFullTree%20%3D%202%3B%20//%200%20-%20current%20frame%2C%201%20-%20top%20frame%2C%202%20-%20topmost%20frame%0A//%20Note%3A%20%22View%20-%20Show%20Anonymous%20Content%22%20should%20be%20checked%20to%20inspect%20content%20documents%20with%20%22_showFullTree%20%3D%202%22%0Avar%20_nodePosition%20%3D%200.55%3B%20//%20Position%20of%20selected%20node%20in%20DOM%20Inspector%27s%20tree%2C%200..1%20%28-1%20-%20don%27t%20change%29%0A%0A//%20Show%20debug%20messages%20in%20error%20console%3A%0A//var%20_debug%20%3D%20false%3B%0Avar%20_debug%20%3D%20typeof%20event%20%3D%3D%20%22object%22%20%26%26%20event%20instanceof%20Event%0A%09%3F%20event.shiftKey%20%7C%7C%20event.ctrlKey%20%7C%7C%20event.altKey%20%7C%7C%20event.metaKey%0A%09%3A%20false%3B%0A%0Afunction%20_log%28s%29%20%7B%0A%09if%28%21_debug%29%0A%09%09return%20_log%20%3D%20function%28s%29%20%7B%7D%3B%0A%09var%20cs%20%3D%20Components.classes%5B%[email protected]/consoleservice%3B1%22%5D%0A%09%09.getService%28Components.interfaces.nsIConsoleService%29%3B%0A%09function%20ts%28%29%20%7B%0A%09%09var%20d%20%3D%20new%20Date%28%29%3B%0A%09%09var%20ms%20%3D%20d.getMilliseconds%28%29%3B%0A%09%09return%20d.toTimeString%28%29.replace%28/%5E.*%5Cd+%3A%28%5Cd+%3A%5Cd+%29.*%24/%2C%20%22%241%22%29%20+%20%22%3A%22%20+%20%22000%22.substr%28%28%22%22%20+%20ms%29.length%29%20+%20ms%20+%20%22%20%22%3B%0A%09%7D%0A%09_log%20%3D%20function%28s%29%20%7B%0A%09%09cs.logStringMessage%28%22%5BAttributes%20Inspector%5D%3A%20%22%20+%20ts%28%29%20+%20%22%20%22%20+%20s%29%3B%0A%09%7D%3B%0A%09return%20_log%28s%29%3B%0A%7D%0A%0Aconst%20_ns%20%3D%20%22__attributesInspector%22%3B%0A%0Avar%20context%3B%0Avar%20wm%20%3D%20Components.classes%5B%[email protected]/appshell/window-mediator%3B1%22%5D%0A%09.getService%28Components.interfaces.nsIWindowMediator%29%3B%0Avar%20ws%20%3D%20wm.getEnumerator%28null%29%3B%0Awhile%28ws.hasMoreElements%28%29%29%20%7B%0A%09var%20w%20%3D%20ws.getNext%28%29%3B%0A%09if%28_ns%20in%20w%29%20%7B%0A%09%09context%20%3D%20w%5B_ns%5D%3B%0A%09%09break%3B%0A%09%7D%0A%7D%0Aif%28%21context%29%20%7B%0A%09context%20%3D%20window%5B_ns%5D%20%3D%20%7B%0A%09%09button%3A%20this%20instanceof%20XULElement%20%26%26%20this.localName%20%21%3D%20%22popupset%22%20%26%26%20this%2C%0A%09%09checked%3A%20false%2C%0A%09%09wm%3A%20wm%2C%0A%09%09toggle%3A%20function%28%29%20%7B%0A%09%09%09toggle.call%28context%29%3B%0A%09%09%7D%2C%0A%09%09stop%3A%20function%28%29%20%7B%0A%09%09%09this.checked%20%26%26%20this.toggle%28%29%3B%0A%09%09%7D%0A%09%7D%3B%0A%7D%0A%0Afunction%20ael%28type%2C%20func%2C%20useCapture%2C%20target%29%20%7B%0A%09return%20%28target%20%7C%7C%20window%29.addEventListener%28type%2C%20func%2C%20useCapture%29%3B%0A%7D%0Afunction%20rel%28type%2C%20func%2C%20useCapture%2C%20target%29%20%7B%0A%09//%20Trick%20for%20Firefox%2036.0a1%0A%09if%28%22EventTarget%22%20in%20window%20%26%26%20EventTarget.prototype%20%26%26%20EventTarget.prototype.removeEventListener%29%20try%20%7B%0A%09%09EventTarget.prototype.removeEventListener.call%28target%20%7C%7C%20window%2C%20type%2C%20func%2C%20useCapture%29%3B%0A%09%7D%0A%09catch%28e%29%20%7B%0A%09%7D%0A%09return%20%28target%20%7C%7C%20window%29.removeEventListener%28type%2C%20func%2C%20useCapture%29%3B%0A%7D%0Afunction%20defineGetter%28o%2C%20p%2C%20g%29%20%7B%0A%09defineGetter%20%3D%20%22defineProperty%22%20in%20Object%20//%20Firefox%20%3E%3D%204.0%0A%09%09%3F%20function%28o%2C%20p%2C%20g%29%20%7B%0A%09%09%09Object.defineProperty%28o%2C%20p%2C%20%7B%0A%09%09%09%09get%3A%20g%2C%0A%09%09%09%09configurable%3A%20true%2C%0A%09%09%09%09enumerable%3A%20true%0A%09%09%09%7D%29%3B%0A%09%09%7D%0A%09%09%3A%20function%28o%2C%20p%2C%20g%29%20%7B%0A%09%09%09Object.__defineGetter__.call%28o%2C%20p%2C%20g%29%3B%0A%09%09%7D%3B%0A%09return%20defineGetter.apply%28this%2C%20arguments%29%3B%0A%7D%0A%0Acontext.toggle%28%29%3B%0A%0Afunction%20toggle%28%29%20%7B%0A%09var%20checked%20%3D%20this.checked%20%3D%20%21this.checked%3B%0A%09var%20btn%20%3D%20this.button%3B%0A%09if%28btn%29%20%7B%0A%09%09btn.checked%20%3D%20checked%3B%0A%09%09if%28%21checked%29%20%7B%0A%09%09%09var%20doc%20%3D%20btn.ownerDocument%3B%0A%09%09%09%28function%20uncheck%28%29%20%7B%20//%20D%27oh...%0A%09%09%09%09for%28var%20node%20%3D%20btn.parentNode%3B%20node%20%21%3D%20doc%3B%20node%20%3D%20node.parentNode%29%20%7B%0A%09%09%09%09%09if%28%21node%29%20%7B%20//%20Node%20was%20removed%20from%20document%0A%09%09%09%09%09%09_log%28%22Button%20was%20removed%20from%20document%22%29%3B%0A%09%09%09%09%09%09var%20toolboxes%20%3D%20doc.getElementsByTagName%28%22toolbox%22%29%3B%0A%09%09%09%09%09%09for%28var%20i%20%3D%200%2C%20l%20%3D%20toolboxes.length%3B%20i%20%3C%20l%3B%20++i%29%20%7B%0A%09%09%09%09%09%09%09var%20toolbox%20%3D%20toolboxes%5Bi%5D%3B%0A%09%09%09%09%09%09%09if%28%22palette%22%20in%20toolbox%20%26%26%20toolbox.palette%29%20%7B%0A%09%09%09%09%09%09%09%09var%20paletteBtns%20%3D%20toolbox.palette.getElementsByAttribute%28%22id%22%2C%20btn.id%29%3B%0A%09%09%09%09%09%09%09%09var%20paletteBtn%20%3D%20paletteBtns.length%20%26%26%20paletteBtns%5B0%5D%3B%0A%09%09%09%09%09%09%09%09if%28paletteBtn%20%26%26%20paletteBtn.getAttribute%28%22checked%22%29%20%3D%3D%20%22true%22%29%20%7B%0A%09%09%09%09%09%09%09%09%09_log%28%22Uncheck%20pallete%20button%22%29%3B%0A%09%09%09%09%09%09%09%09%09paletteBtn.removeAttribute%28%22checked%22%29%3B%0A%09%09%09%09%09%09%09%09%09break%3B%0A%09%09%09%09%09%09%09%09%7D%0A%09%09%09%09%09%09%09%7D%0A%09%09%09%09%09%09%7D%0A%09%09%09%09%09%09return%3B%0A%09%09%09%09%09%7D%0A%09%09%09%09%7D%0A%09%09%09%09//if%28%21doc.getElementById%28%22wrapper-%22%20+%20btn.id%29%29%20%7B%0A%09%09%09%09if%28btn.parentNode.localName%20%21%3D%20%22toolbarpaletteitem%22%29%20%7B%0A%09%09%09%09%09if%28btn.checked%20%21%3D%20checked%29%20%7B%0A%09%09%09%09%09%09btn.checked%20%3D%20checked%3B%0A%09%09%09%09%09%09_log%28%22Set%20checked%20state%3A%20%22%20+%20checked%29%3B%0A%09%09%09%09%09%09return%3B%0A%09%09%09%09%09%7D%0A%09%09%09%09%09_log%28%22Button%20checked%20state%20is%20correct%22%29%3B%0A%09%09%09%09%09return%3B%0A%09%09%09%09%7D%0A%09%09%09%09if%28%21uncheck.hasOwnProperty%28%22_logged%22%29%29%20%7B%0A%09%09%09%09%09uncheck._logged%20%3D%20true%3B%0A%09%09%09%09%09_log%28%22Button%20is%20wrapped%2C%20wait...%22%29%3B%0A%09%09%09%09%7D%0A%09%09%09%09doc.defaultView.setTimeout%28uncheck%2C%2020%29%3B%0A%09%09%09%7D%29%28%29%3B%0A%09%09%7D%0A%09%7D%0A%09if%28checked%29%0A%09%09init.call%28this%29%3B%0A%09else%0A%09%09destroy.call%28this%29%3B%0A%7D%0Afunction%20init%28%29%20%7B%0A%09var%20tt%20%3D%20this.tt%20%3D%20document.createElementNS%28%22http%3A//www.mozilla.org/keymaster/gatekeeper/there.is.only.xul%22%2C%20%22tooltip%22%29%3B%0A%09tt.id%20%3D%20%22__attrsInspectorTooltip%22%3B%0A%09tt.setAttribute%28%22orient%22%2C%20%22vertical%22%29%3B%0A%09if%28_maxTooltipWidth%20%3E%200%29%20%7B%0A%09%09_maxTooltipWidth%20%3D%20Math.min%28_maxTooltipWidth%2C%20%28screen.availWidth%20%7C%7C%20screen.width%29%20-%2020%29%20+%20%22px%22%3B%0A%09%09tt.style.maxWidth%20%3D%20_maxTooltipWidth%3B%0A%09%7D%0A%09//if%28%22pointerEvents%22%20in%20tt.style%29%0A%09//%09tt.style.pointerEvents%20%3D%20%22none%22%3B%0A%09tt.setAttribute%28%22mousethrough%22%2C%20%22always%22%29%3B%0A%09top.document.documentElement.appendChild%28tt%29%3B%0A%0A%09var%20tts%20%3D%20tt.style%3B%0A%09//%20Trick%20to%20force%20repaint%20tooltip%2C%20see%20https%3A//github.com/Infocatcher/Custom_Buttons/issues/25%0A%09tts.opacity%20%3D%20%220.99%22%3B%0A%0A%09//%20Resolve%20-moz-*%20and%20system%20colors%20%28for%20copy%20tooltip%20contents%20feature%29%0A%09var%20ttcs%20%3D%20top.getComputedStyle%28tt%2C%20null%29%3B%0A%09tts.color%20%3D%20_addedColor%3B%0A%09_addedColor%20%3D%20ttcs.color%3B%0A%09tts.color%20%3D%20_removedColor%3B%0A%09_removedColor%20%3D%20ttcs.color%3B%0A%09tts.color%20%3D%20_changedColor%3B%0A%09_changedColor%20%3D%20ttcs.color%3B%0A%09tts.color%20%3D%20%22%22%3B%0A%0A%09if%28%21_highlightUsingFlasher%29%20%7B%0A%09%09this.hlAttrNS%20%3D%20%22urn%3AattrsInspectorNS%22%3B%0A%09%09this.hlAttr%20%3D%20%22__attrs_inspector_highlighted__%22%3B%20//%20Don%27t%20use%20caps%20here%20-%20works%20only%20in%20Firefox%204%0A%09%09var%20sss%20%3D%20this.sss%20%3D%20Components.classes%5B%[email protected]/content/style-sheet-service%3B1%22%5D%0A%09%09%09.getService%28Components.interfaces.nsIStyleSheetService%29%3B%0A%09%09var%20cssStr%20%3D%20%27%5C%0A%09%09%09/*%20Attributes%20Inspector%20highlight%20styles%20*/%5Cn%5C%0A%09%09%09@namespace%20ains%20url%28%22%25ns%25%22%29%3B%5Cn%5C%0A%09%09%09%25priorityHack%25%5Bains%7C%25attr%25%3D%22true%22%5D%20%7B%5Cn%5C%0A%09%09%09%09outline%3A%20%25borderWidth%25px%20%25borderStyle%25%20%25borderColor%25%20%21important%3B%5Cn%5C%0A%09%09%09%09outline-offset%3A%20-%25borderWidth%25px%20%21important%3B%5Cn%5C%0A%09%09%09%7D%27%0A%09%09%09.replace%28/%25ns%25/g%2C%20this.hlAttrNS%29%0A%09%09%09.replace%28/%25attr%25/g%2C%20this.hlAttr%29%0A%09%09%09.replace%28/%25borderColor%25/g%2C%20_borderColor%29%0A%09%09%09.replace%28/%25borderWidth%25/g%2C%20_borderWidth%29%0A%09%09%09.replace%28/%25borderStyle%25/g%2C%20_borderStyle%29%0A%09%09%09.replace%28/%25priorityHack%25/g%2C%20%28function%28%29%20%7B%0A%09%09%09%09var%20rnd%20%3D%20Math.random%28%29.toFixed%2816%29.substr%282%29%3B%0A%09%09%09%09var%20hack%20%3D%20%22*%7C*%22%3B%0A%09%09%09%09for%28var%20i%20%3D%200%3B%20i%20%3C%2016%3B%20++i%29%0A%09%09%09%09%09hack%20+%3D%20%22%3Anot%28%23__priorityHack__%22%20+%20rnd%20+%20%22__%22%20+%20i%20+%20%22%29%22%3B%0A%09%09%09%09return%20hack%3B%0A%09%09%09%7D%29%28%29%29%3B%0A%09%09var%20cssURI%20%3D%20this.cssURI%20%3D%20Components.classes%5B%[email protected]/network/io-service%3B1%22%5D%0A%09%09%09.getService%28Components.interfaces.nsIIOService%29%0A%09%09%09.newURI%28%22data%3Atext/css%2C%22%20+%20encodeURIComponent%28cssStr%29%2C%20null%2C%20null%29%3B%0A%09%09if%28%21sss.sheetRegistered%28cssURI%2C%20sss.AGENT_SHEET%29%29%0A%09%09%09sss.loadAndRegisterSheet%28cssURI%2C%20sss.AGENT_SHEET%29%3B%0A%09%09if%28%21sss.sheetRegistered%28cssURI%2C%20sss.USER_SHEET%29%29%0A%09%09%09sss.loadAndRegisterSheet%28cssURI%2C%20sss.USER_SHEET%29%3B%0A%09%7D%0A%0A%09this.setAllListeners%20%3D%20function%28action%29%20%7B%0A%09%09var%20ws%20%3D%20this.wm.getEnumerator%28null%29%3B%0A%09%09while%28ws.hasMoreElements%28%29%29%0A%09%09%09this.setListeners%28action%2C%20ws.getNext%28%29%29%3B%0A%09%7D%3B%0A%09this.setListeners%20%3D%20function%28action%2C%20w%29%20%7B%0A%09%09var%20h%20%3D%20this.eventHandler%3B%0A%0A%09%09action%28%22mouseover%22%2C%20h%2C%20true%2C%20w%29%3B%0A%09%09action%28%22mousemove%22%2C%20h%2C%20true%2C%20w%29%3B%0A%09%09action%28%22mouseout%22%2C%20%20h%2C%20true%2C%20w%29%3B%0A%0A%09%09action%28%22draggesture%22%2C%20h%2C%20true%2C%20w%29%3B%0A%09%09action%28%22dragover%22%2C%20%20%20%20h%2C%20true%2C%20w%29%3B%0A%09%09action%28%22dragexit%22%2C%20%20%20%20h%2C%20true%2C%20w%29%3B%0A%0A%09%09action%28%22keydown%22%2C%20%20%20h%2C%20true%2C%20w%29%3B%0A%09%09action%28%22keypress%22%2C%20%20h%2C%20true%2C%20w%29%3B%0A%09%09action%28%22keyup%22%2C%20%20%20%20%20h%2C%20true%2C%20w%29%3B%0A%0A%09%09//if%28action%20%3D%3D%20rel%20%7C%7C%20this.inspector%29%20%7B%0A%09%09action%28%22mousedown%22%2C%20h%2C%20true%2C%20w%29%3B%0A%09%09action%28%22mouseup%22%2C%20%20%20h%2C%20true%2C%20w%29%3B%0A%09%09action%28%22click%22%2C%20%20%20%20%20h%2C%20true%2C%20w%29%3B%0A%09%09//%7D%0A%0A%09%09action%28%22popupshown%22%2C%20h%2C%20true%2C%20w%29%3B%0A%09%09if%28_forbidTooltips%29%20%7B%0A%09%09%09action%28%22popupshowing%22%2C%20h%2C%20true%2C%20w%29%3B%0A%09%09%09action%28%22popuphiding%22%2C%20%20h%2C%20true%2C%20w%29%3B%0A%09%09%7D%0A%09%7D%3B%0A%09this.ww%20%3D%20Components.classes%5B%[email protected]/embedcomp/window-watcher%3B1%22%5D%0A%09%09.getService%28Components.interfaces.nsIWindowWatcher%29%3B%0A%0A%09this.eventHandler%20%3D%20%7B%0A%09%09context%3A%20this%2C%0A%09%09window%3A%20window%2C%0A%09%09_hl%3A%20null%2C%0A%09%09_node%3A%20null%2C%0A%09%09_nodes%3A%20%5B%5D%2C%0A%09%09handleEvent%3A%20function%28e%29%20%7B%0A%09%09%09this%5Be.type%20+%20%22Handler%22%5D%28e%29%3B%0A%09%09%7D%2C%0A%09%09e%3A%20function%28nn%29%20%7B%0A%09%09%09return%20document.createElementNS%28%22http%3A//www.w3.org/1999/xhtml%22%2C%20nn%29%3B%0A%09%09%7D%2C%0A%09%09s%3A%20function%28v%2C%20tag%29%20%7B%0A%09%09%09var%20s%20%3D%20this.e%28tag%20%7C%7C%20%22span%22%29%3B%0A%09%09%09s.appendChild%28document.createTextNode%28v%29%29%3B%0A%09%09%09return%20s%3B%0A%09%09%7D%2C%0A%09%09getHeader%3A%20function%28v%2C%20state%29%20%7B%0A%09%09%09var%20e%20%3D%20this.s%28v%2C%20%22strong%22%29%3B%0A%09%09%09e.className%20%3D%20%22attrsInspector-header%22%3B%0A%09%09%09state%20%26%26%20this.setState%28e%2C%20state%29%3B%0A%09%09%09return%20e%3B%0A%09%09%7D%2C%0A%09%09get%20separator%28%29%20%7B%0A%09%09%09var%20sep%20%3D%20this._separator%20%3D%20this.s%28%22%20%3D%20%22%29%3B%0A%09%09%09sep.className%20%3D%20%22attrsInspector-separator%22%3B%0A%09%09%09defineGetter%28this%2C%20%22separator%22%2C%20function%28%29%20%7B%0A%09%09%09%09return%20this._separator.cloneNode%28true%29%3B%0A%09%09%09%7D%29%3B%0A%09%09%09return%20this.separator%3B%0A%09%09%7D%2C%0A%09%09get%20space%28%29%20%7B%0A%09%09%09var%20sp%20%3D%20this._space%20%3D%20this.s%28%22%20%22%29%3B%0A%09%09%09sp.className%20%3D%20%22attrsInspector-space%22%3B%0A%09%09%09defineGetter%28this%2C%20%22space%22%2C%20function%28%29%20%7B%0A%09%09%09%09return%20this._space.cloneNode%28true%29%3B%0A%09%09%09%7D%29%3B%0A%09%09%09return%20this.space%3B%0A%09%09%7D%2C%0A%09%09get%20colon%28%29%20%7B%0A%09%09%09var%20col%20%3D%20this._colon%20%3D%20this.s%28%22%3A%20%22%29%3B%0A%09%09%09col.className%20%3D%20%22attrsInspector-colon%22%3B%0A%09%09%09defineGetter%28this%2C%20%22colon%22%2C%20function%28%29%20%7B%0A%09%09%09%09return%20this._colon.cloneNode%28true%29%3B%0A%09%09%09%7D%29%3B%0A%09%09%09return%20this.colon%3B%0A%09%09%7D%2C%0A%09%09getValue%3A%20function%28v%2C%20state%29%20%7B%0A%09%09%09var%20e%20%3D%20this.s%28v%29%3B%0A%09%09%09//e.style.whiteSpace%20%3D%20%22pre%22%3B%0A%09%09%09e.className%20%3D%20%22attrsInspector-value%22%3B%0A%09%09%09state%20%26%26%20this.setState%28e%2C%20state%29%3B%0A%09%09%09return%20e%3B%0A%09%09%7D%2C%0A%09%09setState%3A%20function%28e%2C%20state%29%20%7B%0A%09%09%09if%28state.isRemoved%29%20%7B%0A%09%09%09%09e.style.color%20%3D%20_removedColor%3B%0A%09%09%09%09e.style.textDecoration%20%3D%20%22line-through%22%3B%0A%09%09%09%09e.className%20+%3D%20%22%20attrsInspector-removed%22%3B%0A%09%09%09%7D%0A%09%09%09if%28state.isAdded%29%20%7B%0A%09%09%09%09e.style.color%20%3D%20_addedColor%3B%0A%09%09%09%09e.className%20+%3D%20%22%20attrsInspector-added%22%3B%0A%09%09%09%7D%0A%09%09%09if%28state.isChanged%29%20%7B%20//%20Can%20be%20added%20and%20changed%21%0A%09%09%09%09e.style.color%20%3D%20_changedColor%3B%0A%09%09%09%09e.className%20+%3D%20%22%20attrsInspector-changed%22%3B%0A%09%09%09%7D%0A%09%09%7D%2C%0A%09%09get%20overflowBox%28%29%20%7B%0A%09%09%09var%20overflowBox%20%3D%20this._overflowBox%20%3D%20this.e%28%22div%22%29%3B%0A%09%09%09overflowBox.style.overflow%20%3D%20%22hidden%22%3B%0A%09%09%09overflowBox.className%20%3D%20%22attrsInspector-itemContainer%22%3B%0A%0A%09%09%09var%20item%20%3D%20this.e%28%22div%22%29%3B%0A%09%09%09item.style.lineHeight%20%3D%20%221.25%22%3B%0A%09%09%09item.style.maxHeight%20%3D%20%2212.5em%22%3B%0A%09%09%09//%20Note%3A%20max-width%20for%20tooltip%20itself%20may%20not%20work%20with%20classic%20windows%20theme%0A%09%09%09if%28_maxTooltipWidth%29%0A%09%09%09%09item.style.maxWidth%20%3D%20_maxTooltipWidth%3B%0A%09%09%09item.className%20%3D%20%22attrsInspector-item%22%3B%0A%0A%09%09%09overflowBox.appendChild%28item%29%3B%0A%0A%09%09%09defineGetter%28this%2C%20%22overflowBox%22%2C%20function%28%29%20%7B%0A%09%09%09%09return%20this._overflowBox.cloneNode%28true%29%3B%0A%09%09%09%7D%29%3B%0A%09%09%09return%20this.overflowBox%3B%0A%09%09%7D%2C%0A%09%09getItem%3A%20function%28header%2C%20value%2C%20separator%2C%20state%29%20%7B%0A%09%09%09var%20overflowBox%20%3D%20this.overflowBox%3B%0A%09%09%09var%20item%20%3D%20overflowBox.firstChild%3B%0A%09%09%09item.appendChild%28this.getHeader%28header%2C%20state%29%29%3B%0A%09%09%09if%28value%29%20%7B%0A%09%09%09%09item.appendChild%28separator%20%7C%7C%20this.separator%29%3B%0A%09%09%09%09item.appendChild%28this.getValue%28value%2C%20state%29%29%3B%0A%09%09%09%7D%0A%09%09%09return%20overflowBox%3B%0A%09%09%7D%2C%0A%09%09_setDataLast%3A%20%5B0%2C%200%2C%200%2C%200%2C%200%5D%2C%20//%20Array%20length%20-%20count%20of%20fast%20updates%0A%09%09_setDataMinDelay%3A%20750%2C%20//%20Delay%20between%20two%20series%20of%20fast%20updates%0A%09%09_setDataScheduled%3A%20false%2C%0A%09%09setDataProxy%3A%20function%28node%29%20%7B%0A%09%09%09if%28this._setDataScheduled%29%0A%09%09%09%09return%3B%0A%09%09%09var%20dt%20%3D%20this._setDataLast%5B0%5D%20+%20this._setDataMinDelay%20-%20Date.now%28%29%3B%0A%09%09%09if%28dt%20%3E%200%29%20%7B%0A%09%09%09%09this._setDataScheduled%20%3D%20true%3B%0A%09%09%09%09this.timer%28function%28%29%20%7B%0A%09%09%09%09%09this._setDataScheduled%20%3D%20false%3B%0A%09%09%09%09%09if%28node%20%3D%3D%20this._node%29%20%7B%0A%09%09%09%09%09%09this.setData%28node%29%3B%0A%09%09%09%09%09%09this.setDataProxyTime%28%29%3B%0A%09%09%09%09%09%7D%0A%09%09%09%09%7D%2C%20this%2C%20dt%29%3B%0A%09%09%09%09return%3B%0A%09%09%09%7D%0A%09%09%09this.setData%28node%29%3B%0A%09%09%09this.setDataProxyTime%28%29%3B%0A%09%09%7D%2C%0A%09%09setDataProxyTime%3A%20function%28%29%20%7B%0A%09%09%09var%20a%20%3D%20this._setDataLast%3B%0A%09%09%09a.push%28Date.now%28%29%29%3B%0A%09%09%09a.shift%28%29%3B%0A%09%09%7D%2C%0A%09%09_hasData%3A%20false%2C%0A%09%09setData%3A%20function%28node%29%20%7B%0A%09%09%09var%20tt%20%3D%20this.context.tt%3B%0A%09%09%09this._hasData%20%3D%20true%3B%0A%0A%09%09%09var%20_this%20%3D%20this%3B%0A%09%09%09var%20df%20%3D%20tt.ownerDocument.createDocumentFragment%28%29%3B%0A%09%09%09function%20flush%28%29%20%7B%0A%09%09%09%09tt.textContent%20%3D%20%22%22%3B%0A%09%09%09%09//%20Firefox%20sometimes%20sets%20width/height%20to%20limit%20very%20huge%20tooltip%0A%09%09%09%09tt.removeAttribute%28%22width%22%29%3B%0A%09%09%09%09tt.removeAttribute%28%22height%22%29%3B%0A%09%09%09%09tt.appendChild%28df%29%3B%0A%09%09%09%09if%28%22state%22%20in%20tt%20%26%26%20tt.state%20%3D%3D%20%22closed%22%29%20//%20Strange%20things%20happens%0A%09%09%09%09%09_this.mousemoveHandler%28%29%3B%20//%20Force%20show%0A%09%09%09%7D%0A%0A%09%09%09if%28node.nodeType%20%3D%3D%20node.DOCUMENT_NODE%29%20%7B%0A%09%09%09%09df.appendChild%28this.getItem%28node.nodeName%29%29%3B%0A%09%09%09%09df.appendChild%28this.getItem%28%22documentURI%22%2C%20node.documentURI%2C%20this.colon%29%29%3B%0A%09%09%09%09node.title%20%26%26%20df.appendChild%28this.getItem%28%22title%22%2C%20node.title%2C%20this.colon%29%29%3B%0A%09%09%09%09var%20doctype%20%3D%20%22doctype%22%20in%20node%20%26%26%20node.doctype%3B%0A%09%09%09%09if%28doctype%20%26%26%20doctype%20%3D%3D%20node.firstChild%29%20%7B%0A%09%09%09%09%09var%20dt%3B%0A%09%09%09%09%09if%28doctype.name%20%3D%3D%20%22html%22%20%26%26%20doctype.publicId%20%3D%3D%20%22%22%20%26%26%20doctype.systemId%20%3D%3D%20%22%22%29%0A%09%09%09%09%09%09dt%20%3D%20%22HTML5%22%3B%0A%09%09%09%09%09else%20if%28doctype.publicId%29%0A%09%09%09%09%09%09dt%20%3D%20%28%22%22%20+%20doctype.publicId%29.replace%28/%5E-%5C/%5C/W3C%5C/%5C/DTD%5Cs+%7C%5C/%5C/EN%24/ig%2C%20%22%22%29%3B%0A%09%09%09%09%09else%0A%09%09%09%09%09%09dt%20%3D%20doctype.systemId%3B%0A%09%09%09%09%09df.appendChild%28this.getItem%28%22doctype%22%2C%20dt%2C%20this.colon%29%29%3B%0A%09%09%09%09%7D%0A%09%09%09%09if%28%22contentType%22%20in%20node%29%0A%09%09%09%09%09df.appendChild%28this.getItem%28%22contentType%22%2C%20node.contentType%2C%20this.colon%29%29%3B%0A%09%09%09%09if%28%22characterSet%22%20in%20node%29%0A%09%09%09%09%09df.appendChild%28this.getItem%28%22characterSet%22%2C%20node.characterSet%2C%20this.colon%29%29%3B%0A%09%09%09%09if%28%22compatMode%22%20in%20node%29%0A%09%09%09%09%09df.appendChild%28this.getItem%28%22compatMode%22%2C%20node.compatMode%2C%20this.colon%29%29%3B%0A%09%09%09%09if%28%22lastModified%22%20in%20node%29%20%7B%0A%09%09%09%09%09var%20dt%20%3D%20new%20Date%28node.lastModified%29%3B%0A%09%09%09%09%09var%20dts%20%3D%20isNaN%28dt.getTime%28%29%29%20%3F%20node.lastModified%20%3A%20dt.toLocaleString%28%29%3B%0A%09%09%09%09%09df.appendChild%28this.getItem%28%22lastModified%22%2C%20dts%2C%20this.colon%29%29%3B%0A%09%09%09%09%7D%0A%09%09%09%09if%28%22designMode%22%20in%20node%20%26%26%20node.designMode%20%21%3D%20%22off%22%29%0A%09%09%09%09%09df.appendChild%28this.getItem%28%22designMode%22%2C%20node.designMode%2C%20this.colon%29%29%3B%0A%09%09%09%09flush%28%29%3B%0A%09%09%09%09return%3B%0A%09%09%09%7D%0A%0A%09%09%09var%20rect%20%3D%20this.getRect%28node%29%3B%0A%09%09%09var%20w%20%3D%20rect%20%26%26%20rect.width%3B%0A%09%09%09var%20h%20%3D%20rect%20%26%26%20rect.height%3B%0A%09%09%09if%28%21w%20%26%26%20%21h%29%0A%09%09%09%09df.appendChild%28this.getItem%28node.nodeName%29%29%3B%0A%09%09%09else%20%7B%0A%09%09%09%09//if%28Math.floor%28w%29%20%21%3D%20w%29%0A%09%09%09%09if%28/%5C.%5Cd%7B4%2C%7D%24/.test%28w%29%29%0A%09%09%09%09%09w%20%3D%20w.toFixed%283%29%3B%0A%09%09%09%09//if%28Math.floor%28h%29%20%21%3D%20h%29%0A%09%09%09%09if%28/%5C.%5Cd%7B4%2C%7D%24/.test%28h%29%29%0A%09%09%09%09%09h%20%3D%20h.toFixed%283%29%3B%0A%09%09%09%09df.appendChild%28this.getItem%28node.nodeName%2C%20%22%5B%22%20+%20w%20+%20%22%5Cxd7%22%20+%20h%20+%20%22%5D%22%2C%20this.space%29%29%3B%0A%09%09%09%7D%0A%0A%09%09%09var%20nodeNS%20%3D%20node.namespaceURI%3B%0A%09%09%09if%28_showNamespaceURI/*%20%26%26%20node.nodeName.indexOf%28%22%3A%22%29%20%3D%3D%20-1*/%29%0A%09%09%09%09df.appendChild%28this.getItem%28%22namespaceURI%22%2C%20this.getNS%28nodeNS%29%2C%20this.colon%29%29%3B%0A%0A%09%09%09var%20win%20%3D%20node.ownerDocument.defaultView%3B%0A%09%09%09if%28_showMargins%20%26%26%20node%20instanceof%20Element%29%20%7B%0A%09%09%09%09var%20cs%20%3D%20win.getComputedStyle%28node%2C%20null%29%3B%0A%09%09%09%09var%20dirs%20%3D%20%5B%22Top%22%2C%20%22Right%22%2C%20%22Bottom%22%2C%20%22Left%22%5D%3B%0A%09%09%09%09var%20getMargins%20%3D%20function%28prop%2C%20propAdd%29%20%7B%0A%09%09%09%09%09if%28%21propAdd%29%0A%09%09%09%09%09%09propAdd%20%3D%20%22%22%3B%0A%09%09%09%09%09var%20margins%20%3D%20dirs.map%28function%28dir%2C%20i%29%20%7B%0A%09%09%09%09%09%09var%20margin%20%3D%20cs%5Bprop%20+%20dir%20+%20propAdd%5D%3B%0A%09%09%09%09%09%09if%28margin%20%3D%3D%20%220px%22%29%0A%09%09%09%09%09%09%09return%20%220%22%3B%0A%09%09%09%09%09%09if%28/%5C.%5Cd%7B4%2C%7Dpx%24/.test%28margin%29%29%0A%09%09%09%09%09%09%09return%20parseFloat%28margin%29.toFixed%283%29%20+%20%22px%22%3B%0A%09%09%09%09%09%09return%20margin%3B%0A%09%09%09%09%09%7D%29%3B%0A%09%09%09%09%09if%28margins%5B0%5D%20%3D%3D%20margins%5B2%5D%20%26%26%20margins%5B1%5D%20%3D%3D%20margins%5B3%5D%29%20%7B%0A%09%09%09%09%09%09if%28margins%5B0%5D%20%3D%3D%20margins%5B1%5D%29%0A%09%09%09%09%09%09%09return%20margins%5B0%5D%3B%0A%09%09%09%09%09%09return%20margins%5B0%5D%20+%20%22%20%22%20+%20margins%5B1%5D%3B%0A%09%09%09%09%09%7D%0A%09%09%09%09%09return%20margins.join%28%22%20%22%29%3B%0A%09%09%09%09%7D%0A%09%09%09%09var%20boxSizing%20%3D%20%22boxSizing%22%20in%20cs%20%3F%20cs.boxSizing%20%3A%20cs.MozBoxSizing%3B%0A%09%09%09%09var%20boxSizingNote%20%3D%20%22%20*box-sizing%22%3B%0A%09%09%09%09var%20styles%20%3D%20%7B%0A%09%09%09%09%09margin%3A%20getMargins%28%22margin%22%29%2C%0A%09%09%09%09%09border%3A%20getMargins%28%22border%22%2C%20%22Width%22%29%20+%20%28%0A%09%09%09%09%09%09boxSizing%20%3D%3D%20%22border-box%22%0A%09%09%09%09%09%09%09%26%26%20nodeNS%20%21%3D%20%22http%3A//www.mozilla.org/keymaster/gatekeeper/there.is.only.xul%22%0A%09%09%09%09%09%09%3F%20boxSizingNote%0A%09%09%09%09%09%09%3A%20%22%22%0A%09%09%09%09%09%29%2C%0A%09%09%09%09%09padding%3A%20getMargins%28%22padding%22%29%0A%09%09%09%09%09%09+%20%28boxSizing%20%3D%3D%20%22padding-box%22%20%3F%20boxSizingNote%20%3A%20%22%22%29%2C%0A%09%09%09%09%09__proto__%3A%20null%0A%09%09%09%09%7D%3B%0A%09%09%09%09var%20prevStyles%20%3D%20this.prevStyles%3B%0A%09%09%09%09var%20changedStyles%20%3D%20this.changedStyles%3B%0A%09%09%09%09for%28var%20p%20in%20prevStyles%29%0A%09%09%09%09%09if%28styles%5Bp%5D%20%21%3D%20prevStyles%5Bp%5D%29%0A%09%09%09%09%09%09changedStyles%5Bp%5D%20%3D%20true%3B%0A%09%09%09%09for%28var%20p%20in%20styles%29%0A%09%09%09%09%09prevStyles%5Bp%5D%20%3D%20styles%5Bp%5D%3B%0A%09%09%09%09if%28_showMargins%20%3E%3D%203%20%7C%7C%20this._shiftKey%29%20%7B%0A%09%09%09%09%09df.appendChild%28this.getItem%28%22margin%22%2C%20styles.margin%2C%20this.colon%2C%20%7B%0A%09%09%09%09%09%09isChanged%3A%20%22margin%22%20in%20changedStyles%0A%09%09%09%09%09%7D%29%29%3B%0A%09%09%09%09%09df.appendChild%28this.getItem%28%22border%22%2C%20styles.border%2C%20this.colon%2C%20%7B%0A%09%09%09%09%09%09isChanged%3A%20%22border%22%20in%20changedStyles%0A%09%09%09%09%09%7D%29%29%3B%0A%09%09%09%09%09df.appendChild%28this.getItem%28%22padding%22%2C%20styles.padding%2C%20this.colon%2C%20%7B%0A%09%09%09%09%09%09isChanged%3A%20%22padding%22%20in%20changedStyles%0A%09%09%09%09%09%7D%29%29%3B%0A%09%09%09%09%7D%0A%09%09%09%7D%0A%0A%09%09%09if%28%21node.attributes%29%20%7B%0A%09%09%09%09df.appendChild%28this.getItem%28%22nodeValue%22%2C%20node.nodeValue%2C%20this.colon%29%29%3B%0A%09%09%09%09flush%28%29%3B%0A%09%09%09%09return%3B%0A%09%09%09%7D%0A%0A%09%09%09var%20topAttrs%20%3D%20%5B%22id%22%2C%20%22class%22%5D.reverse%28%29%3B%0A%09%09%09if%28this._node%29%20%7B%0A%09%09%09%09var%20addedAttrs%20%20%20%3D%20this.addedAttrs%3B%0A%09%09%09%09var%20removedAttrs%20%3D%20this.removedAttrs%3B%0A%09%09%09%09var%20changedAttrs%20%3D%20this.changedAttrs%3B%0A%09%09%09%7D%0A%09%09%09else%20%7B%0A%09%09%09%09addedAttrs%20%3D%20removedAttrs%20%3D%20changedAttrs%20%3D%20%7B%20__proto__%3A%20null%20%7D%3B%0A%09%09%09%7D%0A%0A%09%09%09var%20attrs%20%3D%20Array.prototype.slice.call%28node.attributes%29%3B%0A%09%09%09for%28var%20name%20in%20removedAttrs%29%0A%09%09%09%09attrs.push%28removedAttrs%5Bname%5D%29%3B%0A%0A%09%09%09attrs.sort%28function%28a%2C%20b%29%20%7B%0A%09%09%09%09a%20%3D%20a.name%3B%0A%09%09%09%09b%20%3D%20b.name%3B%0A%09%09%09%09var%20ai%20%3D%20topAttrs.indexOf%28a%29%3B%0A%09%09%09%09var%20bi%20%3D%20topAttrs.indexOf%28b%29%3B%0A%09%09%09%09if%28ai%20%21%3D%20-1%20%7C%7C%20bi%20%21%3D%20-1%29%0A%09%09%09%09%09return%20bi%20-%20ai%3B%0A%09%09%09%09return%20a%20%3E%20b%3B%0A%09%09%09%7D%29.forEach%28function%28attr%29%20%7B%0A%09%09%09%09var%20name%20%3D%20attr.name%3B%0A%09%09%09%09var%20val%20%3D%20attr.value%3B%0A%09%09%09%09var%20ns%20%3D%20attr.namespaceURI%3B%0A%09%09%09%09if%28%21_highlightUsingFlasher%29%20%7B%0A%09%09%09%09%09if%28name%20%3D%3D%20this.context.hlAttr%20%26%26%20ns%20%3D%3D%20this.context.hlAttrNS%29%0A%09%09%09%09%09%09return%3B%0A%09%09%09%09%09if%28this.noStyles%20%26%26%20name%20%3D%3D%20%22style%22%29%20%7B%0A%09%09%09%09%09%09val%20%3D%20this._oldStyle%3B%0A%09%09%09%09%09%09if%28val%20%3D%3D%3D%20false%29%0A%09%09%09%09%09%09%09return%3B%0A%09%09%09%09%09%7D%0A%09%09%09%09%7D%0A%09%09%09%09if%28_showNamespaceURI%20%26%26%20ns%20%26%26%20ns%20%21%3D%20nodeNS%20%26%26%20name.indexOf%28%22%3A%22%29%20%3D%3D%20-1%29%0A%09%09%09%09%09name%20+%3D%20%22%20%5B%22%20+%20this.getNS%28ns%29%20+%20%22%5D%22%3B%0A%09%09%09%09df.appendChild%28this.getItem%28name%2C%20val%2C%20this.separator%2C%20%7B%0A%09%09%09%09%09isAdded%3A%20%20%20name%20in%20addedAttrs%20%26%26%20addedAttrs%5Bname%5D%20%3D%3D%20ns%2C%0A%09%09%09%09%09isChanged%3A%20name%20in%20changedAttrs%20%26%26%20changedAttrs%5Bname%5D%20%3D%3D%20ns%2C%0A%09%09%09%09%09isRemoved%3A%20name%20in%20removedAttrs%20%26%26%20removedAttrs%5Bname%5D.namespaceURI%20%3D%3D%20ns%0A%09%09%09%09%7D%29%29%3B%0A%09%09%09%7D%2C%20this%29%3B%0A%09%09%09flush%28%29%3B%0A%09%09%7D%2C%0A%09%09getRect%3A%20function%28node%29%20%7B%0A%09%09%09return%20this.getScreenRect%28node%2C%201%29%3B%0A%09%09%7D%2C%0A%09%09getScreenRect%3A%20function%28node%2C%20scale%29%20%7B%0A%09%09%09var%20win%20%3D%20node.ownerDocument.defaultView%3B%0A%09%09%09if%28%21scale%29%20try%20%7B%0A%09%09%09%09var%20dwu%20%3D%20%22windowUtils%22%20in%20win%20%26%26%20win.windowUtils%20instanceof%20Components.interfaces.nsIDOMWindowUtils%0A%09%09%09%09%09%3F%20win.windowUtils%20//%20Firefox%2063+%0A%09%09%09%09%09%3A%20win.QueryInterface%28Components.interfaces.nsIInterfaceRequestor%29%0A%09%09%09%09%09%09.getInterface%28Components.interfaces.nsIDOMWindowUtils%29%3B%0A%09%09%09%09scale%20%3D%20dwu.screenPixelsPerCSSPixel%20%7C%7C%201%3B%0A%09%09%09%7D%0A%09%09%09catch%28e%29%20%7B%0A%09%09%09%09Components.utils.reportError%28e%29%3B%0A%09%09%09%09scale%20%3D%201%3B%0A%09%09%09%7D%0A%0A%09%09%09if%28%21%28node%20instanceof%20Element%29%29%20try%20%7B%0A%09%09%09%09var%20rng%20%3D%20node.ownerDocument.createRange%28%29%3B%0A%09%09%09%09rng.selectNodeContents%28node%29%3B%0A%09%09%09%09node%20%3D%20rng%3B%0A%09%09%09%7D%0A%09%09%09catch%28e%29%20%7B%0A%09%09%09%09Components.utils.reportError%28e%29%3B%0A%09%09%09%7D%0A%0A%09%09%09if%28%22getBoundingClientRect%22%20in%20node%29%20%7B%0A%09%09%09%09var%20rect%20%3D%20node.getBoundingClientRect%28%29%3B%0A%09%09%09%09return%20%7B%0A%09%09%09%09%09x%3A%20rect.left*scale%2C%0A%09%09%09%09%09y%3A%20rect.top*scale%2C%0A%09%09%09%09%09screenX%3A%20%28rect.left%20+%20win.mozInnerScreenX%29*scale%2C%0A%09%09%09%09%09screenY%3A%20%28rect.top%20+%20win.mozInnerScreenY%29*scale%2C%0A%09%09%09%09%09width%3A%20%28rect.right%20-%20rect.left%29*scale%2C%0A%09%09%09%09%09height%3A%20%28rect.bottom%20-%20rect.top%29*scale%0A%09%09%09%09%7D%3B%0A%09%09%09%7D%0A%0A%09%09%09try%20%7B%0A%09%09%09%09var%20bo%20%3D%20node%20instanceof%20XULElement%20%26%26%20node.boxObject%0A%09%09%09%09%09%7C%7C%20node.ownerDocument%20%26%26%20%22getBoxObjectFor%22%20in%20node.ownerDocument%0A%09%09%09%09%09%09%26%26%20node.ownerDocument.getBoxObjectFor%28node%29%3B%0A%09%09%09%7D%0A%09%09%09catch%28e%29%20%7B%0A%09%09%09%7D%0A%09%09%09if%28bo%29%20%7B%0A%09%09%09%09if%28%21%28%22width%22%20in%20bo%29%29%20%7B%0A%09%09%09%09%09bo.width%20%3D%20bo.right%20-%20bo.left%3B%0A%09%09%09%09%09bo.height%20%3D%20bo.bottom%20-%20bo.top%3B%0A%09%09%09%09%7D%0A%09%09%09%09return%20%7B%0A%09%09%09%09%09x%3A%20bo.x*scale%2C%0A%09%09%09%09%09y%3A%20bo.y*scale%2C%0A%09%09%09%09%09screenX%3A%20bo.screenX*scale%2C%0A%09%09%09%09%09screenY%3A%20bo.screenY*scale%2C%0A%09%09%09%09%09width%3A%20bo.width*scale%2C%0A%09%09%09%09%09height%3A%20bo.height*scale%0A%09%09%09%09%7D%3B%0A%09%09%09%7D%0A%09%09%09return%20null%3B%0A%09%09%7D%2C%0A%09%09isNodeVisible%3A%20function%28node%2C%20rect%29%20%7B%0A%09%09%09if%28%21rect%29%0A%09%09%09%09rect%20%3D%20this.getRect%28node%29%3B%0A%09%09%09if%28rect.width%20%3D%3D%200%20%26%26%20rect.height%20%3D%3D%200%29%0A%09%09%09%09return%20false%3B%0A%09%09%09for%28var%20p%20%3D%20node%3B%20p%3B%20p%20%3D%20p.parentNode%29%20%7B%0A%09%09%09%09if%28%0A%09%09%09%09%09p%20instanceof%20XULElement%0A%09%09%09%09%09%26%26%20%28p.localName%20%3D%3D%20%22menupopup%22%20%7C%7C%20p.localName%20%3D%3D%20%22popup%22%29%0A%09%09%09%09%09%26%26%20%22state%22%20in%20p%0A%09%09%09%09%09%26%26%20p.state%20%3D%3D%20%22closed%22%0A%09%09%09%09%29%0A%09%09%09%09%09return%20false%3B%0A%09%09%09%7D%0A%09%09%09return%20true%3B%0A%09%09%7D%2C%0A%09%09getNS%3A%20function%28ns%29%20%7B%0A%09%09%09if%28_showNamespaceURI%20%3D%3D%202%29%20switch%28ns%29%20%7B%0A%09%09%09%09case%20%22http%3A//www.mozilla.org/keymaster/gatekeeper/there.is.only.xul%22%3A%20return%20%22XUL%22%3B%0A%09%09%09%09case%20%22http%3A//www.w3.org/1999/xhtml%22%3A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20return%20%22XHTML%22%3B%0A%09%09%09%09case%20%22http%3A//www.mozilla.org/xbl%22%3A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20return%20%22XBL%22%3B%0A%09%09%09%09case%20%22http%3A//www.w3.org/2000/svg%22%3A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20return%20%22SVG%22%3B%0A%09%09%09%09case%20%22http%3A//www.w3.org/1998/Math/MathML%22%3A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20return%20%22MathML%22%3B%0A%09%09%09%09case%20%22http%3A//www.w3.org/1999/xlink%22%3A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20return%20%22XLink%22%3B%0A%09%09%09%09case%20%22http%3A//www.w3.org/2000/xmlns/%22%3A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20return%20%22XMLNS%22%3B%0A%09%09%09%09case%20%22http%3A//www.w3.org/XML/1998/namespace%22%3A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20return%20%22XML%22%3B%0A%09%09%09%09case%20%22http%3A//www.w3.org/1999/XSL/Transform%22%3A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20return%20%22XSLT%22%3B%0A%09%09%09%09case%20%22http%3A//www.w3.org/1999/02/22-rdf-syntax-ns%22%3A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20return%20%22RDF%22%3B%0A%09%09%09%09case%20%22http%3A//www.w3.org/2001/xml-events%22%3A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20return%20%22XML%20Events%22%3B%0A%09%09%09%7D%0A%09%09%09return%20%22%22%20+%20ns%3B%20//%20Can%20be%20null%20for%20%23text%0A%09%09%7D%2C%0A%09%09stop%3A%20function%28%29%20%7B%0A%09%09%09this.context.stop%28%29%3B%0A%09%09%7D%2C%0A%09%09canInspect%3A%20function%28e%29%20%7B%0A%09%09%09var%20noMdf%20%3D%20/*%21e.shiftKey%20%26%26%20*/%21e.altKey%20%26%26%20%21e.metaKey%3B%0A%09%09%09if%28%21_forbidTooltips%20%26%26%20e.shiftKey%29%0A%09%09%09%09return%20false%3B%0A%09%09%09return%20e.button%20%3D%3D%201%20%26%26%20noMdf%20%26%26%20%21e.ctrlKey%20//%20Middle-click%0A%09%09%09%20%20%20%20%7C%7C%20e.button%20%3D%3D%200%20%26%26%20noMdf%20%26%26%20%20e.ctrlKey%3B%20//%20Ctrl%20+%20left-click%0A%09%09%7D%2C%0A%09%09get%20appInfo%28%29%20%7B%0A%09%09%09delete%20this.appInfo%3B%0A%09%09%09return%20this.appInfo%20%3D%20Components.classes%5B%[email protected]/xre/app-info%3B1%22%5D%0A%09%09%09%09.getService%28Components.interfaces.nsIXULAppInfo%29%3B%0A%09%09%7D%2C%0A%09%09get%20fxVersion%28%29%20%7B%0A%09%09%09delete%20this.fxVersion%3B%0A%09%09%09var%20pv%20%3D%20this.appInfo.platformVersion%3B%0A%09%09%09var%20v%20%3D%20parseFloat%28pv%29%3B%0A%09%09%09if%28this.appInfo.name%20%3D%3D%20%22Pale%20Moon%22%20%7C%7C%20this.appInfo.name%20%3D%3D%20%22Basilisk%22%29%0A%09%09%09%09return%20this.fxVersion%20%3D%20v%20%3E%3D%204.1%20%3F%2056%20%3A%2028%3B%0A%09%09%09//%20https%3A//developer.mozilla.org/en-US/docs/Mozilla/Gecko/Versions%0A%09%09%09if%28v%20%3C%205%29%20%7B%0A%09%09%09%09var%20vc%20%3D%20Components.classes%5B%[email protected]/xpcom/version-comparator%3B1%22%5D%0A%09%09%09%09%09.getService%28Components.interfaces.nsIVersionComparator%29%3B%0A%09%09%09%09if%28vc.compare%28pv%2C%20%222.0a1pre%22%29%20%3E%3D%200%29%0A%09%09%09%09%09v%20%3D%204.0%3B%0A%09%09%09%09else%20if%28vc.compare%28pv%2C%20%221.9.2a1pre%22%29%20%3E%3D%200%29%0A%09%09%09%09%09v%20%3D%203.6%3B%0A%09%09%09%09else%20if%28vc.compare%28pv%2C%20%221.9.1a1pre%22%29%20%3E%3D%200%29%0A%09%09%09%09%09v%20%3D%203.5%3B%0A%09%09%09%09else%20if%28vc.compare%28pv%2C%20%221.9a1pre%22%29%20%3E%3D%200%29%0A%09%09%09%09%09v%20%3D%203.0%3B%0A%09%09%09%09else%20if%28vc.compare%28pv%2C%20%221.8.1a1pre%22%29%20%3E%3D%200%29%0A%09%09%09%09%09v%20%3D%202.0%3B%0A%09%09%09%09else%20//if%28vc.compare%28pv%2C%20%221.8a1pre%22%29%20%3E%3D%200%29%0A%09%09%09%09%09v%20%3D%201.5%3B%0A%09%09%09%7D%0A%09%09%09return%20this.fxVersion%20%3D%20v%3B%0A%09%09%7D%2C%0A%09%09get%20noStyles%28%29%20%7B%0A%09%09%09delete%20this.noStyles%3B%0A%09%09%09//return%20this.noStyles%20%3D%20this.fxVersion%20%3C%203%3B%0A%09%09%09return%20this.noStyles%20%3D%20Components.ID%28%22%7B41d979dc-ea03-4235-86ff-1e3c090c5630%7D%22%29%0A%09%09%09%09.equals%28Components.interfaces.nsIStyleSheetService%29%3B%0A%09%09%7D%2C%0A%09%09stopEvent%3A%20function%28e%29%20%7B%0A%09%09%09try%20%7B%0A%09%09%09%09e.preventDefault%28%29%3B%0A%09%09%09%09e.stopPropagation%28%29%3B%0A%09%09%09%09%22stopImmediatePropagation%22%20in%20e%20%26%26%20e.stopImmediatePropagation%28%29%3B%0A%09%09%09%7D%0A%09%09%09catch%28e%29%20%7B%20//%20e10s%3A%20TypeError%3A%20%27preventDefault%27%20called%20on%20an%20object%20that%20does%20not%20implement%20interface%20Event.%0A%09%09%09%09if%28_debug%20%7C%7C%20%28%22%22%20+%20e%29.indexOf%28%22does%20not%20implement%20interface%22%29%20%3D%3D%20-1%29%0A%09%09%09%09%09Components.utils.reportError%28e%29%3B%0A%09%09%09%7D%0A%09%09%09//_log%28%22stopEvent%3A%20%22%20+%20e.type%29%3B%0A%09%09%7D%2C%0A%09%09_timers%3A%20%7B%20__proto__%3A%20null%20%7D%2C%0A%09%09_timersCounter%3A%200%2C%0A%09%09get%20Timer%28%29%20%7B%0A%09%09%09delete%20this.Timer%3B%0A%09%09%09return%20this.Timer%20%3D%20Components.Constructor%28%[email protected]/timer%3B1%22%2C%20%22nsITimer%22%29%3B%0A%09%09%7D%2C%0A%09%09timer%3A%20function%28callback%2C%20context%2C%20delay%2C%20args%29%20%7B%0A%09%09%09var%20id%20%3D%20++this._timersCounter%3B%0A%09%09%09var%20_timers%20%3D%20this._timers%3B%0A%09%09%09var%20timer%20%3D%20new%20this.Timer%28%29%3B%0A%09%09%09timer.init%28%7B%0A%09%09%09%09observe%3A%20function%28subject%2C%20topic%2C%20data%29%20%7B%0A%09%09%09%09%09delete%20_timers%5Bid%5D%3B%0A%09%09%09%09%09callback.apply%28context%2C%20args%29%3B%0A%09%09%09%09%7D%0A%09%09%09%7D%2C%20delay%20%7C%7C%200%2C%20timer.TYPE_ONE_SHOT%29%3B%0A%09%09%09return%20id%3B%0A%09%09%7D%2C%0A%09%09cancelTimer%3A%20function%28id%29%20%7B%0A%09%09%09var%20_timers%20%3D%20this._timers%3B%0A%09%09%09if%28id%20in%20_timers%29%20%7B%0A%09%09%09%09_timers%5Bid%5D.cancel%28%29%3B%0A%09%09%09%09delete%20_timers%5Bid%5D%3B%0A%09%09%09%7D%0A%09%09%7D%2C%0A%09%09destroyTimers%3A%20function%28%29%20%7B%0A%09%09%09var%20_timers%20%3D%20this._timers%3B%0A%09%09%09for%28var%20id%20in%20_timers%29%0A%09%09%09%09_timers%5Bid%5D.cancel%28%29%3B%0A%09%09%09this._timers%20%3D%20%7B%20__proto__%3A%20null%20%7D%3B%0A%09%09%09this._timersCounter%20%3D%200%3B%0A%09%09%7D%2C%0A%09%09get%20flasher%28%29%20%7B%0A%09%09%09try%20%7B%20//%20Will%20be%20removed%20in%20Gecko%2033+%2C%20see%20https%3A//bugzilla.mozilla.org/show_bug.cgi%3Fid%3D1018324%0A%09%09%09%09var%20flasher%20%3D%20Components.classes%5B%[email protected]/inspector/flasher%3B1%22%5D%0A%09%09%09%09%09.getService%28Components.interfaces.inIFlasher%29%3B%0A%09%09%09%09flasher.color%20%3D%20_borderColor%3B%0A%09%09%09%09flasher.thickness%20%3D%20_borderWidth%3B%0A%09%09%09%09flasher.invert%20%3D%20false%3B%0A%09%09%09%7D%0A%09%09%09catch%28e%29%20%7B%0A%09%09%09%09_log%28%22inIFlasher%20not%20available%22%29%3B%0A%09%09%09%09Components.utils.reportError%28e%29%3B%0A%09%09%09%7D%0A%09%09%09delete%20this.flasher%3B%0A%09%09%09return%20this.flasher%20%3D%20flasher%3B%0A%09%09%7D%2C%0A%09%09hl%3A%20function%28node%29%20%7B%0A%09%09%09if%28%21_highlight%29%0A%09%09%09%09return%3B%0A%09%09%09this.unhl%28%29%3B%20//%20Only%20one%20highlighted%20node%0A%09%09%09if%28%21%28%22setAttributeNS%22%20in%20node%29%29%0A%09%09%09%09return%3B%0A%09%09%09this._hl%20%3D%20node%3B%0A%0A%09%09%09if%28_highlightUsingFlasher%29%20%7B%0A%09%09%09%09this.flasher.drawElementOutline%28node%29%3B%0A%09%09%09%09this._hlInterval%20%3D%20node.ownerDocument.defaultView.setInterval%28function%28_this%29%20%7B%0A%09%09%09%09%09_this.flasher.drawElementOutline%28node%29%3B%0A%09%09%09%09%7D%2C%2010%2C%20this%29%3B%0A%09%09%09%09return%3B%0A%09%09%09%7D%0A%0A%09%09%09if%28node.hasAttributeNS%28this.context.hlAttrNS%2C%20this.context.hlAttr%29%29%0A%09%09%09%09return%3B%0A%09%09%09if%28this.noStyles%29%20%7B%0A%09%09%09%09this._oldStyle%20%3D%20node.hasAttribute%28%22style%22%29%20%26%26%20node.getAttribute%28%22style%22%29%3B%0A%09%09%09%09node.style.outline%20%3D%20_borderWidth%20+%20%22px%20%22%20+%20_borderStyle%20+%20%22%20%22%20+%20_borderColor%3B%0A%09%09%09%09node.style.outlineOffset%20%3D%20%22-%22%20+%20_borderWidth%20+%20%22px%22%3B%0A%09%09%09%7D%0A%09%09%09node.setAttributeNS%28this.context.hlAttrNS%2C%20this.context.hlAttr%2C%20%22true%22%29%3B%0A%09%09%7D%2C%0A%09%09unhl%3A%20function%28%29%20%7B%0A%09%09%09var%20node%20%3D%20this._hl%3B%0A%09%09%09if%28%21node%29%0A%09%09%09%09return%3B%0A%09%09%09this._hl%20%3D%20null%3B%0A%09%09%09try%20%7B%0A%09%09%09%09if%28%21%28%22removeAttributeNS%22%20in%20node%29%29%0A%09%09%09%09%09return%3B%0A%09%09%09%7D%0A%09%09%09catch%28e%29%20%7B%20//%20TypeError%3A%20can%27t%20access%20dead%20object%0A%09%09%09%09return%3B%0A%09%09%09%7D%0A%0A%09%09%09if%28_highlightUsingFlasher%29%20%7B%0A%09%09%09%09var%20win%20%3D%20node.ownerDocument.defaultView%3B%0A%09%09%09%09win.clearInterval%28this._hlInterval%29%3B%0A%09%09%09%09this.flasher.repaintElement%28node%29%3B%0A%09%09%09%09//this.flasher.repaintElement%28node.ownerDocument.documentElement%29%3B%0A%09%09%09%09this.flasher.repaintElement%28this.getTopWindow%28win%29.document.documentElement%29%3B%0A%09%09%09%09return%3B%0A%09%09%09%7D%0A%0A%09%09%09if%28this.noStyles%29%20%7B%0A%09%09%09%09if%28this._oldStyle%20%3D%3D%3D%20false%29%0A%09%09%09%09%09node.removeAttribute%28%22style%22%29%3B%0A%09%09%09%09else%0A%09%09%09%09%09node.setAttribute%28%22style%22%2C%20this._oldStyle%29%3B%0A%09%09%09%7D%0A%09%09%09node.removeAttributeNS%28this.context.hlAttrNS%2C%20this.context.hlAttr%29%3B%0A%09%09%7D%2C%0A%0A%09%09get%20mutationObserver%28%29%20%7B%0A%09%09%09delete%20this.mutationObserver%3B%0A%09%09%09return%20this.mutationObserver%20%3D%20%22MutationObserver%22%20in%20this.window%20//%20Firefox%2014+%0A%09%09%09%09%26%26%20new%20this.window.MutationObserver%28this.handleMutations.bind%28this%29%29%3B%0A%09%09%7D%2C%0A%09%09watchAttrs%3A%20function%28node%29%20%7B%0A%09%09%09this.unwatchAttrs%28%29%3B%20//%20Only%20one%20watched%20node%0A%09%09%09this._node%20%3D%20node%3B%0A%0A%09%09%09this.addedAttrs%20%20%20%3D%20%7B%20__proto__%3A%20null%20%7D%3B%0A%09%09%09this.removedAttrs%20%3D%20%7B%20__proto__%3A%20null%20%7D%3B%0A%09%09%09this.changedAttrs%20%3D%20%7B%20__proto__%3A%20null%20%7D%3B%0A%0A%09%09%09var%20mo%20%3D%20this.mutationObserver%3B%0A%09%09%09if%28mo%29%20%7B%0A%09%09%09%09//%20http%3A//dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html%23mutation-observers%0A%09%09%09%09try%20%7B%0A%09%09%09%09%09mo.observe%28node%2C%20%7B%0A%09%09%09%09%09%09attributes%3A%20true%2C%0A%09%09%09%09%09%09attributeOldValue%3A%20true%0A%09%09%09%09%09%7D%29%3B%0A%09%09%09%09%7D%0A%09%09%09%09catch%28e%29%20%7B%20//%20e10s%3A%20Argument%201%20of%20MutationObserver.observe%20does%20not%20implement%20interface%20Node.%0A%09%09%09%09%09if%28_debug%20%7C%7C%20%28%22%22%20+%20e%29.indexOf%28%22does%20not%20implement%20interface%22%29%20%3D%3D%20-1%29%0A%09%09%09%09%09%09Components.utils.reportError%28e%29%3B%0A%09%09%09%09%7D%0A%09%09%09%09return%3B%0A%09%09%09%7D%0A%09%09%09//%20Legacy%20version%0A%09%09%09var%20aw%20%3D%20this%3B%0A%09%09%09if%28this.fxVersion%20%3D%3D%202%29%20%7B%20//%20Hack%20for%20Firefox%202.0%0A%09%09%09%09aw%20%3D%20this._attrsWatcher%20%3D%20%7B%0A%09%09%09%09%09parent%3A%20this%2C%0A%09%09%09%09%09handleEvent%3A%20function%28e%29%20%7B%0A%09%09%09%09%09%09this.parent.DOMAttrModifiedHandler%28e%29%3B%0A%09%09%09%09%09%7D%0A%09%09%09%09%7D%3B%0A%09%09%09%7D%0A%09%09%09ael%28%22DOMAttrModified%22%2C%20aw%2C%20true%2C%20node%29%3B%0A%09%09%7D%2C%0A%09%09unwatchAttrs%3A%20function%28%29%20%7B%0A%09%09%09if%28%21this._node%29%0A%09%09%09%09return%3B%0A%09%09%09var%20mo%20%3D%20this.mutationObserver%3B%0A%09%09%09if%28mo%29%0A%09%09%09%09mo.disconnect%28%29%3B%0A%09%09%09else%0A%09%09%09%09rel%28%22DOMAttrModified%22%2C%20this._attrsWatcher%20%7C%7C%20this%2C%20true%2C%20this._node%29%3B%0A%09%09%09this._node%20%3D%20this._attrsWatcher%20%3D%20null%3B%0A%09%09%09this.addedAttrs%20%3D%20this.removedAttrs%20%3D%20this.changedAttrs%20%3D%20null%3B%0A%09%09%7D%2C%0A%09%09handleMutations%3A%20function%28mutations%29%20%7B%0A%09%09%09mutations.forEach%28function%28mutation%29%20%7B%0A%09%09%09%09var%20node%20%3D%20mutation.target%3B%0A%09%09%09%09if%28mutation.type%20%21%3D%20%22attributes%22%20%7C%7C%20node%20%21%3D%20this._node%29%0A%09%09%09%09%09return%3B%0A%09%09%09%09var%20attrName%20%3D%20mutation.attributeName%3B%0A%09%09%09%09var%20attrNS%20%3D%20mutation.attributeNamespace%3B%0A%09%09%09%09var%20oldVal%20%3D%20mutation.oldValue%3B%0A%09%09%09%09var%20isAdded%20%3D%20oldVal%20%3D%3D%3D%20null%3B%0A%09%09%09%09var%20isRemoved%20%3D%20%21node.hasAttributeNS%28attrNS%2C%20attrName%29%3B%0A%09%09%09%09this.handleMutation%28attrName%2C%20attrNS%2C%20isAdded%2C%20isRemoved%2C%20oldVal%29%3B%0A%09%09%09%7D%2C%20this%29%3B%0A%09%09%09this.setDataProxy%28this._node%29%3B%0A%09%09%7D%2C%0A%09%09DOMAttrModifiedHandler%3A%20function%28e%29%20%7B%0A%09%09%09if%28e.originalTarget%20%21%3D%20this._node%29%20//%20Ignore%20mutations%20in%20child%20nodes%0A%09%09%09%09return%3B%0A%09%09%09this.handleMutation%28%0A%09%09%09%09e.attrName%2C%0A%09%09%09%09e.relatedNode%20%26%26%20e.relatedNode.namespaceURI%20%7C%7C%20null%2C%0A%09%09%09%09e.attrChange%20%3D%3D%20e.ADDITION%2C%0A%09%09%09%09e.attrChange%20%3D%3D%20e.REMOVAL%2C%0A%09%09%09%09e.prevValue%0A%09%09%09%29%3B%0A%09%09%09this.setDataProxy%28this._node%29%3B%0A%09%09%7D%2C%0A%09%09handleMutation%3A%20function%28attrName%2C%20attrNS%2C%20isAdded%2C%20isRemoved%2C%20oldValue%29%20%7B%0A%09%09%09if%28isAdded%29%20%7B%0A%09%09%09%09this.addedAttrs%5BattrName%5D%20%3D%20attrNS%3B%0A%09%09%09%09delete%20this.removedAttrs%5BattrName%5D%3B%0A%09%09%09%09delete%20this.changedAttrs%5BattrName%5D%3B%0A%09%09%09%7D%0A%09%09%09else%20if%28isRemoved%29%20%7B%0A%09%09%09%09this.removedAttrs%5BattrName%5D%20%3D%20%7B%0A%09%09%09%09%09name%3A%20attrName%2C%0A%09%09%09%09%09value%3A%20oldValue%2C%0A%09%09%09%09%09namespaceURI%3A%20attrNS%0A%09%09%09%09%7D%3B%0A%09%09%09%09delete%20this.addedAttrs%5BattrName%5D%3B%0A%09%09%09%09delete%20this.changedAttrs%5BattrName%5D%3B%0A%09%09%09%7D%0A%09%09%09else%20%7B%0A%09%09%09%09this.changedAttrs%5BattrName%5D%20%3D%20attrNS%3B%0A%09%09%09%09delete%20this.removedAttrs%5BattrName%5D%3B%20//%20%3F%0A%09%09%09%7D%0A%09%09%7D%2C%0A%0A%09%09setClipboardData%3A%20function%28dataObj%2C%20sourceWindow%2C%20clipId%29%20%7B%0A%09%09%09var%20ta%20%3D%20Components.classes%5B%[email protected]/widget/transferable%3B1%22%5D%0A%09%09%09%09.createInstance%28Components.interfaces.nsITransferable%29%3B%0A%09%09%09if%28sourceWindow%20%26%26%20%22init%22%20in%20ta%29%20%7B%0A%09%09%09%09//%20The%20clipboard%20will%20be%20cleared%20when%20private%20browsing%20mode%20ends%2C%0A%09%09%09%09//%20removed%20in%20Firefox%2041+%20https%3A//bugzilla.mozilla.org/show_bug.cgi%3Fid%3D1166840%0A%09%09%09%09//%20QueryInterface%20removed%20in%20Firefox%2070+%20https%3A//bugzilla.mozilla.org/show_bug.cgi%3Fid%3D1568585%0A%09%09%09%09var%20privacyContext%20%3D%20sourceWindow.QueryInterface%20%26%26%20sourceWindow%0A%09%09%09%09%09.QueryInterface%28Components.interfaces.nsIInterfaceRequestor%29%0A%09%09%09%09%09.getInterface%28Components.interfaces.nsIWebNavigation%29%0A%09%09%09%09%09.QueryInterface%28Components.interfaces.nsILoadContext%29%3B%0A%09%09%09%09ta.init%28privacyContext%20%7C%7C%20null%29%3B%0A%09%09%09%7D%0A%09%09%09for%28var%20flavor%20in%20dataObj%29%20if%28dataObj.hasOwnProperty%28flavor%29%29%20%7B%0A%09%09%09%09var%20value%20%3D%20dataObj%5Bflavor%5D%3B%0A%09%09%09%09var%20str%20%3D%20Components.classes%5B%[email protected]/supports-string%3B1%22%5D%0A%09%09%09%09%09.createInstance%28Components.interfaces.nsISupportsString%29%3B%0A%09%09%09%09str.data%20%3D%20value%3B%0A%09%09%09%09ta.addDataFlavor%28flavor%29%3B%0A%09%09%09%09ta.setTransferData%28flavor%2C%20str%2C%20value.length%20*%202%29%3B%0A%09%09%09%7D%0A%09%09%09var%20cb%20%3D%20Components.classes%5B%[email protected]/widget/clipboard%3B1%22%5D%0A%09%09%09%09.getService%28Components.interfaces.nsIClipboard%29%3B%0A%09%09%09cb.setData%28ta%2C%20null%2C%20clipId%20%3D%3D%3D%20undefined%20%3F%20cb.kGlobalClipboard%20%3A%20clipId%29%3B%0A%09%09%7D%2C%0A%09%09_noMouseover%3A%20false%2C%0A%09%09_noMouseoverTimer%3A%20-1%2C%0A%09%09mouseoverHandler%3A%20function%28e%29%20%7B%0A%09%09%09if%28this._noMouseover%29%0A%09%09%09%09return%3B%0A%09%09%09var%20node%20%3D%20e.originalTarget%3B%0A%09%09%09if%28node%20%3D%3D%20this.context.tt%29%0A%09%09%09%09return%3B%0A%09%09%09this._nodes%20%3D%20%5Bnode%5D%3B%0A%09%09%09this.handleNodeFromEvent%28node%2C%20e%29%3B%0A%09%09%7D%2C%0A%09%09handleNodeFromEvent%3A%20function%28node%2C%20e%29%20%7B%0A%09%09%09this.hl%28node%29%3B%0A%09%09%09if%28node%20%21%3D%20this._node%29%20%7B%0A%09%09%09%09this.prevStyles%20%20%20%20%3D%20%7B%20__proto__%3A%20null%20%7D%3B%0A%09%09%09%09this.changedStyles%20%3D%20%7B%20__proto__%3A%20null%20%7D%3B%0A%09%09%09%7D%0A%09%09%09this.setData%28node%29%3B%0A%09%09%09this.watchAttrs%28node%29%3B%0A%09%09%09this.mousemoveHandler%28e%29%3B%0A%09%09%7D%2C%0A%09%09handleNode%3A%20function%28node%29%20%7B%0A%09%09%09//%20Tooltip%20with%20big%20height%20-%3E%20wrongly%20under%20cursor%20-%3E%20reposition%20-%3E%20mouseover%0A%09%09%09//%20And%20setTimeout%28%29%20in%20parent%20window%20fail%20for%20modal%20child%20window%0A%09%09%09if%28this._noMouseover%29%0A%09%09%09%09this.cancelTimer%28this._noMouseoverTimer%29%3B%0A%09%09%09this._noMouseover%20%3D%20true%3B%0A%0A%09%09%09this.handleNodeFromEvent%28node%29%3B%0A%0A%09%09%09this._noMouseoverTimer%20%3D%20this.timer%28function%28%29%20%7B%0A%09%09%09%09this._noMouseover%20%3D%20false%3B%0A%09%09%09%09this._noMouseoverTimer%20%3D%20null%3B%0A%09%09%09%7D%2C%20this%2C%20200%29%3B%0A%09%09%7D%2C%0A%09%09mousemoveHandler%3A%20function%28e%29%20%7B%0A%09%09%09var%20tt%20%3D%20this.context.tt%3B%0A%0A%09%09%09if%28%21this._hasData%29%20%7B%0A%09%09%09%09this.mouseoverHandler%28e%29%3B%0A%09%09%09%09return%3B%0A%09%09%09%7D%0A%0A%09%09%09var%20x%2C%20y%3B%0A%09%09%09if%28e%29%20%7B%0A%09%09%09%09x%20%3D%20e.screenX%3B%0A%09%09%09%09y%20%3D%20e.screenY%3B%0A%09%09%09%09if%28this.fxVersion%20%3E%3D%2099%29%20%7B%0A%09%09%09%09%09var%20k%20%3D%20e.view.devicePixelRatio/%28tt.ownerGlobal%20%26%26%20tt.ownerGlobal.devicePixelRatio%29%3B%0A%09%09%09%09%09if%28k%20%26%26%20isFinite%28k%29%29%20%7B%0A%09%09%09%09%09%09x%20*%3D%20k%3B%0A%09%09%09%09%09%09y%20*%3D%20k%3B%0A%09%09%09%09%09%7D%0A%09%09%09%09%7D%0A%09%09%09%09if%28%0A%09%09%09%09%09%22_lastScreenX%22%20in%20this%0A%09%09%09%09%09%26%26%20x%20%3D%3D%20this._lastScreenX%0A%09%09%09%09%09%26%26%20y%20%3D%3D%20this._lastScreenY%0A%09%09%09%09%29%0A%09%09%09%09%09return%3B%0A%0A%09%09%09%09this._lastScreenX%20%3D%20x%3B%0A%09%09%09%09this._lastScreenY%20%3D%20y%3B%0A%0A%09%09%09%09this._shiftKey%20%3D%20e.shiftKey%3B%0A%09%09%09%7D%0A%09%09%09else%20%7B%0A%09%09%09%09x%20%3D%20this._lastScreenX%20%7C%7C%200%3B%0A%09%09%09%09y%20%3D%20this._lastScreenY%20%7C%7C%200%3B%0A%09%09%09%7D%0A%0A%09%09%09var%20fxVersion%20%3D%20this.fxVersion%3B%0A%0A%09%09%09if%28fxVersion%20%3C%3D%202%29%20%7B%0A%09%09%09%09//%20Ugly%20workaround...%0A%09%09%09%09var%20text%20%3D%20Array.prototype.map.call%28tt.childNodes%2C%20function%28node%29%20%7B%0A%09%09%09%09%09return%20node.textContent%3B%0A%09%09%09%09%7D%29.join%28%22%5Cn%22%29%3B%0A%09%09%09%09tt.textContent%20%3D%20%22%22%3B%0A%09%09%09%09var%20d%20%3D%20this.e%28%22div%22%29%3B%0A%09%09%09%09d.style.whiteSpace%20%3D%20%22-moz-pre-wrap%22%3B%0A%09%09%09%09d.textContent%20%3D%20text%3B%0A%09%09%09%09tt.height%20%3D%20null%3B%0A%09%09%09%09tt.appendChild%28d%29%3B%0A%09%09%09%09tt.height%20%3D%20tt.boxObject.height%3B%0A%09%09%09%7D%0A%0A%09%09%09if%28%22openPopupAtScreen%22%20in%20tt%29%20//%20Firefox%203.0+%0A%09%09%09%09tt.openPopupAtScreen%28x%2C%20y%2C%20false%20/*isContextMenu*/%29%3B%0A%09%09%09else%0A%09%09%09%09tt.showPopup%28document.documentElement%2C%20x%2C%20y%2C%20%22tooltip%22%2C%20null%2C%20null%29%3B%0A%0A%09%09%09if%28fxVersion%20%3C%3D%202%29%0A%09%09%09%09return%3B%0A%09%09%09if%28fxVersion%20%3C%3D%203.5%29%20%7B%0A%09%09%09%09x%20%3D%20Math.min%28screen.width%20%20-%20tt.boxObject.width%2C%20%20x%29%3B%0A%09%09%09%09y%20%3D%20Math.min%28screen.height%20-%20tt.boxObject.height%2C%20y%29%3B%0A%09%09%09%09var%20debo%20%3D%20document.documentElement.boxObject%3B%0A%09%09%09%09x%20+%3D%20debo.screenX%3B%0A%09%09%09%09y%20+%3D%20debo.screenY%3B%0A%09%09%09%7D%0A%09%09%09if%28fxVersion%20%21%3D%203.6%29%0A%09%09%09%09y%20+%3D%2022%3B%0A%09%09%09tt.moveTo%28x%2C%20y%29%3B%0A%09%09%7D%2C%0A%09%09mouseoutHandler%3A%20function%28e%29%20%7B%0A%09%09%09if%28%21e.relatedTarget%29%0A%09%09%09%09this.context.tt.hidePopup%28%29%3B%0A%09%09%09this.unwatchAttrs%28%29%3B%0A%09%09%09this.unhl%28%29%3B%0A%09%09%7D%2C%0A%09%09draggestureHandler%3A%20function%28e%29%20%7B%0A%09%09%09this.makeTooltipTopmost%28%29%3B%0A%09%09%09_log%28e.type%20+%20%22%20%3D%3E%20make%20tooltip%20topmost%22%29%3B%0A%09%09%7D%2C%0A%09%09dragoverHandler%3A%20function%28e%29%20%7B%0A%09%09%09var%20node%20%3D%20e.originalTarget%20%7C%7C%20e.target%3B%0A%09%09%09if%28node%20%21%3D%20this._node%29%0A%09%09%09%09this.mouseoverHandler%28e%29%3B%0A%09%09%09else%0A%09%09%09%09this.mousemoveHandler%28e%29%3B%0A%09%09%7D%2C%0A%09%09dragexitHandler%3A%20function%28e%29%20%7B%0A%09%09%09if%28%21e.relatedTarget%20%26%26%20this._node%29%0A%09%09%09%09this.mouseoutHandler%28e%29%3B%0A%09%09%7D%2C%0A%09%09keydownHandler%3A%20function%28e%29%20%7B%0A%09%09%09this._shiftKey%20%3D%20e.shiftKey%3B%0A%09%09%09this.keypressHandler.apply%28this%2C%20arguments%29%3B%0A%09%09%7D%2C%0A%09%09keyupHandler%3A%20function%28e%29%20%7B%0A%09%09%09this._shiftKey%20%3D%20e.shiftKey%3B%0A%09%09%09this.keypressHandler.apply%28this%2C%20arguments%29%3B%0A%09%09%7D%2C%0A%09%09keypressHandler%3A%20function%28e%29%20%7B%0A%09%09%09//%20See%20https%3A//github.com/Infocatcher/Custom_Buttons/issues/12%0A%09%09%09//%20keydown%20%20%3D%3E%20stopEvent%28%29%20+%20hetkey%20action%20in%20Firefox%20%3E%3D%2025%0A%09%09%09//%20keypress%20%3D%3E%20stopEvent%28%29%20+%20hetkey%20action%20in%20Firefox%20%3C%2025%0A%09%09%09//%20keyup%20%20%20%20%3D%3E%20stopEvent%28%29%0A%09%09%09var%20onlyStop%20%3D%20this.fxVersion%20%3C%2025%0A%09%09%09%09%3F%20e.type%20%3D%3D%20%22keydown%22%20%7C%7C%20e.type%20%3D%3D%20%22keyup%22%0A%09%09%09%09%3A%20e.type%20%3D%3D%20%22keypress%22%20%7C%7C%20e.type%20%3D%3D%20%22keyup%22%3B%0A%09%09%09//_log%28e.type%20+%20%22%3A%20keyCode%3A%20%22%20+%20e.keyCode%20+%20%22%20charCode%3A%20%22%20+%20e.charCode%29%3B%0A%09%09%09if%28e.keyCode%20%3D%3D%20e.DOM_VK_ESCAPE%29%20%7B%0A%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%09if%28onlyStop%29%0A%09%09%09%09%09return%3B%0A%09%09%09%09this.stopSingleEvent%28e%2C%20%22keyup%22%29%3B%0A%09%09%09%09this.stop%28%29%3B%0A%09%09%09%09return%3B%0A%09%09%09%7D%0A%09%09%09var%20ctrlOrCtrlShift%20%3D%20%28e.ctrlKey%20%7C%7C%20e.metaKey%29%20%26%26%20%21e.altKey%3B%0A%09%09%09var%20ctrl%20%20%20%20%20%20%3D%20ctrlOrCtrlShift%20%26%26%20%21e.shiftKey%3B%0A%09%09%09var%20ctrlShift%20%3D%20ctrlOrCtrlShift%20%26%26%20%20e.shiftKey%3B%0A%09%09%09if%28%21ctrlOrCtrlShift%29%0A%09%09%09%09return%3B%0A%0A%09%09%09if%28%21_forbidTooltips%29%0A%09%09%09%09ctrlOrCtrlShift%20%3D%20ctrl%3B%0A%0A%09%09%09if%28ctrlOrCtrlShift%20%26%26%20e.keyCode%20%3D%3D%20e.DOM_VK_UP%29%20%7B%20//%20Ctrl+Up%0A%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%09if%28%21onlyStop%29%0A%09%09%09%09%09this.navigateUp%28%29%3B%0A%09%09%09%7D%0A%09%09%09else%20if%28ctrlOrCtrlShift%20%26%26%20e.keyCode%20%3D%3D%20e.DOM_VK_DOWN%29%20%7B%20//%20Ctrl+Down%0A%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%09if%28%21onlyStop%29%0A%09%09%09%09%09this.navigateDown%28%29%3B%0A%09%09%09%7D%0A%09%09%09if%28ctrlOrCtrlShift%20%26%26%20e.keyCode%20%3D%3D%20e.DOM_VK_RIGHT%29%20%7B%20//%20Ctrl+Right%0A%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%09if%28%21onlyStop%29%0A%09%09%09%09%09this.navigateNext%28%29%3B%0A%09%09%09%7D%0A%09%09%09else%20if%28ctrlOrCtrlShift%20%26%26%20e.keyCode%20%3D%3D%20e.DOM_VK_LEFT%29%20%7B%20//%20Ctrl+Left%0A%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%09if%28%21onlyStop%29%0A%09%09%09%09%09this.navigatePrev%28%29%3B%0A%09%09%09%7D%0A%09%09%09else%20if%28%20//%20Ctrl+Shift+C%0A%09%09%09%09ctrlShift%20%26%26%20%28%0A%09%09%09%09%09e.keyCode%20%3D%3D%20e.DOM_VK_C%20//%20keydown%20%7C%7C%20keyup%0A%09%09%09%09%09%7C%7C%20e.keyCode%20%3D%3D%200%20%26%26%20String.fromCharCode%28e.charCode%29.toUpperCase%28%29%20%3D%3D%20%22C%22%20//%20keypress%0A%09%09%09%09%29%0A%09%09%09%29%20%7B%0A%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%09if%28%21onlyStop%29%0A%09%09%09%09%09this.copyTootipContent%28%29%3B%0A%09%09%09%7D%0A%09%09%09else%20if%28%20//%20Ctrl+I%2C%20Ctrl+Shift+I%0A%09%09%09%09ctrlOrCtrlShift%20%26%26%20%28%0A%09%09%09%09%09e.keyCode%20%3D%3D%20e.DOM_VK_I%20//%20keydown%20%7C%7C%20keyup%0A%09%09%09%09%09%7C%7C%20e.keyCode%20%3D%3D%200%20%26%26%20String.fromCharCode%28e.charCode%29.toUpperCase%28%29%20%3D%3D%20%22I%22%20//%20keypress%0A%09%09%09%09%29%0A%09%09%09%29%20%7B%0A%09%09%09%09this._checkPreventDefault%28e%29%3B%0A%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%09if%28onlyStop%29%0A%09%09%09%09%09return%3B%0A%09%09%09%09this.stopSingleEvent%28e%2C%20%22keyup%22%29%3B%0A%09%09%09%09var%20nodes%20%3D%20this._nodes%3B%0A%09%09%09%09var%20node%20%3D%20nodes.length%20%26%26%20nodes%5B0%5D%3B%0A%09%09%09%09node%20%26%26%20this.inspect%28node%2C%20e.shiftKey%29%3B%0A%09%09%09%7D%0A%09%09%09else%20if%28%20//%20Ctrl+Shift+W%0A%09%09%09%09ctrlShift%20%26%26%20%28%0A%09%09%09%09%09e.keyCode%20%3D%3D%20e.DOM_VK_W%20//%20keydown%20%7C%7C%20keyup%0A%09%09%09%09%09%7C%7C%20e.keyCode%20%3D%3D%200%20%26%26%20String.fromCharCode%28e.charCode%29.toUpperCase%28%29%20%3D%3D%20%22W%22%20//%20keypress%0A%09%09%09%09%29%0A%09%09%09%29%20%7B%0A%09%09%09%09this._checkPreventDefault%28e%29%3B%0A%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%09if%28onlyStop%29%0A%09%09%09%09%09return%3B%0A%09%09%09%09this.stopSingleEvent%28e%2C%20%22keyup%22%29%3B%0A%09%09%09%09var%20nodes%20%3D%20this._nodes%3B%0A%09%09%09%09var%20node%20%3D%20nodes.length%20%26%26%20nodes%5B0%5D%3B%0A%09%09%09%09if%28node%29%20%7B%0A%09%09%09%09%09this.stop%28%29%3B%0A%09%09%09%09%09this.hideUnclosedPopups%28%29%3B%0A%09%09%09%09%09this.closeMenus%28node%29%3B%0A%09%09%09%09%09this.inspectWindow%28node%29%3B%0A%09%09%09%09%7D%0A%09%09%09%7D%0A%09%09%7D%2C%0A%09%09navigateUp%3A%20function%28%29%20%7B%0A%09%09%09var%20nodes%20%3D%20this._nodes%3B%0A%09%09%09var%20node%20%3D%20nodes.length%20%26%26%20this.getParentNode%28nodes%5B0%5D%29%3B%0A%09%09%09if%28node%29%20%7B%0A%09%09%09%09nodes.unshift%28node%29%3B%0A%09%09%09%09this.handleNode%28node%29%3B%0A%09%09%09%7D%0A%09%09%7D%2C%0A%09%09navigateDown%3A%20function%28%29%20%7B%0A%09%09%09var%20nodes%20%3D%20this._nodes%3B%0A%09%09%09if%28nodes.length%20%3E%201%29%20%7B%0A%09%09%09%09nodes.shift%28%29%3B%0A%09%09%09%09this.handleNode%28nodes%5B0%5D%29%3B%0A%09%09%09%7D%0A%09%09%09else%20if%28nodes.length%20%3D%3D%201%29%20%7B%0A%09%09%09%09var%20node%20%3D%20nodes%5B0%5D%3B%0A%09%09%09%09var%20childs%20%3D%20this.getChildNodes%28node%29%3B%0A%09%09%09%09if%28%21childs%29%0A%09%09%09%09%09return%3B%0A%09%09%09%09var%20child%3B%0A%09%09%09%09for%28var%20i%20%3D%200%2C%20l%20%3D%20childs.length%3B%20i%20%3C%20l%3B%20++i%29%20%7B%0A%09%09%09%09%09var%20ch%20%3D%20childs%5Bi%5D%3B%0A%09%09%09%09%09if%28%21_excludeChildTextNodes%20%7C%7C%20ch%20instanceof%20Element%29%20%7B%0A%09%09%09%09%09%09child%20%3D%20ch%3B%0A%09%09%09%09%09%09break%3B%0A%09%09%09%09%09%7D%0A%09%09%09%09%7D%0A%09%09%09%09if%28%21child%20%26%26%20_excludeChildTextNodes%20%3D%3D%201%20%26%26%20l%29%0A%09%09%09%09%09child%20%3D%20childs%5B0%5D%3B%0A%09%09%09%09if%28child%29%20%7B%0A%09%09%09%09%09this._nodes%20%3D%20%5Bchild%5D%3B%0A%09%09%09%09%09this.handleNode%28child%29%3B%0A%09%09%09%09%7D%0A%09%09%09%7D%0A%09%09%7D%2C%0A%09%09navigateNext%3A%20function%28%29%20%7B%0A%09%09%09this.navigateSibling%28true%29%3B%0A%09%09%7D%2C%0A%09%09navigatePrev%3A%20function%28%29%20%7B%0A%09%09%09this.navigateSibling%28false%29%3B%0A%09%09%7D%2C%0A%09%09navigateSibling%3A%20function%28toNext%29%20%7B%0A%09%09%09var%20nodes%20%3D%20this._nodes%3B%0A%09%09%09if%28%21nodes.length%29%0A%09%09%09%09return%3B%0A%09%09%09var%20node%20%3D%20nodes%5B0%5D%3B%0A%09%09%09//var%20sibling%20%3D%20node%3B%0A%09%09%09//do%20sibling%20%3D%20toNext%20%3F%20sibling.nextSibling%20%3A%20sibling.previousSibling%3B%0A%09%09%09//while%28_excludeSiblingTextNodes%20%26%26%20sibling%20%26%26%20%21%28sibling%20instanceof%20Element%29%29%3B%0A%09%09%09var%20parent%20%3D%20this.getParentNode%28node%29%3B%0A%09%09%09var%20siblings%20%3D%20parent%20%26%26%20this.getChildNodes%28parent%2C%20node%29%3B%0A%09%09%09if%28%21siblings%20%7C%7C%20siblings.length%20%3C%202%29%0A%09%09%09%09return%3B%0A%09%09%09var%20max%20%3D%20siblings.length%20-%201%3B%0A%09%09%09var%20pos%20%3D%20Array.prototype.indexOf.call%28siblings%2C%20node%29%3B%0A%09%09%09if%28pos%20%3D%3D%20-1%29%0A%09%09%09%09return%3B%0A%09%09%09var%20shift%20%3D%20toNext%20%3F%201%20%3A%20-1%3B%0A%09%09%09var%20sibling%3B%0A%09%09%09for%28var%20i%20%3D%20pos%20+%20shift%3B%20%3B%20i%20+%3D%20shift%29%20%7B%0A%09%09%09%09if%28_useCycleNavigation%29%20%7B%0A%09%09%09%09%09if%28i%20%3C%200%29%0A%09%09%09%09%09%09i%20%3D%20max%3B%0A%09%09%09%09%09else%20if%28i%20%3E%20max%29%0A%09%09%09%09%09%09i%20%3D%200%3B%0A%09%09%09%09%09if%28i%20%3D%3D%20pos%29%0A%09%09%09%09%09%09break%3B%0A%09%09%09%09%7D%0A%09%09%09%09if%28i%20%3C%200%20%7C%7C%20i%20%3E%20max%29%0A%09%09%09%09%09break%3B%0A%09%09%09%09var%20sb%20%3D%20siblings%5Bi%5D%3B%0A%09%09%09%09if%28sb%20%26%26%20%28%21_excludeSiblingTextNodes%20%7C%7C%20sb%20instanceof%20Element%29%29%20%7B%0A%09%09%09%09%09sibling%20%3D%20sb%3B%0A%09%09%09%09%09break%3B%0A%09%09%09%09%7D%0A%09%09%09%7D%0A%09%09%09if%28%21sibling%29%0A%09%09%09%09return%3B%0A%09%09%09//%20Update%20screen%20position%20for%20mousemoveHandler%28%29%0A%09%09%09var%20rect%20%3D%20this.getScreenRect%28sibling%29%3B%0A%09%09%09if%28%0A%09%09%09%09rect%0A%09%09%09%09%26%26%20%28this.fxVersion%20%3C%203%20%7C%7C%20this.fxVersion%20%3E%203.5%29%0A%09%09%09%09%26%26%20this.isNodeVisible%28sibling%2C%20rect%29%20//%20Wrong%20coordinates%20for%20hidden%20nodes%0A%09%09%09%29%20%7B%0A%09%09%09%09var%20x%20%3D%20rect.screenX%3B%0A%09%09%09%09var%20y%20%3D%20rect.screenY%20+%20rect.height%3B%0A%09%09%09%09if%28x%20%21%3D%20undefined%20%26%26%20y%20%21%3D%20undefined%29%20%7B%0A%09%09%09%09%09this._lastScreenX%20%3D%20x%3B%0A%09%09%09%09%09this._lastScreenY%20%3D%20y%20-%2022%20+%208%3B%0A%09%09%09%09%7D%0A%09%09%09%7D%0A%09%09%09this._nodes%20%3D%20%5Bsibling%5D%3B%0A%09%09%09this.handleNode%28sibling%29%3B%0A%09%09%7D%2C%0A%09%09get%20domUtils%28%29%20%7B%0A%09%09%09delete%20this.domUtils%3B%0A%09%09%09return%20this.domUtils%20%3D%20%22inIDOMUtils%22%20in%20Components.interfaces%0A%09%09%09%09%3F%20Components.classes%5B%[email protected]/inspector/dom-utils%3B1%22%5D%0A%09%09%09%09%09.getService%28Components.interfaces.inIDOMUtils%29%0A%09%09%09%09%3A%20InspectorUtils%3B%20//%20Firefox%2059+%0A%09%09%7D%2C%0A%09%09getParentNode%3A%20function%28node%29%20%7B%0A%09%09%09try%20%7B%0A%09%09%09%09var%20pn%20%3D%20this.domUtils.getParentForNode%28node%2C%20true%29%3B%0A%09%09%09%7D%0A%09%09%09catch%28e%29%20%7B%0A%09%09%09%09if%28%28%22%22%20+%20e%29.indexOf%28%22NS_ERROR_XPC_CANT_PASS_CPOW_TO_NATIVE%22%29%20%3D%3D%20-1%29%0A%09%09%09%09%09Components.utils.reportError%28e%29%3B%0A%09%09%09%09pn%20%3D%20node.parentNode%3B%0A%09%09%09%7D%0A%09%09%09if%28%21pn%20%26%26%20node.nodeType%20%3D%3D%20Node.DOCUMENT_NODE%29%20%7B%20//%20Firefox%201.5%3F%0A%09%09%09%09pn%20%3D%20node.defaultView.QueryInterface%28Components.interfaces.nsIInterfaceRequestor%29%0A%09%09%09%09%09.getInterface%28Components.interfaces.nsIWebNavigation%29%0A%09%09%09%09%09.QueryInterface%28Components.interfaces.nsIDocShell%29%0A%09%09%09%09%09.chromeEventHandler%3B%0A%09%09%09%7D%0A%09%09%09return%20pn%3B%0A%09%09%7D%2C%0A%09%09getTopWindow%3A%20function%28node%29%20%7B%0A%09%09%09var%20win%20%3D%20node.ownerDocument%20%26%26%20node.ownerDocument.defaultView%0A%09%09%09%09%7C%7C%20node.defaultView%0A%09%09%09%09%7C%7C%20node%3B%0A%09%09%09//for%28%3B%3B%29%20%7B%0A%09%09%09//%09var%20browser%20%3D%20this.domUtils.getParentForNode%28win.document%2C%20true%29%3B%0A%09%09%09//%09if%28%21browser%29%0A%09%09%09//%09%09break%3B%0A%09%09%09//%09win%20%3D%20browser.ownerDocument.defaultView.top%3B%0A%09%09%09//%7D%0A%09%09%09try%20%7B%0A%09%09%09%09return%20%22QueryInterface%22%20in%20win%0A%09%09%09%09%09%3F%20win.QueryInterface%28Components.interfaces.nsIInterfaceRequestor%29%0A%09%09%09%09%09%09.getInterface%28Components.interfaces.nsIWebNavigation%29%0A%09%09%09%09%09%09.QueryInterface%28Components.interfaces.nsIDocShellTreeItem%29%0A%09%09%09%09%09%09.rootTreeItem%0A%09%09%09%09%09%09.QueryInterface%28Components.interfaces.nsIInterfaceRequestor%29%0A%09%09%09%09%09%09.getInterface%28Components.interfaces.nsIDOMWindow%29%0A%09%09%09%09%09%3A%20win.docShell.rootTreeItem.domWindow%3B%20//%20Firefox%2070+%0A%09%09%09%7D%0A%09%09%09catch%28e%29%20%7B%0A%09%09%09%09Components.utils.reportError%28e%29%3B%0A%09%09%09%7D%0A%09%09%09return%20win%3B%0A%09%09%7D%2C%0A%09%09getChildNodes%3A%20function%28node%2C%20child%29%20%7B%0A%09%09%09if%28_preferNotAnonymousChildNodes%29%20%7B%0A%09%09%09%09var%20childNodes%20%3D%20node.childNodes%3B%0A%09%09%09%09if%28%21childNodes.length%20%26%26%20%22getAnonymousNodes%22%20in%20node.ownerDocument%29%0A%09%09%09%09%09childNodes%20%3D%20node.ownerDocument.getAnonymousNodes%28node%29%3B%0A%09%09%09%09return%20childNodes%3B%0A%09%09%09%7D%0A%09%09%09var%20du%20%3D%20this.domUtils%3B%0A%09%09%09if%28%22getChildrenForNode%22%20in%20du%29%20try%20%7B%20//%20Gecko%207.0+%0A%09%09%09%09return%20du.getChildrenForNode%28node%2C%20true%29%3B%0A%09%09%09%7D%0A%09%09%09catch%28e%29%20%7B%0A%09%09%09%09if%28%28%22%22%20+%20e%29.indexOf%28%22NS_ERROR_XPC_CANT_PASS_CPOW_TO_NATIVE%22%29%20%3D%3D%20-1%29%0A%09%09%09%09%09Components.utils.reportError%28e%29%3B%0A%09%09%09%09//return%20node.childNodes%3B%0A%09%09%09%7D%0A%09%09%09var%20childNodes%20%3D%20node%20instanceof%20XULElement%0A%09%09%09%09%26%26%20%22getAnonymousNodes%22%20in%20node.ownerDocument%0A%09%09%09%09%26%26%20node.ownerDocument.getAnonymousNodes%28node%29%0A%09%09%09%09%7C%7C%20node.childNodes%3B%0A%09%09%09//%20We%20can%27t%20get%20child%20nodes%20of%20anonymous%20node...%0A%09%09%09if%28%21childNodes%20%7C%7C%20%21childNodes.length%29%20%7B%0A%09%09%09%09if%28%21child%29%0A%09%09%09%09%09child%20%3D%20node.firstChild%3B%0A%09%09%09%09if%28%21child%29%20%7B%20//%20Get%20nearest%20not%20anonymous%20parent%0A%09%09%09%09%09for%28var%20p%20%3D%20node.parentNode%3B%20p%3B%20p%20%3D%20p.parentNode%29%0A%09%09%09%09%09%09if%28p.childNodes.length%29%0A%09%09%09%09%09%09%09return%20p.childNodes%3B%0A%09%09%09%09%7D%0A%09%09%09%09if%28child%29%20%7B%0A%09%09%09%09%09var%20childNodes%20%3D%20%5Bchild%5D%3B%0A%09%09%09%09%09var%20sibling%20%3D%20child%3B%0A%09%09%09%09%09while%28%28sibling%20%3D%20sibling.previousSibling%29%29%0A%09%09%09%09%09%09childNodes.unshift%28sibling%29%3B%0A%09%09%09%09%09sibling%20%3D%20child%3B%0A%09%09%09%09%09while%28%28sibling%20%3D%20sibling.nextSibling%29%29%0A%09%09%09%09%09%09childNodes.push%28sibling%29%3B%0A%09%09%09%09%7D%0A%09%09%09%7D%0A%09%09%09return%20childNodes%3B%0A%09%09%7D%2C%0A%09%09get%20hasDOMInspector%28%29%20%7B%0A%09%09%09delete%20this.hasDOMInspector%3B%0A%09%09%09return%20this.hasDOMInspector%20%3D%20%[email protected]/commandlinehandler/general-startup%3B1%3Ftype%3Dinspector%22%20in%20Components.classes%3B%0A%09%09%7D%2C%0A%09%09checkDOMInspector%3A%20function%28%29%20%7B%0A%09%09%09if%28this.hasDOMInspector%29%0A%09%09%09%09return%20true%3B%0A%09%09%09_log%28%22DOM%20Inspector%20not%20installed%21%22%29%3B%0A%09%09%09var%20label%20%3D%20this.context.button%20%26%26%20this.context.button.label%0A%09%09%09%09%7C%7C%20%22Attributes%20Inspector%22%3B%0A%09%09%09var%20ps%20%3D%20Components.classes%5B%[email protected]/prompter%3B1%22%5D%0A%09%09%09%09%7C%7C%20Components.classes%5B%[email protected]/embedcomp/prompt-service%3B1%22%5D%3B%0A%09%09%09ps.getService%28Components.interfaces.nsIPromptService%29%0A%09%09%09%09.alert%28null%2C%20label%2C%20%22DOM%20Inspector%20not%20found%21%22%29%3B%0A%09%09%09return%20false%3B%0A%09%09%7D%2C%0A%09%09inspectNode%3A%20function%28node%29%20%7B%0A%09%09%09if%28%21this.checkDOMInspector%28%29%29%0A%09%09%09%09return%3B%0A%0A%09%09%09var%20top%20%3D%20this.getTopWindow%28node%29%3B%0A%09%09%09_log%28%22Open%20DOM%20Inspector%20for%20%3C%22%20+%20node.nodeName%20+%20%22%3E%20from%20%22%20+%20top.location%29%3B%0A%09%09%09if%28%21_showFullTree%20%7C%7C%20_nodePosition%20%3C%200%20%7C%7C%20this.fxVersion%20%3C%202%29%20%7B%0A%09%09%09%09//%20See%20window.inspectDOMNode%28%29%0A%09%09%09%09top.openDialog%28%22chrome%3A//inspector/content/%22%2C%20%22_blank%22%2C%20%22chrome%2Call%2Cdialog%3Dno%22%2C%20node%29%3B%0A%09%09%09%09return%3B%0A%09%09%09%7D%0A%0A%09%09%09var%20inspWin%20%3D%20top.openDialog%28%0A%09%09%09%09%22chrome%3A//inspector/content/%22%2C%0A%09%09%09%09%22_blank%22%2C%0A%09%09%09%09%22chrome%2Call%2Cdialog%3Dno%22%2C%0A%09%09%09%09_showFullTree%20%3D%3D%200%0A%09%09%09%09%09%3F%20node.ownerDocument%20%7C%7C%20node%0A%09%09%09%09%09%3A%20_showFullTree%20%3D%3D%201%0A%09%09%09%09%09%09%3F%20%28node.ownerDocument%20%7C%7C%20node%29.defaultView.top.document%0A%09%09%09%09%09%09%3A%20%28top%20%7C%7C%20window.top%29.document%0A%09%09%09%29%3B%0A%09%09%09inspWin%20%3D%20inspWin.wrappedJSObject%20%7C%7C%20inspWin%3B%20//%20At%20least%20for%20Firefox%203.0%0A%09%09%09inspWin.addEventListener%28%22load%22%2C%20function%20onLoad%28e%29%20%7B%0A%09%09%09%09inspWin.removeEventListener%28%22load%22%2C%20onLoad%2C%20false%29%3B%0A%09%09%09%09inspect%28%29%3B%0A%09%09%09%7D%2C%20false%29%3B%0A%0A%09%09%09var%20_this%20%3D%20this%3B%0A%09%09%09var%20stopTime%20%3D%20Date.now%28%29%20+%205e3%3B%0A%09%09%09var%20restoreBlink%20%3D%20this.overrideBoolPref%28%22inspector.blink.on%22%2C%20false%29%3B%0A%09%09%09function%20wait%28%29%20%7B%0A%09%09%09%09if%28Date.now%28%29%20%3C%20stopTime%29%0A%09%09%09%09%09inspWin.setTimeout%28inspect%2C%2010%29%3B%0A%09%09%09%09else%0A%09%09%09%09%09_log%28%22inspectNode%28%29%3A%20take%20too%20many%20time%22%29%3B%0A%09%09%09%7D%0A%09%09%09function%20inspect%28%29%20%7B%0A%09%09%09%09var%20inspector%20%3D%20%22inspector%22%20in%20inspWin%20%26%26%20inspWin.inspector%3B%0A%09%09%09%09if%28%21inspector%29%0A%09%09%09%09%09return%20wait%28%29%3B%0A%09%09%09%09try%20%7B%0A%09%09%09%09%09//%20Avoid%20warnings%20in%20error%20console%20after%20getViewer%28%22dom%22%29%0A%09%09%09%09%09var%20hash%20%3D%20inspector.mPanelSet.registry.mViewerHash%3B%0A%09%09%09%09%09if%28hash%20%26%26%20%21%28%22dom%22%20in%20hash%29%29%0A%09%09%09%09%09%09return%20wait%28%29%3B%0A%09%09%09%09%7D%0A%09%09%09%09catch%28e%29%20%7B%0A%09%09%09%09%09Components.utils.reportError%28e%29%3B%0A%09%09%09%09%7D%0A%09%09%09%09try%20%7B%0A%09%09%09%09%09var%20viewer%20%3D%20inspector.getViewer%28%22dom%22%29%3B%0A%09%09%09%09%7D%0A%09%09%09%09catch%28e%29%20%7B%0A%09%09%09%09%09Components.utils.reportError%28e%29%3B%0A%09%09%09%09%09return%20wait%28%29%3B%0A%09%09%09%09%7D%0A%0A%09%09%09%09_this.timer%28restoreBlink%29%3B%0A%0A%09%09%09%09if%28%22showNodeInTree%22%20in%20viewer%29%20//%20New%20DOM%20Inspector%0A%09%09%09%09%09viewer.showNodeInTree%28node%29%3B%0A%09%09%09%09else%0A%09%09%09%09%09viewer.selectElementInTree%28node%29%3B%0A%09%09%09%09if%28_nodePosition%20%3E%3D%200%29%20%7B%0A%09%09%09%09%09if%28%22nsITreeBoxObject%22%20in%20Components.interfaces%29%20%7B%0A%09%09%09%09%09%09var%20tbo%20%3D%20viewer.mDOMTree.treeBoxObject%3B%0A%09%09%09%09%09%09var%20visibleRows%20%3D%20tbo.height/tbo.rowHeight%3B%0A%09%09%09%09%09%7D%0A%09%09%09%09%09else%20%7B%20//%20Firefox%2066+%2C%20https%3A//bugzilla.mozilla.org/show_bug.cgi%3Fid%3D1482389%0A%09%09%09%09%09%09var%20tbo%20%3D%20viewer.mDOMTree%3B%0A%09%09%09%09%09%09var%20visibleRows%20%3D%20tbo.getPageLength%28%29%3B%0A%09%09%09%09%09%7D%0A%09%09%09%09%09var%20cur%20%3D%20tbo.view.selection.currentIndex%3B%0A%09%09%09%09%09var%20first%20%3D%20tbo.getFirstVisibleRow%28%29%3B%0A%09%09%09%09%09var%20newFirst%20%3D%20cur%20-%20_nodePosition*visibleRows%20+%201%3B%0A%09%09%09%09%09tbo.scrollByLines%28Math.round%28newFirst%20-%20first%29%29%3B%0A%09%09%09%09%09tbo.ensureRowIsVisible%28cur%29%3B%20//%20Should%20be%20visible%2C%20but...%0A%09%09%09%09%7D%0A%09%09%09%09return%20true%3B%0A%09%09%09%7D%0A%09%09%7D%2C%0A%09%09inspectWindow%3A%20function%28node%29%20%7B%0A%09%09%09if%28%21this.checkDOMInspector%28%29%29%0A%09%09%09%09return%3B%0A%0A%09%09%09_log%28%22inspectWindow%28%29%3A%20open%20DOM%20Inspector%20for%20%3C%22%20+%20node.nodeName%20+%20%22%3E%22%29%3B%0A%09%09%09var%20top%20%3D%20this.getTopWindow%28node%29%3B%0A%09%09%09var%20inspWin%20%3D%20top.openDialog%28%0A%09%09%09%09%22chrome%3A//inspector/content/%22%2C%0A%09%09%09%09%22_blank%22%2C%0A%09%09%09%09%22chrome%2Call%2Cdialog%3Dno%22%2C%0A%09%09%09%09//node.ownerDocument%20%7C%7C%20node%0A%09%09%09%09node%0A%09%09%09%29%3B%0A%09%09%09inspWin%20%3D%20inspWin.wrappedJSObject%20%7C%7C%20inspWin%3B%20//%20At%20least%20for%20Firefox%201.5%0A%09%09%09inspWin.addEventListener%28%22load%22%2C%20function%20onLoad%28e%29%20%7B%0A%09%09%09%09inspWin.removeEventListener%28%22load%22%2C%20onLoad%2C%20false%29%3B%0A%09%09%09%09_log%28%22inspectWindow%28%29%3A%20DOM%20Inspector%20loaded%22%29%3B%0A%09%09%09%09wait%28_this.fxVersion%20%3D%3D%201.5%20%3F%20200%20%3A%200%29%3B%0A%09%09%09%7D%2C%20false%29%3B%0A%0A%09%09%09var%20_this%20%3D%20this%3B%0A%09%09%09var%20stopTime%20%3D%20Date.now%28%29%20+%205e3%3B%0A%09%09%09var%20restoreBlink%20%3D%20this.overrideBoolPref%28%22inspector.blink.on%22%2C%20false%29%3B%0A%09%09%09function%20wait%28delay%29%20%7B%0A%09%09%09%09if%28Date.now%28%29%20%3C%20stopTime%29%0A%09%09%09%09%09inspWin.setTimeout%28inspect%2C%20delay%20%7C%7C%2010%29%3B%0A%09%09%09%09else%0A%09%09%09%09%09_log%28%22inspectWindow%28%29%3A%20take%20too%20many%20time%22%29%3B%0A%09%09%09%7D%0A%09%09%09function%20inspect%28%29%20%7B%0A%09%09%09%09var%20doc%20%3D%20inspWin.document%3B%0A%09%09%09%09var%20panel%20%3D%20doc.getElementById%28%22bxDocPanel%22%29%3B%0A%09%09%09%09if%28%21panel%29%0A%09%09%09%09%09return%20wait%28%29%3B%0A%09%09%09%09var%20js%20%3D%20doc.getAnonymousElementByAttribute%28panel%2C%20%22viewerListEntry%22%2C%20%228%22%29%0A%09%09%09%09%09%7C%7C%20doc.getAnonymousElementByAttribute%28panel%2C%20%22viewerListEntry%22%2C%20%227%22%29%3B%20//%20DOM%20Inspector%201.8.1.x%2C%20Firefox%202.0.0.x%0A%09%09%09%09var%20browser%20%3D%20doc.getAnonymousElementByAttribute%28panel%2C%20%22anonid%22%2C%20%22viewer-iframe%22%29%3B%0A%09%09%09%09if%28%21js%20%7C%7C%20%21browser%29%0A%09%09%09%09%09return%20wait%28%29%3B%0A%09%09%09%09_this.timer%28restoreBlink%29%3B%0A%09%09%09%09browser.addEventListener%28%22load%22%2C%20function%20load%28e%29%20%7B%0A%09%09%09%09%09if%28e.target.documentURI%20%3D%3D%20%22about%3Ablank%22%29%0A%09%09%09%09%09%09return%3B%0A%09%09%09%09%09browser.removeEventListener%28e.type%2C%20load%2C%20true%29%3B%0A%09%09%09%09%09stopTime%20%3D%20Date.now%28%29%20+%203e3%3B%0A%09%09%09%09%09inspWin.setTimeout%28function%20selectWindow%28%29%20%7B%0A%09%09%09%09%09%09var%20brDoc%20%3D%20browser.contentDocument%3B%0A%09%09%09%09%09%09var%20tree%20%3D%20brDoc%20%26%26%20brDoc.getElementById%28%22treeJSObject%22%29%3B%0A%09%09%09%09%09%09if%28tree%20%26%26%20tree.view%20%26%26%20tree.view.selection%20%26%26%20tree.columns%29%20%7B%0A%09%09%09%09%09%09%09var%20keyCol%20%3D%20tree.columns.getKeyColumn%28%29%3B%0A%09%09%09%09%09%09%09var%20view%20%3D%20tree.view%3B%0A%09%09%09%09%09%09%09var%20rowCount%20%3D%20view.rowCount%3B%0A%09%09%09%09%09%09%09if%28rowCount%20%3D%3D%201%29%20%7B%20//%20DOM%20Inspector%201.8.1.x%2C%20Firefox%202.0.0.x%0A%09%09%09%09%09%09%09%09tree.changeOpenState%280%2C%20true%29%3B%0A%09%09%09%09%09%09%09%09rowCount%20%3D%20view.rowCount%3B%0A%09%09%09%09%09%09%09%7D%0A%09%09%09%09%09%09%09for%28var%20i%20%3D%200%3B%20i%20%3C%20rowCount%3B%20++i%29%20%7B%0A%09%09%09%09%09%09%09%09var%20cellText%20%3D%20view.getCellText%28i%2C%20keyCol%29%3B%0A%09%09%09%09%09%09%09%09if%28cellText%20%3D%3D%20%22defaultView%22%29%20%7B%0A%09%09%09%09%09%09%09%09%09_log%28%27inspectWindow%28%29%3A%20scroll%20to%20%22defaultView%22%20entry%27%29%3B%0A%09%09%09%09%09%09%09%09%09var%20tbo%20%3D%20%22nsITreeBoxObject%22%20in%20Components.interfaces%0A%09%09%09%09%09%09%09%09%09%09%3F%20tree.treeBoxObject%0A%09%09%09%09%09%09%09%09%09%09%3A%20tree%3B%20//%20Firefox%2066+%0A%09%09%09%09%09%09%09%09%09tbo.beginUpdateBatch%28%29%3B%0A%09%09%09%09%09%09%09%09%09tree.changeOpenState%28i%2C%20true%29%3B%0A%09%09%09%09%09%09%09%09%09view.selection.select%28i%29%3B%0A%09%09%09%09%09%09%09%09%09tbo.scrollByLines%28i%29%3B%0A%09%09%09%09%09%09%09%09%09tbo.ensureRowIsVisible%28i%29%3B%0A%09%09%09%09%09%09%09%09%09tbo.endUpdateBatch%28%29%3B%0A%09%09%09%09%09%09%09%09%09inspWin.setTimeout%28function%28%29%20%7B%20//%20Tree%20not%20yet%20loaded%3F%0A%09%09%09%09%09%09%09%09%09%09var%20di%20%3D%20i%20-%20tbo.getFirstVisibleRow%28%29%3B%0A%09%09%09%09%09%09%09%09%09%09if%28di%29%20%7B%0A%09%09%09%09%09%09%09%09%09%09%09_log%28%22inspectWindow%28%29%3A%20tree%20changed%20%3D%3E%20scrollByLines%28%22%20+%20di%20+%20%22%29%22%29%3B%0A%09%09%09%09%09%09%09%09%09%09%09tbo.scrollByLines%28di%29%3B%0A%09%09%09%09%09%09%09%09%09%09%09tbo.ensureRowIsVisible%28i%29%3B%0A%09%09%09%09%09%09%09%09%09%09%7D%0A%09%09%09%09%09%09%09%09%09%7D%2C%200%29%3B%0A%09%09%09%09%09%09%09%09%09return%3B%0A%09%09%09%09%09%09%09%09%7D%0A%09%09%09%09%09%09%09%7D%0A%09%09%09%09%09%09%7D%0A%09%09%09%09%09%09if%28Date.now%28%29%20%3C%20stopTime%29%0A%09%09%09%09%09%09%09inspWin.setTimeout%28selectWindow%2C%2025%29%3B%0A%09%09%09%09%09%7D%2C%20_this.fxVersion%20%3D%3D%201.5%20%3F%2050%20%3A%200%29%3B%0A%09%09%09%09%7D%2C%20true%29%3B%0A%09%09%09%09_log%28%22inspectWindow%28%29%3A%20select%20JavaScript%20Object%20panel%22%29%3B%0A%09%09%09%09return%20js.doCommand%28%29%3B%0A%09%09%09%7D%0A%09%09%7D%2C%0A%09%09overrideBoolPref%3A%20function%28prefName%2C%20prefVal%29%20%7B%0A%09%09%09var%20prefs%20%3D%20Components.classes%5B%[email protected]/preferences-service%3B1%22%5D%0A%09%09%09%09.getService%28Components.interfaces.nsIPrefBranch%29%3B%0A%09%09%09try%20%7B%0A%09%09%09%09var%20origVal%20%3D%20prefs.getBoolPref%28prefName%29%3B%0A%09%09%09%7D%0A%09%09%09catch%28e%29%20%7B%0A%09%09%09%09//%20Firefox%2058+%3A%20Remove%20support%20for%20extensions%20having%20their%20own%20prefs%20file%0A%09%09%09%09//%20https%3A//bugzilla.mozilla.org/show_bug.cgi%3Fid%3D1413413%0A%09%09%09%7D%0A%09%09%09if%28origVal%20%3D%3D%20prefVal%20%7C%7C%20origVal%20%3D%3D%3D%20undefined%29%0A%09%09%09%09return%20function%20restore%28%29%20%7B%7D%3B%0A%09%09%09prefs.setBoolPref%28prefName%2C%20prefVal%29%3B%0A%09%09%09var%20_this%20%3D%20this%3B%0A%09%09%09function%20restore%28%29%20%7B%0A%09%09%09%09_this.cancelTimer%28timer%29%3B%0A%09%09%09%09prefs.setBoolPref%28prefName%2C%20origVal%29%3B%0A%09%09%09%7D%0A%09%09%09var%20timer%20%3D%20this.timer%28restore%2C%20this%2C%203e3%29%3B%0A%09%09%09return%20restore%3B%0A%09%09%7D%2C%0A%09%09copyTootipContent%3A%20function%28%29%20%7B%0A%09%09%09var%20node%20%3D%20this._node%3B%0A%09%09%09var%20sourceWindow%20%3D%20node%20%26%26%20%28node.ownerDocument%20%7C%7C%20node%29.defaultView%3B%0A%09%09%09var%20tt%20%3D%20this.context.tt%3B%0A%09%09%09var%20text%20%3D%20Array.prototype.map.call%28tt.childNodes%2C%20function%28node%29%20%7B%0A%09%09%09%09return%20node.textContent%3B%0A%09%09%09%7D%29.join%28%22%5Cn%22%29%3B%0A%09%09%09var%20_tt%20%3D%20tt.cloneNode%28true%29%3B%0A%09%09%09Array.prototype.forEach.call%28_tt.getElementsByAttribute%28%22class%22%2C%20%22attrsInspector-value%22%29%2C%20function%28elt%29%20%7B%0A%09%09%09%09elt.style.whiteSpace%20%3D%20%22pre%22%3B%0A%09%09%09%7D%29%3B%0A%09%09%09if%28_tt.firstChild.style.whiteSpace%20%3D%3D%20%22-moz-pre-wrap%22%29%20//%20Part%20of%20hack%20for%20Firefox%201.5%20and%202.0%0A%09%09%09%09_tt.firstChild.style.whiteSpace%20%3D%20%22pre%22%3B%0A%09%09%09var%20html%20%3D%20Array.prototype.map.call%28_tt.childNodes%2C%20function%28node%29%20%7B%0A%09%09%09%09return%20new%20XMLSerializer%28%29.serializeToString%28node%29%3B%0A%09%09%09%7D%29.join%28%22%5Cn%22%29%3B%0A%09%09%09var%20td%20%3D%20text.replace%28/%5Cr%5Cn%3F%7C%5Cn/g%2C%20this.lineBreak%29%3B%0A%09%09%09this.setClipboardData%28%7B%0A%09%09%09%09%22text/plain%22%3A%20%20%20td%2C%0A%09%09%09%09%22text/unicode%22%3A%20td%2C%0A%09%09%09%09%22text/html%22%3A%20%20%20%20html.replace%28/%5Cr%5Cn%3F%7C%5Cn/g%2C%20this.lineBreak%29%0A%09%09%09%7D%2C%20sourceWindow%29%3B%0A%0A%09%09%09if%28%21/%28%3F%3A%5E%7C%5Cs%29attrsInspector-copied%28%3F%3A%5Cs%7C%24%29/.test%28tt.className%29%29%0A%09%09%09%09tt.className%20+%3D%20%22%20attrsInspector-copied%22%3B%0A%09%09%09//tt.style.opacity%20%3D%20%220.75%22%3B%0A%09%09%09tt.style.color%20%3D%20%22grayText%22%3B%0A%09%09%09this.timer%28function%28%29%20%7B%0A%09%09%09%09tt.className%20%3D%20tt.className%0A%09%09%09%09%09.replace%28/%28%3F%3A%5E%7C%5Cs%29attrsInspector-copied%28%3F%3A%5Cs%7C%24%29/%2C%20%22%20%22%29%0A%09%09%09%09%09.replace%28/%5Cs+%24/%2C%20%22%22%29%3B%0A%09%09%09%09//tt.style.opacity%20%3D%20%22%22%3B%0A%09%09%09%09tt.style.color%20%3D%20%22%22%3B%0A%09%09%09%7D%2C%20this%2C%20150%29%3B%0A%09%09%7D%2C%0A%09%09get%20lineBreak%28%29%20%7B%0A%09%09%09delete%20this.lineBreak%3B%0A%09%09%09return%20this.lineBreak%20%3D%20this.appInfo.OS%20%3D%3D%20%22WINNT%22%20%3F%20%22%5Cr%5Cn%22%20%3A%20%22%5Cn%22%3B%0A%09%09%7D%2C%0A%09%09stopSingleEvent%3A%20function%28e%2C%20type%29%20%7B%0A%09%09%09var%20top%20%3D%20this.getTopWindow%28e.target%29%3B%0A%09%09%09var%20stopEvent%20%3D%20this.stopEvent%3B%0A%09%09%09top.addEventListener%28type%2C%20function%20handler%28e%29%20%7B%0A%09%09%09%09top.removeEventListener%28type%2C%20handler%2C%20true%29%3B%0A%09%09%09%09stopEvent%28e%29%3B%0A%09%09%09%7D%2C%20true%29%3B%0A%09%09%7D%2C%0A%09%09mousedownHandler%3A%20function%28e%29%20%7B%0A%09%09%09if%28this.canInspect%28e%29%29%20%7B%0A%09%09%09%09this._checkPreventDefault%28e%29%3B%0A%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%7D%0A%09%09%7D%2C%0A%09%09mouseupHandler%3A%20function%28e%29%20%7B%0A%09%09%09this.mousedownHandler.apply%28this%2C%20arguments%29%3B%0A%09%09%7D%2C%0A%09%09clickHandler%3A%20function%28e%29%20%7B%0A%09%09%09if%28%21this.canInspect%28e%29%29%0A%09%09%09%09return%3B%0A%09%09%09this._checkPreventDefault%28e%29%3B%0A%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09var%20nodes%20%3D%20this._nodes%3B%0A%09%09%09var%20node%20%3D%20nodes.length%20%3F%20nodes%5B0%5D%20%3A%20e.originalTarget%3B%0A%09%09%09this.inspect%28node%2C%20e.shiftKey%29%3B%0A%09%09%7D%2C%0A%09%09inspect%3A%20function%28node%2C%20forcePopupLocker%29%20%7B%0A%09%09%09var%20top%20%3D%20this.getTopWindow%28node%29%3B%0A%09%09%09if%28this.hasDOMInspector%20%26%26%20_popupLocker%20%26%26%20%28_popupLocker%20%3D%3D%202%20%7C%7C%20forcePopupLocker%29%29%0A%09%09%09%09this.lockPopup%28node%29%3B%0A%09%09%09this.stop%28%29%3B%0A%09%09%09this.closeMenus%28node%29%3B%0A%09%09%09this.hideUnclosedPopups%28%29%3B%0A%09%09%09this.inspectNode%28node%29%3B%0A%09%09%7D%2C%0A%09%09getPopup%3A%20function%28node%29%20%7B%0A%09%09%09for%28%3B%20node%20%26%26%20%22tagName%22%20in%20node%3B%20node%20%3D%20node.parentNode%29%0A%09%09%09%09if%28%0A%09%09%09%09%09node.namespaceURI%20%3D%3D%20%22http%3A//www.mozilla.org/keymaster/gatekeeper/there.is.only.xul%22%0A%09%09%09%09%09%26%26%20%22hidePopup%22%20in%20node%0A%09%09%09%09%29%0A%09%09%09%09%09return%20node%3B%0A%09%09%09return%20null%3B%0A%09%09%7D%2C%0A%09%09lockPopup%3A%20function%28node%29%20%7B%0A%09%09%09var%20popup%20%3D%20this.getPopup%28node%29%3B%0A%09%09%09if%28%21popup%29%0A%09%09%09%09return%3B%0A%0A%09%09%09var%20popupLocker%20%3D%20%7B%0A%09%09%09%09context%3A%20this%2C%0A%09%09%09%09domiWindow%3A%20null%2C%0A%09%09%09%09window%3A%20this.getTopWindow%28node%29%2C%0A%09%09%09%09popup%3A%20popup%2C%0A%09%09%09%09tt%3A%20this.context.tt%2C%0A%09%09%09%09ww%3A%20this.context.ww%2C%0A%09%09%09%09fxVersion%3A%20this.fxVersion%2C%0A%09%09%09%09closeMenus%3A%20this.closeMenus%2C%0A%09%09%09%09stopEvent%3A%20this.stopEvent%2C%0A%09%09%09%09stopSingleEvent%3A%20function%28%29%20%7B%0A%09%09%09%09%09this.context.stopSingleEvent.apply%28this.context%2C%20arguments%29%3B%0A%09%09%09%09%7D%2C%0A%09%09%09%09_getPopupInfo%3A%20this._getPopupInfo%2C%0A%09%09%09%09_popups%3A%20%5B%5D%2C%0A%09%09%09%09init%3A%20function%28%29%20%7B%0A%09%09%09%09%09var%20w%20%3D%20this.window%3B%0A%09%09%09%09%09//w.addEventListener%28%22unload%22%2C%20%20%20%20%20%20%20this%2C%20false%29%3B%0A%09%09%09%09%09w.addEventListener%28%22keydown%22%2C%20%20%20%20%20%20this%2C%20true%29%3B%0A%09%09%09%09%09w.addEventListener%28%22keypress%22%2C%20%20%20%20%20this%2C%20true%29%3B%0A%09%09%09%09%09w.addEventListener%28%22keyup%22%2C%20%20%20%20%20%20%20%20this%2C%20true%29%3B%0A%09%09%09%09%09w.addEventListener%28%22popupshowing%22%2C%20this%2C%20true%29%3B%0A%09%09%09%09%09w.addEventListener%28%22popuphiding%22%2C%20%20this%2C%20true%29%3B%0A%09%09%09%09%09this.ww.registerNotification%28this%29%3B%0A%09%09%09%09%09_log%28%22Popup%20locker%3A%20start%22%29%3B%0A%09%09%09%09%7D%2C%0A%09%09%09%09destroy%3A%20function%28%29%20%7B%0A%09%09%09%09%09var%20w%20%3D%20this.window%3B%0A%09%09%09%09%09//w.removeEventListener%28%22unload%22%2C%20%20%20%20%20%20%20this%2C%20false%29%3B%0A%09%09%09%09%09w.removeEventListener%28%22keydown%22%2C%20%20%20%20%20%20this%2C%20true%29%3B%0A%09%09%09%09%09w.removeEventListener%28%22keypress%22%2C%20%20%20%20%20this%2C%20true%29%3B%0A%09%09%09%09%09w.removeEventListener%28%22keyup%22%2C%20%20%20%20%20%20%20%20this%2C%20true%29%3B%0A%09%09%09%09%09w.removeEventListener%28%22popupshowing%22%2C%20this%2C%20true%29%3B%0A%09%09%09%09%09w.removeEventListener%28%22popuphiding%22%2C%20%20this%2C%20true%29%3B%0A%09%09%09%09%09this.ww.unregisterNotification%28this%29%3B%0A%09%09%09%09%09this._popups.forEach%28function%28popup%29%20%7B%0A%09%09%09%09%09%09if%28%22hidePopup%22%20in%20popup%29%0A%09%09%09%09%09%09%09popup.hidePopup%28%29%3B%0A%09%09%09%09%09%7D%29%3B%0A%09%09%09%09%09_log%28%22Popup%20locker%3A%20stop%22%29%3B%0A%09%09%09%09%7D%2C%0A%09%09%09%09handleEvent%3A%20function%28e%29%20%7B%0A%09%09%09%09%09switch%28e.type%29%20%7B%0A%09%09%09%09%09%09case%20%22popupshowing%22%3A%0A%09%09%09%09%09%09%09var%20popup%20%3D%20e.originalTarget%3B%0A%09%09%09%09%09%09%09if%28popup%20%3D%3D%20this.tt%29%0A%09%09%09%09%09%09%09%09break%3B%0A%09%09%09%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%09%09%09%09_log%28%22Popup%20locker%3A%20prevent%20popup%20showing%3A%20%22%20+%20this._getPopupInfo%28popup%29%29%3B%0A%09%09%09%09%09%09break%3B%0A%09%09%09%09%09%09case%20%22popuphiding%22%3A%0A%09%09%09%09%09%09%09var%20popup%20%3D%20e.originalTarget%3B%0A%09%09%09%09%09%09%09if%28popup%20%3D%3D%20this.tt%29%0A%09%09%09%09%09%09%09%09break%3B%0A%09%09%09%09%09%09%09//if%28e.originalTarget%20%3D%3D%20this.popup%29%0A%09%09%09%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%09%09%09%09_log%28%22Popup%20locker%3A%20prevent%20popup%20hiding%3A%20%22%20+%20this._getPopupInfo%28popup%29%29%3B%0A%09%09%09%09%09%09%09if%28this._popups.indexOf%28popup%29%20%3D%3D%20-1%29%0A%09%09%09%09%09%09%09%09this._popups.push%28popup%29%3B%0A%09%09%09%09%09%09break%3B%0A%09%09%09%09%09%09case%20%22keydown%22%3A%0A%09%09%09%09%09%09case%20%22keypress%22%3A%0A%09%09%09%09%09%09case%20%22keyup%22%3A%0A%09%09%09%09%09%09%09var%20onlyStop%20%3D%20this.fxVersion%20%3C%2025%20//%20See%20notes%20in%20keypressHandler%28%29%0A%09%09%09%09%09%09%09%09%3F%20e.type%20%3D%3D%20%22keydown%22%20%7C%7C%20e.type%20%3D%3D%20%22keyup%22%0A%09%09%09%09%09%09%09%09%3A%20e.type%20%3D%3D%20%22keypress%22%20%7C%7C%20e.type%20%3D%3D%20%22keyup%22%3B%0A%09%09%09%09%09%09%09if%28e.keyCode%20%3D%3D%20e.DOM_VK_ESCAPE%29%20%7B%0A%09%09%09%09%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%09%09%09%09%09if%28onlyStop%29%0A%09%09%09%09%09%09%09%09%09return%3B%0A%09%09%09%09%09%09%09%09this.stopSingleEvent%28e%2C%20%22keyup%22%29%3B%0A%09%09%09%09%09%09%09%09_log%28%22Popup%20locker%3A%20Escape%20pressed%20%3D%3E%20destroy%22%29%3B%0A%09%09%09%09%09%09%09%09this.destroy%28%29%3B%0A%09%09%09%09%09%09%09%09this.closeMenus%28this.popup%29%3B%0A%09%09%09%09%09%09%09%7D%0A%09%09%09%09%09%09break%3B%0A%09%09%09%09%09%09case%20%22load%22%3A%0A%09%09%09%09%09%09%09var%20win%20%3D%20e.target.defaultView%3B%0A%09%09%09%09%09%09%09win.removeEventListener%28%22load%22%2C%20this%2C%20false%29%3B%0A%09%09%09%09%09%09%09if%28%21this.domiWindow%20%26%26%20win.location.href%20%3D%3D%20%22chrome%3A//inspector/content/inspector.xul%22%29%20%7B%0A%09%09%09%09%09%09%09%09_log%28%22Popup%20locker%3A%20DOM%20Inspector%20opened%22%29%3B%0A%09%09%09%09%09%09%09%09this.domiWindow%20%3D%20win%3B%0A%09%09%09%09%09%09%09%7D%0A%09%09%09%09%09%7D%0A%09%09%09%09%7D%2C%0A%09%09%09%09observe%3A%20function%28subject%2C%20topic%2C%20data%29%20%7B%0A%09%09%09%09%09if%28topic%20%3D%3D%20%22domwindowopened%22%29%20%7B%0A%09%09%09%09%09%09subject.addEventListener%28%22load%22%2C%20this%2C%20false%29%3B%0A%09%09%09%09%09%7D%0A%09%09%09%09%09else%20if%28topic%20%3D%3D%20%22domwindowclosed%22%29%20%7B%0A%09%09%09%09%09%09subject.removeEventListener%28%22load%22%2C%20this%2C%20false%29%3B%0A%09%09%09%09%09%09if%28subject%20%3D%3D%20this.domiWindow%29%20%7B%0A%09%09%09%09%09%09%09_log%28%22Popup%20locker%3A%20DOM%20Inspector%20closed%20%3D%3E%20destroy%22%29%3B%0A%09%09%09%09%09%09%09this.destroy%28%29%3B%0A%09%09%09%09%09%09%7D%0A%09%09%09%09%09%09else%20if%28subject%20%3D%3D%20this.window%29%20%7B%0A%09%09%09%09%09%09%09_log%28%22Popup%20locker%3A%20locked%20window%20closed%20%3D%3E%20destroy%22%29%3B%0A%09%09%09%09%09%09%09this.destroy%28%29%3B%0A%09%09%09%09%09%09%7D%0A%09%09%09%09%09%7D%0A%09%09%09%09%7D%0A%09%09%09%7D%3B%0A%09%09%09popupLocker.init%28%29%3B%0A%09%09%7D%2C%0A%09%09_checkPreventDefault%3A%20function%28e%29%20%7B%0A%09%09%09try%20%7B%0A%09%09%09%09if%28%22defaultPrevented%22%20in%20e%20%3F%20e.defaultPrevented%20%3A%20e.getPreventDefault%28%29%29%0A%09%09%09%09%09_log%28%27Warning%21%20Default%20action%20for%20%22%27%20+%20e.type%20+%20%27%22%20event%20is%20already%20cancelled%21%27%29%3B%0A%09%09%09%7D%0A%09%09%09catch%28e%29%20%7B%20//%20e10s%3A%20TypeError%3A%20%27getPreventDefault%27%20called%20on%20an%20object%20that%20does%20not%20implement%20interface%20Event.%0A%09%09%09%09if%28_debug%20%7C%7C%20%28%22%22%20+%20e%29.indexOf%28%22does%20not%20implement%20interface%22%29%20%3D%3D%20-1%29%0A%09%09%09%09%09Components.utils.reportError%28e%29%3B%0A%09%09%09%7D%0A%09%09%7D%2C%0A%09%09closeMenus%3A%20function%28node%29%20%7B%0A%09%09%09//%20Based%20on%20function%20closeMenus%20from%20chrome%3A//browser/content/utilityOverlay.js%0A%09%09%09for%28%3B%20node%20%26%26%20%22tagName%22%20in%20node%3B%20node%20%3D%20node.parentNode%29%20%7B%0A%09%09%09%09if%28%0A%09%09%09%09%09node.namespaceURI%20%3D%3D%20%22http%3A//www.mozilla.org/keymaster/gatekeeper/there.is.only.xul%22%0A%09%09%09%09%09%26%26%20%28node.localName%20%3D%3D%20%22menupopup%22%20%7C%7C%20node.localName%20%3D%3D%20%22popup%22%29%0A%09%09%09%09%29%0A%09%09%09%09%09node.hidePopup%28%29%3B%0A%09%09%09%7D%0A%09%09%7D%2C%0A%0A%09%09_popups%3A%20%5B%5D%2C%0A%09%09__shiftKey%3A%20false%2C%0A%09%09get%20_shiftKey%28%29%20%7B%0A%09%09%09return%20this.__shiftKey%3B%0A%09%09%7D%2C%0A%09%09set%20_shiftKey%28val%29%20%7B%0A%09%09%09if%28val%20%3D%3D%20this.__shiftKey%29%0A%09%09%09%09return%3B%0A%09%09%09this.__shiftKey%20%3D%20val%3B%0A%09%09%09%21val%20%26%26%20this.hideUnclosedPopups%28%29%3B%0A%09%09%09if%28_showMargins%20%3D%3D%202%20%26%26%20this._node%29%0A%09%09%09%09this.setDataProxy%28this._node%29%3B%0A%09%09%7D%2C%0A%09%09hideUnclosedPopups%3A%20function%28%29%20%7B%0A%09%09%09this._popups.forEach%28function%28popup%29%20%7B%0A%09%09%09%09if%28%22hidePopup%22%20in%20popup%29%20%7B%0A%09%09%09%09%09popup.hidePopup%28%29%3B%0A%09%09%09%09%09_log%28%22Hide%20popup%3A%20%22%20+%20this._getPopupInfo%28popup%29%29%3B%0A%09%09%09%09%7D%0A%09%09%09%7D%2C%20this%29%3B%0A%09%09%09this._popups%20%3D%20%5B%5D%3B%0A%09%09%7D%2C%0A%09%09popupshowingHandler%3A%20function%28e%29%20%7B%0A%09%09%09var%20tar%20%3D%20e.originalTarget%3B%0A%09%09%09if%28tar%20%3D%3D%20this.context.tt%29%0A%09%09%09%09return%3B%0A%09%09%09if%28this._shiftKey%29%0A%09%09%09%09return%3B%0A%09%09%09if%28tar.localName%20%3D%3D%20%22tooltip%22%29%20%7B%0A%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%09_log%28%22Forbid%20tooltip%20showing%3A%20%22%20+%20this._getPopupInfo%28tar%29%29%3B%0A%09%09%09%7D%0A%09%09%7D%2C%0A%09%09popupshownHandler%3A%20function%28e%29%20%7B%0A%09%09%09var%20tar%20%3D%20e.originalTarget%3B%0A%09%09%09if%28tar%20%3D%3D%20this.context.tt%29%0A%09%09%09%09return%3B%0A%09%09%09if%28/*this._shiftKey%20%26%26%20*/tar.localName%20%3D%3D%20%22tooltip%22%29%0A%09%09%09%09return%3B%0A%09%09%09this.makeTooltipTopmost%28true%29%3B%0A%09%09%09_log%28e.type%20+%20%22%20%3D%3E%20make%20tooltip%20topmost%22%29%3B%0A%09%09%7D%2C%0A%09%09makeTooltipTopmost%3A%20function%28restorePos%29%20%7B%0A%09%09%09this.context.tt.hidePopup%28%29%3B%20//%20Ugly%20with%20show/hide%20tooltips%20animation%0A%09%09%09restorePos%20%26%26%20this.mousemoveHandler%28%29%3B%0A%09%09%7D%2C%0A%09%09popuphidingHandler%3A%20function%28e%29%20%7B%0A%09%09%09if%28%21this._shiftKey%29%0A%09%09%09%09return%3B%0A%09%09%09var%20tar%20%3D%20e.originalTarget%3B%0A%09%09%09if%28/*tar.localName%20%3D%3D%20%22tooltip%22%20%26%26%20*/tar%20%21%3D%20this.context.tt%29%20%7B%0A%09%09%09%09this.stopEvent%28e%29%3B%0A%09%09%09%09if%28this._popups.indexOf%28tar%29%20%3D%3D%20-1%29%0A%09%09%09%09%09this._popups.push%28tar%29%3B%0A%09%09%09%09_log%28%22Forbid%20popup%20hiding%3A%20%22%20+%20this._getPopupInfo%28tar%29%29%3B%0A%09%09%09%7D%0A%09%09%7D%2C%0A%09%09_getPopupInfo%3A%20function%28tt%29%20%7B%0A%09%09%09var%20ret%20%3D%20%22%3C%22%20+%20tt.nodeName%20+%20%22%3E%22%3B%0A%09%09%09if%28tt.id%29%0A%09%09%09%09ret%20+%3D%20%27%20id%3D%22%27%20+%20tt.id%20+%20%27%22%27%3B%0A%09%09%09if%28tt.className%29%0A%09%09%09%09ret%20+%3D%20%27%20class%3D%22%27%20+%20tt.className%20+%20%27%22%27%3B%0A%09%09%09var%20val%20%3D%20tt.value%20%7C%7C%20tt.getAttribute%28%22value%22%29%20%7C%7C%20tt.getAttribute%28%22label%22%29%20%7C%7C%20tt.textContent%3B%0A%09%09%09if%28val%29%0A%09%09%09%09ret%20+%3D%20%27%20%22%27%20+%20val%20+%20%27%22%27%3B%0A%09%09%09return%20ret%3B%0A%09%09%7D%2C%0A%0A%09%09observe%3A%20function%28subject%2C%20topic%2C%20data%29%20%7B%0A%09%09%09if%28topic%20%3D%3D%20%22domwindowopened%22%29%20%7B%0A%09%09%09%09this.context.setListeners%28ael%2C%20subject%29%3B%0A%09%09%09%09_log%28%22New%20window%20opened%22%29%3B%0A%09%09%09%09if%28%21_debug%29%0A%09%09%09%09%09return%3B%0A%09%09%09%09this._loadHandler%20%3D%20%7B%0A%09%09%09%09%09parent%3A%20this%2C%0A%09%09%09%09%09window%3A%20subject%2C%0A%09%09%09%09%09handleEvent%3A%20function%28e%29%20%7B%0A%09%09%09%09%09%09if%28e.target.defaultView%20%21%3D%20this.window%29%20//%3F%0A%09%09%09%09%09%09%09return%3B%0A%09%09%09%09%09%09_log%28%22New%20window%20loaded%3A%20%22%20+%20e.target.title%20+%20%22%20%28%22%20+%20e.target.location%20+%20%22%29%22%29%3B%0A%09%09%09%09%09%09this.destroy%28%29%3B%0A%09%09%09%09%09%7D%2C%0A%09%09%09%09%09destroy%3A%20function%28%29%20%7B%0A%09%09%09%09%09%09this.window.removeEventListener%28%22load%22%2C%20this%2C%20false%29%3B%0A%09%09%09%09%09%09delete%20this.parent._loadHandler%3B%0A%09%09%09%09%09%7D%0A%09%09%09%09%7D%3B%0A%09%09%09%09subject.addEventListener%28%22load%22%2C%20this._loadHandler%2C%20false%29%3B%0A%09%09%09%7D%0A%09%09%09else%20if%28topic%20%3D%3D%20%22domwindowclosed%22%29%20%7B%0A%09%09%09%09if%28this.hasOwnProperty%28%22_loadHandler%22%29%29%20//%20Window%20can%20be%20closed%20before%20%22load%22%20event%20happens%0A%09%09%09%09%09this._loadHandler.destroy%28%29%3B%0A%09%09%09%09this.context.setListeners%28rel%2C%20subject%29%3B%0A%09%09%09%09if%28subject%20%3D%3D%20this.window%29%0A%09%09%09%09%09this.stop%28%29%3B%0A%09%09%09%09_log%28%22Window%20closed%3A%20%22%20+%20%28subject.document%20%26%26%20subject.document.title%29%20+%20%22%20%28%22%20+%20subject.location%20+%20%22%29%22%29%3B%0A%09%09%09%7D%0A%09%09%7D%0A%09%7D%3B%0A%0A%09this.setAllListeners%28ael%29%3B%0A%09this.ww.registerNotification%28this.eventHandler%29%3B%0A%09var%20btn%20%3D%20this.button%3B%0A%09if%28btn%29%20%7B%0A%09%09var%20destructor%20%3D%20function%28reason%29%20%7B%0A%09%09%09if%28reason%20%3D%3D%20%22delete%22%29%20%7B%0A%09%09%09%09_log%28%27%22Delete%20button%22%20pressed%20-%3E%20stop%28%29%27%29%3B%0A%09%09%09%09context.stop%28%29%3B%0A%09%09%09%7D%0A%09%09%7D%3B%0A%09%09if%28%0A%09%09%09typeof%20addDestructor%20%3D%3D%20%22function%22%20//%20Custom%20Buttons%200.0.5.6pre4+%0A%09%09%09%26%26%20addDestructor%20%21%3D%20%28%22addDestructor%22%20in%20window%20%26%26%20window.addDestructor%29%0A%09%09%29%20%7B%0A%09%09%09btn._attrsInspectorHasAddDestructor%20%3D%20true%3B%0A%09%09%09addDestructor%28destructor%2C%20this%29%3B%0A%09%09%7D%0A%09%09else%20%7B%0A%09%09%09if%28%22onDestroy%22%20in%20btn%29%0A%09%09%09%09var%20origOnDestroy%20%3D%20btn._attrsInspectorOrigOnDestroy%20%3D%20btn.onDestroy%3B%0A%09%09%09btn.onDestroy%20%3D%20function%28reason%29%20%7B%0A%09%09%09%09destructor%28reason%29%3B%0A%09%09%09%09origOnDestroy%20%26%26%20origOnDestroy.apply%28this%2C%20arguments%29%3B%0A%09%09%09%7D%3B%0A%09%09%7D%0A%09%7D%0A%09_log%28%0A%09%09%22Successfully%20started%21%22%0A%09%09+%20%22%5CnMode%3A%20%22%20+%20%28%0A%09%09%09btn%0A%09%09%09%09%3F%20%22Custom%20Button%22%0A%09%09%09%09%3A%20%22No%20Button%22%0A%09%09%29%0A%09%09+%20%22%2C%20highlighter%3A%20%22%20+%20%28%0A%09%09%09_highlightUsingFlasher%0A%09%09%09%09%3F%20%22inIFlasher%22%0A%09%09%09%09%3A%20this.eventHandler.noStyles%0A%09%09%09%09%09%3F%20%22inline%20CSS%22%0A%09%09%09%09%09%3A%20%22nsIStyleSheetService%22%0A%09%09%29%0A%09%29%3B%0A%7D%0Afunction%20destroy%28%29%20%7B%0A%09var%20tt%20%3D%20this.tt%3B%0A%09if%28%21tt%20%7C%7C%20%21tt.parentNode%29%0A%09%09return%3B%0A%09tt.hidePopup%28%29%3B%0A%09tt.parentNode.removeChild%28tt%29%3B%0A%0A%09var%20eh%20%3D%20this.eventHandler%3B%0A%09eh.unwatchAttrs%28%29%3B%0A%09eh.unhl%28%29%3B%0A%09eh.destroyTimers%28%29%3B%0A%09if%28%21_highlightUsingFlasher%29%20%7B%0A%09%09var%20sss%20%3D%20this.sss%3B%0A%09%09var%20cssURI%20%3D%20this.cssURI%3B%0A%09%09if%28sss.sheetRegistered%28cssURI%2C%20sss.AGENT_SHEET%29%29%0A%09%09%09sss.unregisterSheet%28cssURI%2C%20sss.AGENT_SHEET%29%3B%0A%09%09if%28sss.sheetRegistered%28cssURI%2C%20sss.USER_SHEET%29%29%0A%09%09%09sss.unregisterSheet%28cssURI%2C%20sss.USER_SHEET%29%3B%0A%09%7D%0A%09this.setAllListeners%28rel%29%3B%0A%09this.ww.unregisterNotification%28eh%29%3B%0A%09var%20btn%20%3D%20this.button%3B%0A%09if%28btn%29%20%7B%0A%09%09if%28%22_attrsInspectorOrigOnDestroy%22%20in%20btn%29%0A%09%09%09btn.onDestroy%20%3D%20btn._attrsInspectorOrigOnDestroy%3B%0A%09%09else%20if%28%21%28%22_attrsInspectorHasAddDestructor%22%20in%20btn%29%29%0A%09%09%09delete%20btn.onDestroy%3B%0A%09%09delete%20btn._attrsInspectorOrigOnDestroy%3B%0A%09%09delete%20btn._attrsInspectorHasAddDestructor%3B%0A%09%7D%0A%09delete%20window%5B_ns%5D%3B%0A%09_log%28%22Shutdown%20finished%21%22%29%3B%0A%7D%0A%7D%29.call%28this%29%3B%5D%5D%3E%3C/code%3E%0A%20%20%3Caccelkey%3E%3C%21%5BCDATA%5BAlt+Ctrl+i%5D%5D%3E%3C/accelkey%3E%0A%20%20%3Chelp%3E%3C%21%5BCDATA%5BUsage%3A%0A%20%20%20Use%20middle-click%20or%20Ctrl%20+%20left-click%20%28or%20press%20Ctrl+I%29%20to%20inspect%20node%20in%20DOM%20Inspector%0A%20%20%20%28additionally%20hold%20Shift%20key%20to%20enable%20pupup%20locker%29%0A%20%20%20Hold%20Shift%20key%20to%20show%20and%20don%27t%20hide%20tooltips%20and%20popups%0AHotkeys%3A%0A%20%20%20Escape%20%u2013%20cancel%20or%20disable%20popup%20locker%0A%20%20%20Ctrl+Up%2C%20Ctrl+Down%20%u2013%20navigate%20to%20parent/child%20node%0A%20%20%20Ctrl+Left%2C%20Ctrl+Right%20-%20navigate%20to%20previous/next%20sibling%20node%0A%20%20%20Ctrl+Shift+C%20%u2013%20copy%20tooltip%27s%20contents%0A%20%20%20Ctrl+W%20%u2013%20inspect%20node%27s%20window%20object%20in%20DOM%20Inspector%0A%0A%u0418%u0441%u043F%u043E%u043B%u044C%u0437%u043E%u0432%u0430%u043D%u0438%u0435%3A%0A%20%20%20%u041A%u043B%u0438%u043A%u043D%u0438%u0442%u0435%20%u0441%u0440%u0435%u0434%u043D%u0435%u0439%20%u043A%u043D%u043E%u043F%u043A%u043E%u0439%20%u043C%u044B%u0448%u0438%20%u0438%u043B%u0438%20%u043B%u0435%u0432%u043E%u0439%20%u0441%20%u0437%u0430%u0436%u0430%u0442%u044B%u043C%20Ctrl%20%28%u0438%u043B%u0438%20%u043D%u0430%u0436%u043C%u0438%u0442%u0435%20Ctrl+I%29%2C%20%u0447%u0442%u043E%u0431%u044B%20%u0438%u0441%u0441%u043B%u0435%u0434%u043E%u0432%u0430%u0442%u044C%20%u0443%u0437%u0435%u043B%20%u0432%20DOM%20Inspector%27%u0435%0A%20%20%20%28%u0443%u0434%u0435%u0440%u0436%u0438%u0432%u0430%u0439%u0442%u0435%20%u0434%u043E%u043F%u043E%u043B%u043D%u0438%u0442%u0435%u043B%u044C%u043D%u043E%20Shift%2C%20%u0447%u0442%u043E%u0431%u044B%20%u0432%u043A%u043B%u044E%u0447%u0438%u0442%u044C%20%u0431%u043B%u043E%u043A%u0438%u0440%u043E%u0432%u0449%u0438%u043A%20%u0432%u0441%u043F%u043B%u044B%u0432%u0430%u044E%u0449%u0438%u0445%20%u043F%u043E%u0434%u0441%u043A%u0430%u0437%u043E%u043A%20%u0438%20%u043C%u0435%u043D%u044E%29%0A%20%20%20%u0423%u0434%u0435%u0440%u0436%u0438%u0432%u0430%u0439%u0442%u0435%20Shift%2C%20%u0447%u0442%u043E%u0431%u044B%20%u043F%u043E%u043A%u0430%u0437%u044B%u0432%u0430%u0442%u044C%20%u0438%20%u043D%u0435%20%u0441%u043A%u0440%u044B%u0432%u0430%u0442%u044C%20%u0432%u0441%u043F%u043B%u044B%u0432%u0430%u044E%u0449%u0438%u0435%20%u043F%u043E%u0434%u0441%u043A%u0430%u0437%u043A%u0438%20%u0438%20%u043C%u0435%u043D%u044E%0A%u0421%u043E%u0447%u0435%u0442%u0430%u043D%u0438%u044F%20%u043A%u043B%u0430%u0432%u0438%u0448%3A%0A%20%20%20Escape%20%u2013%20%u043E%u0442%u043C%u0435%u043D%u0430%20%u0438%u043B%u0438%20%u043E%u0442%u043A%u043B%u044E%u0447%u0438%u0442%u044C%20%u0431%u043B%u043E%u043A%u0438%u0440%u043E%u0432%u0449%u0438%u043A%20%u0432%u0441%u043F%u043B%u044B%u0432%u0430%u044E%u0449%u0438%u0445%20%u043F%u043E%u0434%u0441%u043A%u0430%u0437%u043E%u043A%20%u0438%20%u043C%u0435%u043D%u044E%0A%20%20%20Ctrl+Up%2C%20Ctrl+Down%20%u2013%20%u043F%u0435%u0440%u0435%u0439%u0442%u0438%20%u043A%20%u0440%u043E%u0434%u0438%u0442%u0435%u043B%u044C%u0441%u043A%u043E%u043C%u0443/%u0434%u043E%u0447%u0435%u0440%u043D%u0435%u043C%u0443%20%u0443%u0437%u043B%u0443%0A%20%20%20Ctrl+Left%2C%20Ctrl+Right%20%u2013%20%u043F%u0435%u0440%u0435%u0439%u0442%u0438%20%u043A%20%u043F%u0440%u0435%u0434%u044B%u0434%u0443%u0449%u0435%u043C%u0443/%u0441%u043B%u0435%u0434%u0443%u044E%u0449%u0435%u043C%u0443%20%u0443%u0437%u043B%u0443%0A%20%20%20Ctrl+Shift+C%20%u2013%20%u043A%u043E%u043F%u0438%u0440%u043E%u0432%u0430%u0442%u044C%20%u0441%u043E%u0434%u0435%u0440%u0436%u0438%u043C%u043E%u0435%20%u0432%u0441%u043F%u043B%u044B%u0432%u0430%u044E%u0449%u0435%u0439%20%u043F%u043E%u0434%u0441%u043A%u0430%u0437%u043A%u0438%0A%20%20%20Ctrl+W%20%u2013%20%u0438%u0441%u0441%u043B%u0435%u0434%u043E%u0432%u0430%u0442%u044C%20%u043E%u0431%u044A%u0435%u043A%u0442%20window%20%u0443%u0437%u043B%u0430%20%u0432%20DOM%20Inspector%27e%5D%5D%3E%3C/help%3E%0A%20%20%3Cattributes/%3E%0A%3C/custombutton%3E"
>Install</a>
| <a href="https://github.com/Infocatcher/Custom_Buttons/tree/master/Attributes_Inspector">Source</a>
| <a href="https://github.com/Infocatcher/Custom_Buttons#usage">Instructions</a>
<script type="text/javascript">
var a = document.getElementsByTagName("a")[0];
a.title = document.title;
if(/%3Cimage%3E%3C%21%5BCDATA%5B(data%3A\S+)%5D%5D%3E%3C\/image%3E/.test(a.href)) {
var icon = decodeURIComponent(RegExp.$1);
var img = document.createElement("img");
img.src = icon;
img.alt = "";
img.style.verticalAlign = "middle";
img.style.marginRight = "4px";
img.style.border = "none";
a.insertBefore(img, a.firstChild);
var link = document.createElement("link");
link.rel = "shortcut icon";
link.href = icon;
document.documentElement.insertBefore(link, document.documentElement.firstChild);
}
</script>
<script type="text/javascript" src="https://infocatcher.github.io/Custom_Buttons/viewCustomButton.js"></script>
<script type="text/javascript">
if("viewCustomButtonCode" in window) setTimeout(function() {
viewCustomButtonCode(a.href);
}, 0);
</script>
</body>