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

Unified Diff: lib/src/iron-list/test/helpers.html

Issue 1418513006: update elements and fix some bugs (Closed) Base URL: git@github.com:dart-lang/polymer_elements.git@master
Patch Set: code review updates Created 5 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
« no previous file with comments | « lib/src/iron-list/test/dynamic-item-size.html ('k') | lib/src/iron-list/test/hidden-list.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/src/iron-list/test/helpers.html
diff --git a/lib/src/iron-list/test/helpers.html b/lib/src/iron-list/test/helpers.html
index eaa43ce05c71a5f824efd7ae096436a7b1c09456..07f240020d25ee91320fee210c3cd4949cc3e734 100644
--- a/lib/src/iron-list/test/helpers.html
+++ b/lib/src/iron-list/test/helpers.html
@@ -72,4 +72,23 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
var listRect = list.getBoundingClientRect();
return document.elementFromPoint(listRect.left + 1, listRect.top + listRect.height - 1);
}
+
+ function isFullOfItems(list) {
+ var listRect = list.getBoundingClientRect();
+ var listHeight = listRect.height - 1;
+ var item, y = listRect.top + 1;
+ // IE 10 & 11 doesn't render propertly :(
+ var badPixels = 0;
+ while (y < listHeight) {
+ item = document.elementFromPoint(listRect.left + 1, y);
+ if (item.parentNode && !item.parentNode._templateInstance) {
+ badPixels++;
+ }
+ if (badPixels > 3) {
+ return false;
+ }
+ y += 2;
+ }
+ return true;
+ }
</script>
« no previous file with comments | « lib/src/iron-list/test/dynamic-item-size.html ('k') | lib/src/iron-list/test/hidden-list.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698