Commit a87a8da
committed
[duplicated subtitle] perf(SubtitleDeduplicator): compile TTML <p> pattern once for efficiency
- Replace defineTtmlSubtitlePattern() method with a static final Pattern
- getTtmlMatcher() now reuses the precompiled pattern instead of recompiling each call
- Improves performance when processing multiple subtitles without changing behavior1 parent cc6e119 commit a87a8da
File tree
1 file changed
+5
-7
lines changed- app/src/main/java/org/schabi/newpipe/util/subtitle
1 file changed
+5
-7
lines changedLines changed: 5 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
372 | 372 | | |
373 | 373 | | |
374 | 374 | | |
375 | | - | |
376 | | - | |
377 | | - | |
378 | | - | |
379 | | - | |
380 | | - | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
381 | 379 | | |
382 | 380 | | |
383 | | - | |
| 381 | + | |
384 | 382 | | |
385 | 383 | | |
386 | 384 | | |
| |||
0 commit comments