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

Unified Diff: third_party/WebKit/Source/devtools/front_end/ui_lazy/ViewportDataGrid.js

Issue 1821803003: DevTools: update ViewportDataGrid resizers when scrollbar visibility changes (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/devtools/front_end/ui_lazy/ViewportDataGrid.js
diff --git a/third_party/WebKit/Source/devtools/front_end/ui_lazy/ViewportDataGrid.js b/third_party/WebKit/Source/devtools/front_end/ui_lazy/ViewportDataGrid.js
index 222d7762ab96ea067766c1d23bdfd214e2faa279..c1ca48c7a456deb43e5bfc3996f0df2d1bb20d3e 100644
--- a/third_party/WebKit/Source/devtools/front_end/ui_lazy/ViewportDataGrid.js
+++ b/third_party/WebKit/Source/devtools/front_end/ui_lazy/ViewportDataGrid.js
@@ -237,11 +237,14 @@ WebInspector.ViewportDataGrid.prototype = {
}
this.setVerticalPadding(viewportState.topPadding, viewportState.bottomPadding);
- var contentFits = viewportState.contentHeight <= clientHeight;
- this.element.classList.toggle("data-grid-fits-viewport", contentFits && viewportState.topPadding + viewportState.bottomPadding === 0);
this._lastScrollTop = scrollTop;
if (scrollTop !== currentScrollTop)
this._scrollContainer.scrollTop = scrollTop;
+ var contentFits = viewportState.contentHeight <= clientHeight && viewportState.topPadding + viewportState.bottomPadding === 0;
+ if (contentFits !== this.element.classList.contains("data-grid-fits-viewport")) {
+ this.element.classList.toggle("data-grid-fits-viewport", contentFits);
+ this.updateWidths();
+ }
this._visibleNodes = visibleNodes;
},
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698