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

Unified Diff: third_party/WebKit/Source/devtools/front_end/network/NetworkPanel.js

Issue 2400093002: [Devtools] New network timeline experiment Part 1 (Closed)
Patch Set: [Devtools] New network timeline experirement Part 1 Created 4 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/devtools/front_end/network/NetworkPanel.js
diff --git a/third_party/WebKit/Source/devtools/front_end/network/NetworkPanel.js b/third_party/WebKit/Source/devtools/front_end/network/NetworkPanel.js
index aff3f1680709c7144d4c71fd072c41a4888a4eb2..66f2184c16559358beffeb37c2b54b4fe88477bb 100644
--- a/third_party/WebKit/Source/devtools/front_end/network/NetworkPanel.js
+++ b/third_party/WebKit/Source/devtools/front_end/network/NetworkPanel.js
@@ -412,6 +412,11 @@ WebInspector.NetworkPanel.prototype = {
*/
_showRequest: function(request)
{
+ if (Runtime.experiments.isEnabled("networkCanvasTimeline")) {
+ var lastSideBarSize = this._previousSideBarWidth || this._splitWidget.sidebarSize();
dgozman 2016/10/07 21:39:57 I don't get why we need this.
allada 2016/10/08 00:13:32 Done.
+ this._previousSideBarWidth = this._splitWidget.sidebarSize();
+ }
+
if (this._networkItemView) {
this._networkItemView.detach();
this._networkItemView = null;
@@ -419,6 +424,10 @@ WebInspector.NetworkPanel.prototype = {
if (request) {
this._networkItemView = new WebInspector.NetworkItemView(request, this._networkLogView.timeCalculator());
+ if (Runtime.experiments.isEnabled("networkCanvasTimeline")) {
+ this._splitWidget.setMainWidget(this._detailsWidget);
+ this._splitWidget.setSidebarSize(lastSideBarSize);
+ }
this._networkItemView.leftToolbar().appendToolbarItem(new WebInspector.ToolbarItem(this._closeButtonElement));
this._networkItemView.show(this._detailsWidget.element);
this._splitWidget.showBoth();
@@ -432,7 +441,7 @@ WebInspector.NetworkPanel.prototype = {
_updateUI: function()
{
this._detailsWidget.element.classList.toggle("network-details-view-tall-header", this._networkLogLargeRowsSetting.get());
- this._networkLogView.switchViewMode(!this._splitWidget.isResizable());
+ this._networkLogView.switchViewMode(!this._networkItemView);
},
/**

Powered by Google App Engine
This is Rietveld 408576698