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

Side by Side Diff: Source/devtools/front_end/timeline/TimelinePanel.js

Issue 1305373004: DevTools: move session logic from TracingModel to TimelineModel (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: review comments addressed Created 5 years, 3 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/timeline/TimelineModel.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) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * Copyright (C) 2012 Intel Inc. All rights reserved. 3 * Copyright (C) 2012 Intel Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 this._overviewPane.requestWindowTimes(windowStartTime, windowEndTime); 235 this._overviewPane.requestWindowTimes(windowStartTime, windowEndTime);
236 }, 236 },
237 237
238 /** 238 /**
239 * @return {!WebInspector.TimelineFrameModelBase} 239 * @return {!WebInspector.TimelineFrameModelBase}
240 */ 240 */
241 _frameModel: function() 241 _frameModel: function()
242 { 242 {
243 if (!this._lazyFrameModel) { 243 if (!this._lazyFrameModel) {
244 var tracingFrameModel = new WebInspector.TracingTimelineFrameModel() ; 244 var tracingFrameModel = new WebInspector.TracingTimelineFrameModel() ;
245 tracingFrameModel.addTraceEvents(this._model.target(), this._model.i nspectedTargetEvents(), this._tracingModel.sessionId() || ""); 245 tracingFrameModel.addTraceEvents(this._model.target(), this._model.i nspectedTargetEvents(), this._model.sessionId() || "");
246 this._lazyFrameModel = tracingFrameModel; 246 this._lazyFrameModel = tracingFrameModel;
247 } 247 }
248 return this._lazyFrameModel; 248 return this._lazyFrameModel;
249 }, 249 },
250 250
251 /** 251 /**
252 * @return {!WebInspector.Widget} 252 * @return {!WebInspector.Widget}
253 */ 253 */
254 _layersView: function() 254 _layersView: function()
255 { 255 {
(...skipping 593 matching lines...) Expand 10 before | Expand all | Expand 10 after
849 this._helpMessageElement.remove(); 849 this._helpMessageElement.remove();
850 delete this._helpMessageElement; 850 delete this._helpMessageElement;
851 }, 851 },
852 852
853 _onRecordingStopped: function() 853 _onRecordingStopped: function()
854 { 854 {
855 this._stopPending = false; 855 this._stopPending = false;
856 this._updateToggleTimelineButton(false); 856 this._updateToggleTimelineButton(false);
857 if (this._lazyFrameModel) { 857 if (this._lazyFrameModel) {
858 this._lazyFrameModel.reset(); 858 this._lazyFrameModel.reset();
859 this._lazyFrameModel.addTraceEvents(this._model.target(), this._mode l.inspectedTargetEvents(), this._tracingModel.sessionId()); 859 this._lazyFrameModel.addTraceEvents(this._model.target(), this._mode l.inspectedTargetEvents(), this._model.sessionId());
860 } 860 }
861 this._overviewPane.reset(); 861 this._overviewPane.reset();
862 this._overviewPane.setBounds(this._model.minimumRecordTime(), this._mode l.maximumRecordTime()); 862 this._overviewPane.setBounds(this._model.minimumRecordTime(), this._mode l.maximumRecordTime());
863 this.requestWindowTimes(this._model.minimumRecordTime(), this._model.max imumRecordTime()); 863 this.requestWindowTimes(this._model.minimumRecordTime(), this._model.max imumRecordTime());
864 this._refreshViews(); 864 this._refreshViews();
865 for (var i = 0; i < this._overviewControls.length; ++i) 865 for (var i = 0; i < this._overviewControls.length; ++i)
866 this._overviewControls[i].timelineStopped(); 866 this._overviewControls[i].timelineStopped();
867 this._setMarkers(); 867 this._setMarkers();
868 this._overviewPane.scheduleUpdate(); 868 this._overviewPane.scheduleUpdate();
869 this._updateSearchHighlight(false, true); 869 this._updateSearchHighlight(false, true);
(...skipping 1054 matching lines...) Expand 10 before | Expand all | Expand 10 after
1924 * @param {!WebInspector.Context} context 1924 * @param {!WebInspector.Context} context
1925 * @param {string} actionId 1925 * @param {string} actionId
1926 */ 1926 */
1927 handleAction: function(context, actionId) 1927 handleAction: function(context, actionId)
1928 { 1928 {
1929 var panel = WebInspector.context.flavor(WebInspector.TimelinePanel); 1929 var panel = WebInspector.context.flavor(WebInspector.TimelinePanel);
1930 console.assert(panel && panel instanceof WebInspector.TimelinePanel); 1930 console.assert(panel && panel instanceof WebInspector.TimelinePanel);
1931 panel._toggleTimelineButtonClicked(); 1931 panel._toggleTimelineButtonClicked();
1932 } 1932 }
1933 } 1933 }
OLDNEW
« no previous file with comments | « Source/devtools/front_end/timeline/TimelineModel.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698