OLD | NEW |
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 1109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1120 currentOffset += style.height; | 1120 currentOffset += style.height; |
1121 } | 1121 } |
1122 var isFirstOnLevel = groupIndex >= 0 && level === groups[groupIndex].start
Level; | 1122 var isFirstOnLevel = groupIndex >= 0 && level === groups[groupIndex].start
Level; |
1123 var thisLevelIsVisible = | 1123 var thisLevelIsVisible = |
1124 parentGroupIsVisible && (visible || isFirstOnLevel && groups[groupInde
x].style.useFirstLineForOverview); | 1124 parentGroupIsVisible && (visible || isFirstOnLevel && groups[groupInde
x].style.useFirstLineForOverview); |
1125 if (level < levelCount) { | 1125 if (level < levelCount) { |
1126 var height; | 1126 var height; |
1127 if (groupIndex >= 0) { | 1127 if (groupIndex >= 0) { |
1128 var group = groups[groupIndex]; | 1128 var group = groups[groupIndex]; |
1129 var style = group.style; | 1129 var style = group.style; |
1130 height = isFirstOnLevel && !style.shareHeaderLine || !group.expanded ?
style.height : | 1130 height = isFirstOnLevel && !style.shareHeaderLine || (style.collapsibl
e && !group.expanded) ? |
1131
(style.itemsHeight || this._barHeight); | 1131 style.height : |
| 1132 (style.itemsHeight || this._barHeight); |
1132 } else { | 1133 } else { |
1133 height = this._barHeight; | 1134 height = this._barHeight; |
1134 } | 1135 } |
1135 this._visibleLevels[level] = thisLevelIsVisible; | 1136 this._visibleLevels[level] = thisLevelIsVisible; |
1136 this._visibleLevelOffsets[level] = currentOffset; | 1137 this._visibleLevelOffsets[level] = currentOffset; |
1137 this._visibleLevelHeights[level] = height; | 1138 this._visibleLevelHeights[level] = height; |
1138 } | 1139 } |
1139 if (thisLevelIsVisible || (parentGroupIsVisible && style.shareHeaderLine &
& isFirstOnLevel)) | 1140 if (thisLevelIsVisible || (parentGroupIsVisible && style.shareHeaderLine &
& isFirstOnLevel)) |
1140 currentOffset += this._visibleLevelHeights[level]; | 1141 currentOffset += this._visibleLevelHeights[level]; |
1141 } | 1142 } |
(...skipping 420 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1562 } | 1563 } |
1563 | 1564 |
1564 /** | 1565 /** |
1565 * @override | 1566 * @override |
1566 * @return {number} | 1567 * @return {number} |
1567 */ | 1568 */ |
1568 boundarySpan() { | 1569 boundarySpan() { |
1569 return this._maximumBoundaries - this._minimumBoundaries; | 1570 return this._maximumBoundaries - this._minimumBoundaries; |
1570 } | 1571 } |
1571 }; | 1572 }; |
OLD | NEW |