Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(392)

Side by Side Diff: Source/devtools/front_end/ui_lazy/TimelineOverviewPane.js

Issue 1295523003: DevTools: do not use arrow functions unless they are in stable. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/devtools/front_end/ui/KeyboardShortcut.js ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 } 134 }
135 }, 135 },
136 136
137 /** 137 /**
138 * @return {!Promise<!DocumentFragment>} 138 * @return {!Promise<!DocumentFragment>}
139 */ 139 */
140 _buildPopoverContents: function() 140 _buildPopoverContents: function()
141 { 141 {
142 var document = this.element.ownerDocument; 142 var document = this.element.ownerDocument;
143 var x = this._cursorPosition; 143 var x = this._cursorPosition;
144 var promises = this._overviewControls.map(control => control.popoverElem entPromise(x)); 144 var promises = this._overviewControls.map(mapToPopover);
145
146 /**
147 * @param {!WebInspector.TimelineOverview} control
148 * @return {!Promise<?Element>}
149 */
150 function mapToPopover(control)
151 {
152 return control.popoverElementPromise(x)
153 }
154
145 return Promise.all(promises).then(buildFragment); 155 return Promise.all(promises).then(buildFragment);
146 156
147 /** 157 /**
148 * @param {!Array<?Element>} elements 158 * @param {!Array<?Element>} elements
149 * @return {!DocumentFragment} 159 * @return {!DocumentFragment}
150 */ 160 */
151 function buildFragment(elements) 161 function buildFragment(elements)
152 { 162 {
153 var fragment = document.createDocumentFragment(); 163 var fragment = document.createDocumentFragment();
154 elements.remove(null); 164 elements.remove(null);
(...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after
622 }, 632 },
623 633
624 resetCanvas: function() 634 resetCanvas: function()
625 { 635 {
626 this._canvas.width = this.element.clientWidth * window.devicePixelRatio; 636 this._canvas.width = this.element.clientWidth * window.devicePixelRatio;
627 this._canvas.height = this.element.clientHeight * window.devicePixelRati o; 637 this._canvas.height = this.element.clientHeight * window.devicePixelRati o;
628 }, 638 },
629 639
630 __proto__: WebInspector.VBox.prototype 640 __proto__: WebInspector.VBox.prototype
631 } 641 }
OLDNEW
« no previous file with comments | « Source/devtools/front_end/ui/KeyboardShortcut.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698