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

Side by Side Diff: Source/devtools/front_end/layers/LayerPaintProfilerView.js

Issue 1163223003: DevTools: better error handling in paint profiler UI (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | Source/devtools/front_end/timeline/PaintProfilerView.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 /** 5 /**
6 * @constructor 6 * @constructor
7 * @param {function(!WebInspector.Layer, string=)} showImageForLayerCallback 7 * @param {function(!WebInspector.Layer, string=)} showImageForLayerCallback
8 * @extends {WebInspector.SplitWidget} 8 * @extends {WebInspector.SplitWidget}
9 */ 9 */
10 WebInspector.LayerPaintProfilerView = function(showImageForLayerCallback) 10 WebInspector.LayerPaintProfilerView = function(showImageForLayerCallback)
(...skipping 29 matching lines...) Expand all
40 snapshot.commandLog(onCommandLogDone.bind(this, snapshot)); 40 snapshot.commandLog(onCommandLogDone.bind(this, snapshot));
41 } 41 }
42 42
43 /** 43 /**
44 * @param {!WebInspector.PaintProfilerSnapshot=} snapshot 44 * @param {!WebInspector.PaintProfilerSnapshot=} snapshot
45 * @param {!Array.<!Object>=} log 45 * @param {!Array.<!Object>=} log
46 * @this {WebInspector.LayerPaintProfilerView} 46 * @this {WebInspector.LayerPaintProfilerView}
47 */ 47 */
48 function onCommandLogDone(snapshot, log) 48 function onCommandLogDone(snapshot, log)
49 { 49 {
50 this._logTreeView.setCommandLog(snapshot.target(), log); 50 this._logTreeView.setCommandLog(snapshot.target(), log || []);
51 this._paintProfilerView.setSnapshotAndLog(snapshot || null, log || [ ], null); 51 this._paintProfilerView.setSnapshotAndLog(snapshot || null, log || [ ], null);
52 } 52 }
53 }, 53 },
54 54
55 _onWindowChanged: function() 55 _onWindowChanged: function()
56 { 56 {
57 var window = this._paintProfilerView.windowBoundaries(); 57 var window = this._paintProfilerView.windowBoundaries();
58 this._logTreeView.updateWindow(window.left, window.right); 58 this._logTreeView.updateWindow(window.left, window.right);
59 }, 59 },
60 60
61 /** 61 /**
62 * @param {string=} imageURL 62 * @param {string=} imageURL
63 */ 63 */
64 _showImage: function(imageURL) 64 _showImage: function(imageURL)
65 { 65 {
66 this._showImageForLayerCallback(this._layer, imageURL); 66 this._showImageForLayerCallback(this._layer, imageURL);
67 }, 67 },
68 68
69 __proto__: WebInspector.SplitWidget.prototype 69 __proto__: WebInspector.SplitWidget.prototype
70 }; 70 };
71 71
OLDNEW
« no previous file with comments | « no previous file | Source/devtools/front_end/timeline/PaintProfilerView.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698