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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/ui_lazy/FlameChart.js

Issue 2466123002: DevTools: reformat front-end code to match chromium style. (Closed)
Patch Set: Created 4 years, 1 month 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
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 536 matching lines...) Expand 10 before | Expand all | Expand 10 after
547 } 547 }
548 }, 548 },
549 549
550 /** 550 /**
551 * @override 551 * @override
552 * @param {number} startTime 552 * @param {number} startTime
553 * @param {number} endTime 553 * @param {number} endTime
554 */ 554 */
555 setWindowTimes: function(startTime, endTime) 555 setWindowTimes: function(startTime, endTime)
556 { 556 {
557 WebInspector.FlameChart.prototype.__proto__.setWindowTimes.call(this, st artTime, endTime); 557 WebInspector.ChartViewport.prototype.setWindowTimes.call(this, startTime , endTime);
558 this._updateHighlight(); 558 this._updateHighlight();
559 }, 559 },
560 560
561 /** 561 /**
562 * @param {!Event} event 562 * @param {!Event} event
563 */ 563 */
564 _onMouseMove: function(event) 564 _onMouseMove: function(event)
565 { 565 {
566 this._lastMouseOffsetX = event.offsetX; 566 this._lastMouseOffsetX = event.offsetX;
567 this._lastMouseOffsetY = event.offsetY; 567 this._lastMouseOffsetY = event.offsetY;
(...skipping 1050 matching lines...) Expand 10 before | Expand all | Expand 10 after
1618 { 1618 {
1619 var height = this._levelToHeight(this._dataProvider.maxStackDepth()); 1619 var height = this._levelToHeight(this._dataProvider.maxStackDepth());
1620 this.setContentHeight(height); 1620 this.setContentHeight(height);
1621 }, 1621 },
1622 1622
1623 /** 1623 /**
1624 * @override 1624 * @override
1625 */ 1625 */
1626 onResize: function() 1626 onResize: function()
1627 { 1627 {
1628 WebInspector.FlameChart.prototype.__proto__.onResize.call(this); 1628 WebInspector.ChartViewport.prototype.onResize.call(this);
1629 this.scheduleUpdate(); 1629 this.scheduleUpdate();
1630 }, 1630 },
1631 1631
1632 /** 1632 /**
1633 * @override 1633 * @override
1634 */ 1634 */
1635 update: function() 1635 update: function()
1636 { 1636 {
1637 if (!this._timelineData()) 1637 if (!this._timelineData())
1638 return; 1638 return;
1639 this._resetCanvas(); 1639 this._resetCanvas();
1640 this._updateHeight(); 1640 this._updateHeight();
1641 this._updateBoundaries(); 1641 this._updateBoundaries();
1642 this._calculator._updateBoundaries(this); 1642 this._calculator._updateBoundaries(this);
1643 this._draw(this._offsetWidth, this._offsetHeight); 1643 this._draw(this._offsetWidth, this._offsetHeight);
1644 if (!this.isDragging()) 1644 if (!this.isDragging())
1645 this._updateHighlight(); 1645 this._updateHighlight();
1646 }, 1646 },
1647 1647
1648 /**
1649 * @override
1650 */
1648 reset: function() 1651 reset: function()
1649 { 1652 {
1650 WebInspector.FlameChart.prototype.__proto__.reset.call(this); 1653 WebInspector.ChartViewport.prototype.reset.call(this);
1651 this._highlightedMarkerIndex = -1; 1654 this._highlightedMarkerIndex = -1;
1652 this._highlightedEntryIndex = -1; 1655 this._highlightedEntryIndex = -1;
1653 this._selectedEntryIndex = -1; 1656 this._selectedEntryIndex = -1;
1654 /** @type {!Map<string,!Map<string,number>>} */ 1657 /** @type {!Map<string,!Map<string,number>>} */
1655 this._textWidth = new Map(); 1658 this._textWidth = new Map();
1656 this.update(); 1659 this.update();
1657 }, 1660 },
1658 1661
1659 _enabled: function() 1662 _enabled: function()
1660 { 1663 {
1661 return this._rawTimelineDataLength !== 0; 1664 return this._rawTimelineDataLength !== 0;
1662 }, 1665 },
1663 1666
1664 __proto__: WebInspector.ChartViewport.prototype 1667 __proto__: WebInspector.ChartViewport.prototype
1665 }; 1668 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698