Fossil SCM

Proactive fix for diff context loading init which would have been a bug once wikiedit and fileedit get connected to it.

stephan 2021-09-13 19:24 trunk
Commit 63eb9d3b00d4f1993d53c731057f51d34fb5bca3a615dec02e7476706a6b8f33
1 file changed +1 -1
--- src/fossil.diff.js
+++ src/fossil.diff.js
@@ -654,11 +654,11 @@
654654
}
655655
/* Potential performance-related TODO: instead of installing all
656656
of these at once, install them as the corresponding TR is
657657
scrolled into view. */
658658
tables.forEach(function(table){
659
- if(!table.dataset.lefthash) return;
659
+ if(table.classList.contains('diffskipped') || !table.dataset.lefthash) return;
660660
D.addClass(table, 'diffskipped'/*avoid processing these more than once */);
661661
table.querySelectorAll('tr.diffskip[data-startln]').forEach(function(tr){
662662
new ChunkLoadControls(D.addClass(tr, 'jchunk'));
663663
});
664664
});
665665
--- src/fossil.diff.js
+++ src/fossil.diff.js
@@ -654,11 +654,11 @@
654 }
655 /* Potential performance-related TODO: instead of installing all
656 of these at once, install them as the corresponding TR is
657 scrolled into view. */
658 tables.forEach(function(table){
659 if(!table.dataset.lefthash) return;
660 D.addClass(table, 'diffskipped'/*avoid processing these more than once */);
661 table.querySelectorAll('tr.diffskip[data-startln]').forEach(function(tr){
662 new ChunkLoadControls(D.addClass(tr, 'jchunk'));
663 });
664 });
665
--- src/fossil.diff.js
+++ src/fossil.diff.js
@@ -654,11 +654,11 @@
654 }
655 /* Potential performance-related TODO: instead of installing all
656 of these at once, install them as the corresponding TR is
657 scrolled into view. */
658 tables.forEach(function(table){
659 if(table.classList.contains('diffskipped') || !table.dataset.lefthash) return;
660 D.addClass(table, 'diffskipped'/*avoid processing these more than once */);
661 table.querySelectorAll('tr.diffskip[data-startln]').forEach(function(tr){
662 new ChunkLoadControls(D.addClass(tr, 'jchunk'));
663 });
664 });
665

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button