CINXE.COM
WaterfallBackground.js - mozsearch
<!DOCTYPE html> <html lang="en-US" class="old-rev"> <head> <meta charset="utf-8" /> <meta name="color-scheme" content="light dark"> <link href="/mozilla-central/static/icons/search.png" rel="shortcut icon"> <title>WaterfallBackground.js - mozsearch</title> <link href="/mozilla-central/static/css/mozsearch.css" rel="stylesheet" media="screen"/> <link href="/mozilla-central/static/css/icons.css" rel="stylesheet" media="screen"/> <link href="/mozilla-central/static/css/font-icons.css" rel="stylesheet" media="screen"/> </head> <body> <div id="fixed-header"> <form method="get" action="/mozilla-central/search" class="search-box" id="search-box"> <fieldset> <div id="query-section"> <label for="query" class="query_label visually-hidden">Find</label> <input type="text" name="q" value="" maxlength="2048" id="query" accesskey="s" title="Search" placeholder="Search mozilla-central" autocomplete="off" /> <div class="zero-size-container"> <div class="bubble" id="query-bubble"> </div> </div> <section id="spinner"></section> </div> <div id="option-section" class="v-flex-container"> <label for="case"> <input type="checkbox" name="case" id="case" class="option-checkbox" value="true" accesskey="c"/><span class="access-key">C</span>ase-sensitive </label> <label for="regexp"> <input type="checkbox" name="regexp" id="regexp" class="option-checkbox" value="true" accesskey="r"/><span class="access-key">R</span>egexp search </label> </div> <div id="path-section"> <label for="path" class="query_label visually-hidden">Path</label> <input type="text" name="path" value="" maxlength="2048" id="path" accesskey="p" title="Path" placeholder="Path filter (supports globbing and ^, $)" autocomplete="off" /> <div class="zero-size-container"> <div class="bubble" id="path-bubble"> </div> </div> </div> </fieldset> <!-- disabled to avoid enter-submits behavior that conflicts with JS search logic --> <input type="submit" value="Search" disabled class="visually-hidden" /> <div id="revision"> <span id="rev-id">Showing <a href="/mozilla-central/commit/3265b390bd5d08a5be520253ef71835bcb715f27">3265b390</a>:</span> <span id="rev-desc">Bug <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=1812019">1812019</a> - Animate to static tab icon after 45s r=cmkm,dao,desktop-theme-reviewers,tabbrowser-reviewers</span> </div> </form> </div> <div id="scrolling"> <div id="content" class="content source-listing not-diff" data-no-results="No results for current query."> <div class="breadcrumbs"><a href="/mozilla-central/source/">mozilla-central</a><button id="tree-switcher" title="Open tree switcher menu" aria-expanded="false" aria-haspopup="true" aria-controls="tree-switcher-menu"></button><div id="tree-switcher-menu" title="Tree switcher" role="menu" class="context-menu" style="display: none"></div><span class="path-separator">/</span><a href="/mozilla-central/source/devtools">devtools</a><span class="path-separator">/</span><a href="/mozilla-central/source/devtools/client">client</a><span class="path-separator">/</span><a href="/mozilla-central/source/devtools/client/netmonitor">netmonitor</a><span class="path-separator">/</span><a href="/mozilla-central/source/devtools/client/netmonitor/src">src</a><span class="path-separator">/</span><a href="/mozilla-central/source/devtools/client/netmonitor/src/widgets">widgets</a><span class="path-separator">/</span><a href="/mozilla-central/source/devtools/client/netmonitor/src/widgets/WaterfallBackground.js">WaterfallBackground.js</a></div> <div class="panel" id="panel"> <button id="panel-toggle"> <span class="navpanel-icon icon-down-dir expanded" aria-hidden="false"></span> Navigation <a id="show-settings" title="Go to settings page" href="/mozilla-central/pages/settings.html"><span class="navpanel-icon icon-cog expanded" aria-hidden="false"></span></a> </button> <section id="panel-content" aria-expanded="true" aria-hidden="false"> <label class="panel-accel"><input type="checkbox" id="panel-accel-enable" checked="checked">Enable keyboard shortcuts</label> <h4>Revision control</h4> <ul> <li> <a href="/mozilla-central/source/devtools/client/netmonitor/src/widgets/WaterfallBackground.js" title="Go to latest version" class="icon item" data-update-link="#{}" data-link="/mozilla-central/source/devtools/client/netmonitor/src/widgets/WaterfallBackground.js">Go to latest version<button class="copy" title="Copy to clipboard"><span class="icon-docs copy-icon"></span><span class="icon-ok tick-icon"></span></button></a> </li> <li> <a href="https://hg.mozilla.org/mozilla-central/log/495128bbc3780b459e1f76fe004c96df81765383/devtools/client/netmonitor/src/widgets/WaterfallBackground.js" title="Log" class="icon item">Log <span class="accel">L</span><button class="copy" title="Copy to clipboard"><span class="icon-docs copy-icon"></span><span class="icon-ok tick-icon"></span></button></a> </li> <li> <a href="https://hg.mozilla.org/mozilla-central/raw-file/495128bbc3780b459e1f76fe004c96df81765383/devtools/client/netmonitor/src/widgets/WaterfallBackground.js" title="Raw" class="icon item">Raw <span class="accel">R</span><button class="copy" title="Copy to clipboard"><span class="icon-docs copy-icon"></span><span class="icon-ok tick-icon"></span></button></a> </li> <li> <a href="javascript:alert('Hover over the gray bar on the left to see blame information.')" title="Blame" class="icon item">Blame</a> </li> </ul> <h4>Copy as Markdown</h4> <ul> <li> <button title="Filename Link" class="icon item">Filename Link <span class="accel">F</span><span class="icon copy indicator"><span class="icon-docs copy-icon"></span><span class="icon-ok tick-icon"></span></span></button> </li> <li> <button title="Code Block" class="icon item">Code Block <span class="accel">C</span><span class="icon copy indicator"><span class="icon-docs copy-icon"></span><span class="icon-ok tick-icon"></span></span></button> </li> </ul> </section> </div> <section class="info-boxes" id="info-boxes-container"> </section> <div id="file" class="file" role="table" data-markdown-slug="js"> <div role="row" id="line-1" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#1" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="1"></div> <code role="cell" class="source-line"><span class="syn_comment" >/* This Source Code Form is subject to the terms of the Mozilla Public</span> </code> </div> <div role="row" id="line-2" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#2" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="2"></div> <code role="cell" class="source-line"><span class="syn_comment" > * License, v. 2.0. If a copy of the MPL was not distributed with this</span> </code> </div> <div role="row" id="line-3" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#3" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="3"></div> <code role="cell" class="source-line"><span class="syn_comment" > * file, You can obtain one at <a href="http://mozilla.org/MPL/2.0/">http://mozilla.org/MPL/2.0/</a>. */</span> </code> </div> <div role="row" id="line-4" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#4" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="4"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-5" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#5" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="5"></div> <code role="cell" class="source-line"><span class="syn_string" >"use strict"</span>; </code> </div> <div role="row" id="line-6" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#6" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="6"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-7" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="91ed615c4810470c470a99794218275db735e90b#%#7" role="button" aria-label="new hash 2" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="7"></div> <code role="cell" class="source-line"><span class="syn_reserved" >const</span> { </code> </div> <div role="row" id="line-8" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="91ed615c4810470c470a99794218275db735e90b#%#8" role="button" aria-label="same hash 2" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="8"></div> <code role="cell" class="source-line"> getCssVariableColor, </code> </div> <div role="row" id="line-9" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="91ed615c4810470c470a99794218275db735e90b#%#9" role="button" aria-label="same hash 2" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="9"></div> <code role="cell" class="source-line">} = require(<span class="syn_string" >"<a href="resource://devtools/client/shared/theme.js">resource://devtools/client/shared/theme.js</a>"</span>); </code> </div> <div role="row" id="line-10" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="10185770942f2f4716dadce837d4f4a9f907d4ae#%#9" role="button" aria-label="new hash 3" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="10"></div> <code role="cell" class="source-line"><span class="syn_reserved" >const</span> { </code> </div> <div role="row" id="line-11" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="10185770942f2f4716dadce837d4f4a9f907d4ae#%#10" role="button" aria-label="same hash 3" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="11"></div> <code role="cell" class="source-line"> REQUESTS_WATERFALL, </code> </div> <div role="row" id="line-12" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="13bf78b543faf367f812d93105e818fd18a2e582#%#11" role="button" aria-label="new hash 4" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="12"></div> <code role="cell" class="source-line">} = require(<span class="syn_string" >"<a href="resource://devtools/client/netmonitor/src/constants.js">resource://devtools/client/netmonitor/src/constants.js</a>"</span>); </code> </div> <div role="row" id="line-13" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#20" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="13"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-14" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="ee77eda75ce0722dc212e96f2311e125496341c2#devtools/client/netmonitor/src/waterfall-background.js#9" role="button" aria-label="new hash 5" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="14"></div> <code role="cell" class="source-line"><span class="syn_reserved" >const</span> HTML_NS = <span class="syn_string" >"<a href="http://www.w3.org/1999/xhtml">http://www.w3.org/1999/xhtml</a>"</span>; </code> </div> <div role="row" id="line-15" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#21" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="15"></div> <code role="cell" class="source-line"><span class="syn_reserved" >const</span> STATE_KEYS = [ </code> </div> <div role="row" id="line-16" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="2ae57e4ad5517396aa7023766e7f31b61812741f#%#13" role="button" aria-label="new hash 6" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="16"></div> <code role="cell" class="source-line"> <span class="syn_string" >"firstRequestStartedMs"</span>, </code> </div> <div role="row" id="line-17" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="ee77eda75ce0722dc212e96f2311e125496341c2#devtools/client/netmonitor/src/waterfall-background.js#12" role="button" aria-label="new hash 5" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="17"></div> <code role="cell" class="source-line"> <span class="syn_string" >"scale"</span>, </code> </div> <div role="row" id="line-18" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#25" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="18"></div> <code role="cell" class="source-line"> <span class="syn_string" >"timingMarkers"</span>, </code> </div> <div role="row" id="line-19" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="ee77eda75ce0722dc212e96f2311e125496341c2#devtools/client/netmonitor/src/waterfall-background.js#14" role="button" aria-label="new hash 5" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="19"></div> <code role="cell" class="source-line"> <span class="syn_string" >"waterfallWidth"</span>, </code> </div> <div role="row" id="line-20" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#26" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="20"></div> <code role="cell" class="source-line">]; </code> </div> <div role="row" id="line-21" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#27" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="21"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-22" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#28" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="22"></div> <code role="cell" class="source-line"><span class="syn_comment" >/**</span> </code> </div> <div role="row" id="line-23" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#29" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="23"></div> <code role="cell" class="source-line"><span class="syn_comment" > * Creates the background displayed on each waterfall view in this container.</span> </code> </div> <div role="row" id="line-24" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#30" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="24"></div> <code role="cell" class="source-line"><span class="syn_comment" > */</span> </code> </div> <div role="row" id="line-25" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#22" role="button" aria-label="new hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="25"></div> <code role="cell" class="source-line"><span class="syn_reserved" >class</span> WaterfallBackground { </code> </div> <div role="row" id="line-26" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#23" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="26"></div> <code role="cell" class="source-line"> constructor() { </code> </div> <div role="row" id="line-27" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#24" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="27"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >this</span>.canvas = document.createElementNS(HTML_NS, <span class="syn_string" >"canvas"</span>); </code> </div> <div role="row" id="line-28" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#25" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="28"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >this</span>.ctx = <span class="syn_reserved" >this</span>.canvas.getContext(<span class="syn_string" >"2d"</span>); </code> </div> <div role="row" id="line-29" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#26" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="29"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >this</span>.prevState = {}; </code> </div> <div role="row" id="line-30" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#27" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="30"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-31" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#37" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="31"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-32" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#29" role="button" aria-label="new hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="32"></div> <code role="cell" class="source-line"> <span class="syn_comment" >/**</span> </code> </div> <div role="row" id="line-33" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#30" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="33"></div> <code role="cell" class="source-line"><span class="syn_comment" > * Changes the element being used as the CSS background for a background</span> </code> </div> <div role="row" id="line-34" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#31" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="34"></div> <code role="cell" class="source-line"><span class="syn_comment" > * with a given background element ID.</span> </code> </div> <div role="row" id="line-35" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#32" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="35"></div> <code role="cell" class="source-line"><span class="syn_comment" > *</span> </code> </div> <div role="row" id="line-36" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#33" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="36"></div> <code role="cell" class="source-line"><span class="syn_comment" > * The funtion wrap the Firefox only API. Waterfall Will not draw the</span> </code> </div> <div role="row" id="line-37" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#34" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="37"></div> <code role="cell" class="source-line"><span class="syn_comment" > * vertical line when running on non-firefox browser.</span> </code> </div> <div role="row" id="line-38" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#35" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="38"></div> <code role="cell" class="source-line"><span class="syn_comment" > * Could be fixed by <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=1308695">Bug 1308695</a></span> </code> </div> <div role="row" id="line-39" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#36" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="39"></div> <code role="cell" class="source-line"><span class="syn_comment" > */</span> </code> </div> <div role="row" id="line-40" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#37" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="40"></div> <code role="cell" class="source-line"> setImageElement(imageElementId, imageElement) { </code> </div> <div role="row" id="line-41" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#38" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="41"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >if</span> (document.mozSetImageElement) { </code> </div> <div role="row" id="line-42" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#39" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="42"></div> <code role="cell" class="source-line"> document.mozSetImageElement(imageElementId, imageElement); </code> </div> <div role="row" id="line-43" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#40" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="43"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-44" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="db417c9975cb95d53d9a4fb7b6f476c35bd9ef11#devtools/client/netmonitor/src/waterfall-background.js#46" role="button" aria-label="new hash 8" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="44"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-45" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="db417c9975cb95d53d9a4fb7b6f476c35bd9ef11#devtools/client/netmonitor/src/waterfall-background.js#48" role="button" aria-label="same hash 8" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="45"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-46" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#39" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="46"></div> <code role="cell" class="source-line"> draw(state) { </code> </div> <div role="row" id="line-47" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#40" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="47"></div> <code role="cell" class="source-line"> <span class="syn_comment" >// Do a shallow compare of the previous and the new state</span> </code> </div> <div role="row" id="line-48" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="f6db0ee55782a171ce893389645b7ec1473bc6a6#%#45" role="button" aria-label="new hash 9" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="48"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> shouldUpdate = STATE_KEYS.some( </code> </div> <div role="row" id="line-49" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="f6db0ee55782a171ce893389645b7ec1473bc6a6#%#46" role="button" aria-label="same hash 9" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="49"></div> <code role="cell" class="source-line"> key => <span class="syn_reserved" >this</span>.prevState[key] !== state[key] </code> </div> <div role="row" id="line-50" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="f6db0ee55782a171ce893389645b7ec1473bc6a6#%#47" role="button" aria-label="same hash 9" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="50"></div> <code role="cell" class="source-line"> ); </code> </div> <div role="row" id="line-51" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#42" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="51"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >if</span> (!shouldUpdate) { </code> </div> <div role="row" id="line-52" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#43" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="52"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >return</span>; </code> </div> <div role="row" id="line-53" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#44" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="53"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-54" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#45" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="54"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-55" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#46" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="55"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >this</span>.prevState = state; </code> </div> <div role="row" id="line-56" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#47" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="56"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-57" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="876f7acea147ad2f11e67349565857c5972231c2#devtools/client/netmonitor/waterfall-background.js#47" role="button" aria-label="new hash 10" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="57"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >if</span> (state.waterfallWidth === <span class="syn_reserved" >null</span> || state.scale === <span class="syn_reserved" >null</span>) { </code> </div> <div role="row" id="line-58" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#53" role="button" aria-label="new hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="58"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >this</span>.setImageElement(<span class="syn_string" >"waterfall-background"</span>, <span class="syn_reserved" >null</span>); </code> </div> <div role="row" id="line-59" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#50" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="59"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >return</span>; </code> </div> <div role="row" id="line-60" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#51" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="60"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-61" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#52" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="61"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-62" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#53" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="62"></div> <code role="cell" class="source-line"> <span class="syn_comment" >// Nuke the context.</span> </code> </div> <div role="row" id="line-63" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="1903289616743ec0626e9a456c52926ad8257bad#%#62" role="button" aria-label="new hash 11" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="63"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> canvasWidth = (<span class="syn_reserved" >this</span>.canvas.width = Math.max( </code> </div> <div role="row" id="line-64" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="1903289616743ec0626e9a456c52926ad8257bad#%#63" role="button" aria-label="same hash 11" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="64"></div> <code role="cell" class="source-line"> state.waterfallWidth - REQUESTS_WATERFALL.LABEL_WIDTH, </code> </div> <div role="row" id="line-65" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="1903289616743ec0626e9a456c52926ad8257bad#%#64" role="button" aria-label="same hash 11" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="65"></div> <code role="cell" class="source-line"> 1 </code> </div> <div role="row" id="line-66" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="1903289616743ec0626e9a456c52926ad8257bad#%#65" role="button" aria-label="same hash 11" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="66"></div> <code role="cell" class="source-line"> )); </code> </div> <div role="row" id="line-67" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#55" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="67"></div> <code role="cell" class="source-line"> <span class="syn_comment" >// Awww yeah, 1px, repeats on Y axis.</span> </code> </div> <div role="row" id="line-68" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="f6db0ee55782a171ce893389645b7ec1473bc6a6#%#63" role="button" aria-label="new hash 9" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="68"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> canvasHeight = (<span class="syn_reserved" >this</span>.canvas.height = 1); </code> </div> <div role="row" id="line-69" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#57" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="69"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-70" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#58" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="70"></div> <code role="cell" class="source-line"> <span class="syn_comment" >// Start over.</span> </code> </div> <div role="row" id="line-71" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="640fe52298335597260c4708fb754d6d899feeda#%#64" role="button" aria-label="new hash 12" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="71"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> imageData = <span class="syn_reserved" >this</span>.ctx.createImageData(canvasWidth, canvasHeight); </code> </div> <div role="row" id="line-72" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="640fe52298335597260c4708fb754d6d899feeda#%#65" role="button" aria-label="same hash 12" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="72"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> pixelArray = imageData.data; </code> </div> <div role="row" id="line-73" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#61" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="73"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-74" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="640fe52298335597260c4708fb754d6d899feeda#%#67" role="button" aria-label="new hash 12" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="74"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> buf = <span class="syn_reserved" >new</span> ArrayBuffer(pixelArray.length); </code> </div> <div role="row" id="line-75" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="640fe52298335597260c4708fb754d6d899feeda#%#68" role="button" aria-label="same hash 12" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="75"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> view8bit = <span class="syn_reserved" >new</span> Uint8ClampedArray(buf); </code> </div> <div role="row" id="line-76" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="640fe52298335597260c4708fb754d6d899feeda#%#69" role="button" aria-label="same hash 12" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="76"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> view32bit = <span class="syn_reserved" >new</span> Uint32Array(buf); </code> </div> <div role="row" id="line-77" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#65" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="77"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-78" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#66" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="78"></div> <code role="cell" class="source-line"> <span class="syn_comment" >// Build new millisecond tick lines...</span> </code> </div> <div role="row" id="line-79" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="ee77eda75ce0722dc212e96f2311e125496341c2#devtools/client/netmonitor/src/waterfall-background.js#70" role="button" aria-label="new hash 5" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="79"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >let</span> timingStep = REQUESTS_WATERFALL.BACKGROUND_TICKS_MULTIPLE; </code> </div> <div role="row" id="line-80" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#68" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="80"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >let</span> optimalTickIntervalFound = <span class="syn_reserved" >false</span>; </code> </div> <div role="row" id="line-81" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#69" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="81"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >let</span> scaledStep; </code> </div> <div role="row" id="line-82" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#70" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="82"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-83" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#71" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="83"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >while</span> (!optimalTickIntervalFound) { </code> </div> <div role="row" id="line-84" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#72" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="84"></div> <code role="cell" class="source-line"> <span class="syn_comment" >// Ignore any divisions that would end up being too close to each other.</span> </code> </div> <div role="row" id="line-85" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#73" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="85"></div> <code role="cell" class="source-line"> scaledStep = state.scale * timingStep; </code> </div> <div role="row" id="line-86" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="ee77eda75ce0722dc212e96f2311e125496341c2#devtools/client/netmonitor/src/waterfall-background.js#77" role="button" aria-label="new hash 5" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="86"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >if</span> (scaledStep < REQUESTS_WATERFALL.BACKGROUND_TICKS_SPACING_MIN) { </code> </div> <div role="row" id="line-87" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#75" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="87"></div> <code role="cell" class="source-line"> timingStep <<= 1; </code> </div> <div role="row" id="line-88" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#76" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="88"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >continue</span>; </code> </div> <div role="row" id="line-89" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#77" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="89"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-90" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#78" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="90"></div> <code role="cell" class="source-line"> optimalTickIntervalFound = <span class="syn_reserved" >true</span>; </code> </div> <div role="row" id="line-91" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#79" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="91"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-92" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#80" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="92"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-93" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="30e8f95fb90c67578dfb20690884d17d5281ecec#%#86" role="button" aria-label="new hash 13" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="93"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> isRTL = document.dir === <span class="syn_string" >"rtl"</span>; </code> </div> <div role="row" id="line-94" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="ee77eda75ce0722dc212e96f2311e125496341c2#devtools/client/netmonitor/src/waterfall-background.js#85" role="button" aria-label="new hash 5" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="94"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> [r, g, b] = REQUESTS_WATERFALL.BACKGROUND_TICKS_COLOR_RGB; </code> </div> <div role="row" id="line-95" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="ee77eda75ce0722dc212e96f2311e125496341c2#devtools/client/netmonitor/src/waterfall-background.js#86" role="button" aria-label="same hash 5" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="95"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >let</span> alphaComponent = REQUESTS_WATERFALL.BACKGROUND_TICKS_OPACITY_MIN; </code> </div> <div role="row" id="line-96" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#84" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="96"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-97" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#85" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="97"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >function</span> drawPixelAt(offset, color) { </code> </div> <div role="row" id="line-98" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="640fe52298335597260c4708fb754d6d899feeda#%#91" role="button" aria-label="new hash 12" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="98"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> position = (isRTL ? canvasWidth - offset : offset - 1) | 0; </code> </div> <div role="row" id="line-99" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="640fe52298335597260c4708fb754d6d899feeda#%#92" role="button" aria-label="same hash 12" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="99"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> [rc, gc, bc, ac] = color; </code> </div> <div role="row" id="line-100" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#88" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="100"></div> <code role="cell" class="source-line"> view32bit[position] = (ac << 24) | (bc << 16) | (gc << 8) | rc; </code> </div> <div role="row" id="line-101" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#89" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="101"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-102" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#90" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="102"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-103" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#91" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="103"></div> <code role="cell" class="source-line"> <span class="syn_comment" >// Insert one pixel for each division on each scale.</span> </code> </div> <div role="row" id="line-104" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="ee77eda75ce0722dc212e96f2311e125496341c2#devtools/client/netmonitor/src/waterfall-background.js#95" role="button" aria-label="new hash 5" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="104"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >for</span> (<span class="syn_reserved" >let</span> i = 1; i <= REQUESTS_WATERFALL.BACKGROUND_TICKS_SCALES; i++) { </code> </div> <div role="row" id="line-105" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="640fe52298335597260c4708fb754d6d899feeda#%#98" role="button" aria-label="new hash 12" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="105"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> increment = scaledStep * Math.pow(2, i); </code> </div> <div role="row" id="line-106" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#94" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="106"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >for</span> (<span class="syn_reserved" >let</span> x = 0; x < canvasWidth; x += increment) { </code> </div> <div role="row" id="line-107" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#95" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="107"></div> <code role="cell" class="source-line"> drawPixelAt(x, [r, g, b, alphaComponent]); </code> </div> <div role="row" id="line-108" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#96" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="108"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-109" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="ee77eda75ce0722dc212e96f2311e125496341c2#devtools/client/netmonitor/src/waterfall-background.js#100" role="button" aria-label="new hash 5" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="109"></div> <code role="cell" class="source-line"> alphaComponent += REQUESTS_WATERFALL.BACKGROUND_TICKS_OPACITY_ADD; </code> </div> <div role="row" id="line-110" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#98" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="110"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-111" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#99" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="111"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-112" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#100" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="112"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >function</span> drawTimestamp(timestamp, color) { </code> </div> <div role="row" id="line-113" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="876f7acea147ad2f11e67349565857c5972231c2#devtools/client/netmonitor/waterfall-background.js#100" role="button" aria-label="new hash 10" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="113"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >if</span> (timestamp === -1) { </code> </div> <div role="row" id="line-114" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#102" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="114"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >return</span>; </code> </div> <div role="row" id="line-115" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#103" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="115"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-116" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#104" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="116"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-117" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="f6db0ee55782a171ce893389645b7ec1473bc6a6#%#112" role="button" aria-label="new hash 9" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="117"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> delta = Math.floor( </code> </div> <div role="row" id="line-118" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="2ae57e4ad5517396aa7023766e7f31b61812741f#%#113" role="button" aria-label="new hash 6" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="118"></div> <code role="cell" class="source-line"> (timestamp - state.firstRequestStartedMs) * state.scale </code> </div> <div role="row" id="line-119" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="f6db0ee55782a171ce893389645b7ec1473bc6a6#%#114" role="button" aria-label="new hash 9" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="119"></div> <code role="cell" class="source-line"> ); </code> </div> <div role="row" id="line-120" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#106" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="120"></div> <code role="cell" class="source-line"> drawPixelAt(delta, color); </code> </div> <div role="row" id="line-121" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#107" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="121"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-122" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#108" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="122"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-123" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="130a65590610eed581600b0e262e005cdf24a85f#%#122" role="button" aria-label="new hash 14" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="123"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> { DOMCONTENTLOADED_TICKS_COLOR, LOAD_TICKS_COLOR } = </code> </div> <div role="row" id="line-124" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="130a65590610eed581600b0e262e005cdf24a85f#%#123" role="button" aria-label="same hash 14" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="124"></div> <code role="cell" class="source-line"> REQUESTS_WATERFALL; </code> </div> <div role="row" id="line-125" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="f6db0ee55782a171ce893389645b7ec1473bc6a6#%#122" role="button" aria-label="new hash 9" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="125"></div> <code role="cell" class="source-line"> drawTimestamp( </code> </div> <div role="row" id="line-126" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="f6db0ee55782a171ce893389645b7ec1473bc6a6#%#123" role="button" aria-label="same hash 9" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="126"></div> <code role="cell" class="source-line"> state.timingMarkers.firstDocumentDOMContentLoadedTimestamp, </code> </div> <div role="row" id="line-127" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="91ed615c4810470c470a99794218275db735e90b#%#128" role="button" aria-label="new hash 2" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="127"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >this</span>.getThemeColorAsRgba(DOMCONTENTLOADED_TICKS_COLOR) </code> </div> <div role="row" id="line-128" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="f6db0ee55782a171ce893389645b7ec1473bc6a6#%#125" role="button" aria-label="new hash 9" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="128"></div> <code role="cell" class="source-line"> ); </code> </div> <div role="row" id="line-129" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="f6db0ee55782a171ce893389645b7ec1473bc6a6#%#126" role="button" aria-label="same hash 9" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="129"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-130" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="f6db0ee55782a171ce893389645b7ec1473bc6a6#%#127" role="button" aria-label="same hash 9" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="130"></div> <code role="cell" class="source-line"> drawTimestamp( </code> </div> <div role="row" id="line-131" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="f6db0ee55782a171ce893389645b7ec1473bc6a6#%#128" role="button" aria-label="same hash 9" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="131"></div> <code role="cell" class="source-line"> state.timingMarkers.firstDocumentLoadTimestamp, </code> </div> <div role="row" id="line-132" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="91ed615c4810470c470a99794218275db735e90b#%#133" role="button" aria-label="new hash 2" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="132"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >this</span>.getThemeColorAsRgba(LOAD_TICKS_COLOR) </code> </div> <div role="row" id="line-133" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="f6db0ee55782a171ce893389645b7ec1473bc6a6#%#130" role="button" aria-label="new hash 9" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="133"></div> <code role="cell" class="source-line"> ); </code> </div> <div role="row" id="line-134" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#114" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="134"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-135" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#115" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="135"></div> <code role="cell" class="source-line"> <span class="syn_comment" >// Flush the image data and cache the waterfall background.</span> </code> </div> <div role="row" id="line-136" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#116" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="136"></div> <code role="cell" class="source-line"> pixelArray.<span class="syn_reserved" >set</span>(view8bit); </code> </div> <div role="row" id="line-137" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="991d7c1b6fd96e8cab88267c277ed7ab49af7a02#%#136" role="button" aria-label="new hash 15" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="137"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >try</span> { </code> </div> <div role="row" id="line-138" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="991d7c1b6fd96e8cab88267c277ed7ab49af7a02#%#137" role="button" aria-label="same hash 15" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="138"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >this</span>.ctx.putImageData(imageData, 0, 0); </code> </div> <div role="row" id="line-139" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="991d7c1b6fd96e8cab88267c277ed7ab49af7a02#%#138" role="button" aria-label="same hash 15" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="139"></div> <code role="cell" class="source-line"> } <span class="syn_reserved" >catch</span> (e) { </code> </div> <div role="row" id="line-140" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="991d7c1b6fd96e8cab88267c277ed7ab49af7a02#%#139" role="button" aria-label="same hash 15" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="140"></div> <code role="cell" class="source-line"> console.error(<span class="syn_string" >"WaterfallBackground crash error"</span>, e); </code> </div> <div role="row" id="line-141" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="991d7c1b6fd96e8cab88267c277ed7ab49af7a02#%#140" role="button" aria-label="same hash 15" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="141"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-142" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#118" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="142"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-143" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#126" role="button" aria-label="new hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="143"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >this</span>.setImageElement(<span class="syn_string" >"waterfall-background"</span>, <span class="syn_reserved" >this</span>.canvas); </code> </div> <div role="row" id="line-144" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#127" role="button" aria-label="same hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="144"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-145" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#121" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="145"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-146" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="b9d70cdb70e819d688de0a1b22459c4285dcb7de#devtools/client/netmonitor/src/waterfall-background.js#128" role="button" aria-label="new hash 16" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="146"></div> <code role="cell" class="source-line"> <span class="syn_comment" >/**</span> </code> </div> <div role="row" id="line-147" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="d50ad0d9fd39eaed6e794e8c94ccaae9862e896f#%#147" role="button" aria-label="new hash 17" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="147"></div> <code role="cell" class="source-line"><span class="syn_comment" > * Retrieve a color defined for the provided theme as a rgba array.</span> </code> </div> <div role="row" id="line-148" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="b9d70cdb70e819d688de0a1b22459c4285dcb7de#devtools/client/netmonitor/src/waterfall-background.js#131" role="button" aria-label="new hash 16" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="148"></div> <code role="cell" class="source-line"><span class="syn_comment" > *</span> </code> </div> <div role="row" id="line-149" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="91ed615c4810470c470a99794218275db735e90b#%#151" role="button" aria-label="new hash 2" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="149"></div> <code role="cell" class="source-line"><span class="syn_comment" > * @param {String} colorVariableName</span> </code> </div> <div role="row" id="line-150" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="91ed615c4810470c470a99794218275db735e90b#%#152" role="button" aria-label="same hash 2" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="150"></div> <code role="cell" class="source-line"><span class="syn_comment" > * The name of the variable defining the color</span> </code> </div> <div role="row" id="line-151" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="b9d70cdb70e819d688de0a1b22459c4285dcb7de#devtools/client/netmonitor/src/waterfall-background.js#136" role="button" aria-label="new hash 16" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="151"></div> <code role="cell" class="source-line"><span class="syn_comment" > * @return {Array} RGBA array for the color.</span> </code> </div> <div role="row" id="line-152" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="b9d70cdb70e819d688de0a1b22459c4285dcb7de#devtools/client/netmonitor/src/waterfall-background.js#137" role="button" aria-label="same hash 16" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="152"></div> <code role="cell" class="source-line"><span class="syn_comment" > */</span> </code> </div> <div role="row" id="line-153" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="91ed615c4810470c470a99794218275db735e90b#%#155" role="button" aria-label="new hash 2" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="153"></div> <code role="cell" class="source-line"> getThemeColorAsRgba(colorVariableName) { </code> </div> <div role="row" id="line-154" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="91ed615c4810470c470a99794218275db735e90b#%#156" role="button" aria-label="same hash 2" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="154"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> colorStr = getCssVariableColor( </code> </div> <div role="row" id="line-155" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="91ed615c4810470c470a99794218275db735e90b#%#157" role="button" aria-label="same hash 2" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="155"></div> <code role="cell" class="source-line"> colorVariableName, </code> </div> <div role="row" id="line-156" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="91ed615c4810470c470a99794218275db735e90b#%#158" role="button" aria-label="same hash 2" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="156"></div> <code role="cell" class="source-line"> document.ownerGlobal </code> </div> <div role="row" id="line-157" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="91ed615c4810470c470a99794218275db735e90b#%#159" role="button" aria-label="same hash 2" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="157"></div> <code role="cell" class="source-line"> ); </code> </div> <div role="row" id="line-158" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="6c3ef8a9a42e954aedf5884ed59a18de6687c6bf#%#158" role="button" aria-label="new hash 18" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="158"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >const</span> { r, g, b, a } = InspectorUtils.colorToRGBA(colorStr, document); </code> </div> <div role="row" id="line-159" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="d50ad0d9fd39eaed6e794e8c94ccaae9862e896f#%#159" role="button" aria-label="new hash 17" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="159"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >return</span> [r, g, b, a * 255]; </code> </div> <div role="row" id="line-160" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#144" role="button" aria-label="new hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="160"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-161" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="b9d70cdb70e819d688de0a1b22459c4285dcb7de#devtools/client/netmonitor/src/waterfall-background.js#144" role="button" aria-label="new hash 16" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="161"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-162" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#122" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="162"></div> <code role="cell" class="source-line"> destroy() { </code> </div> <div role="row" id="line-163" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c1" data-blame="e345a4990ae707f6844be143000f7b0db9e53143#%#147" role="button" aria-label="new hash 7" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="163"></div> <code role="cell" class="source-line"> <span class="syn_reserved" >this</span>.setImageElement(<span class="syn_string" >"waterfall-background"</span>, <span class="syn_reserved" >null</span>); </code> </div> <div role="row" id="line-164" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#124" role="button" aria-label="new hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="164"></div> <code role="cell" class="source-line"> } </code> </div> <div role="row" id="line-165" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#133" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="165"></div> <code role="cell" class="source-line">} </code> </div> <div role="row" id="line-166" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#134" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="166"></div> <code role="cell" class="source-line"> </code> </div> <div role="row" id="line-167" class="source-line-with-number"> <div role="cell"><div class="cov-strip cov-no-data"></div></div> <div role="cell"><div class="blame-strip c2" data-blame="e778ffb693ac698767e66509d2f04d5040a05982#devtools/client/netmonitor/waterfall-background.js#135" role="button" aria-label="same hash 1" aria-expanded="false"></div></div> <div role="cell" class="line-number" data-line-number="167"></div> <code role="cell" class="source-line">module.exports = WaterfallBackground; </code> </div> </div> <script>var SYM_INFO = {};</script> </div> <div id="foot" class="footer"> This page was generated by Searchfox <span class="pretty-date" data-datetime="Sat, 23 Nov 2024 22:42:55 +0000"></span>. </div> <span id="data" data-root="/" data-search="/mozilla-central/search" data-tree="mozilla-central" data-path="devtools/client/netmonitor/src/widgets/WaterfallBackground.js"></span> <script src="/tree-list.js"></script> <script src="/mozilla-central/static/js/settings.js"></script> <script src="/mozilla-central/static/js/search.js"></script> <script src="/mozilla-central/static/js/context-menu.js"></script> <script src="/mozilla-central/static/js/panel.js"></script> <script src="/mozilla-central/static/js/code-highlighter.js"></script> <script src="/mozilla-central/static/js/blame.js"></script> </div> </body> </html>