Repository navigation
Commit 40033eb
authored
fix(android): keep the ListView sticky header layout listener out of a cycle (#11660)
The sticky header's native view holds the OnLayoutChangeListener that
adjusts the list padding, and the listener's arrow function captured
both its own variable (to remove itself) and the ListView. The
self-reference outlived the listener's removal and the ListView
reference reached the header's native view; wrapper resurrection used
to collect both cycles, but a runtime that keeps a JS-implemented
object's state for as long as Java holds the object cannot. The
listener now removes itself through `this` and reaches the ListView
through a WeakRef.1 parent ef1971d commit 40033eb
2 files changed
Lines changed: 52 additions & 7 deletions
File tree
- apps/automated/src/ui/list-view
- packages/core/ui/list-view
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
872 | 872 | | |
873 | 873 | | |
874 | 874 | | |
| 875 | + | |
| 876 | + | |
| 877 | + | |
| 878 | + | |
| 879 | + | |
| 880 | + | |
| 881 | + | |
| 882 | + | |
| 883 | + | |
| 884 | + | |
| 885 | + | |
| 886 | + | |
| 887 | + | |
| 888 | + | |
| 889 | + | |
| 890 | + | |
| 891 | + | |
| 892 | + | |
| 893 | + | |
| 894 | + | |
| 895 | + | |
| 896 | + | |
| 897 | + | |
| 898 | + | |
| 899 | + | |
| 900 | + | |
| 901 | + | |
| 902 | + | |
| 903 | + | |
| 904 | + | |
| 905 | + | |
| 906 | + | |
| 907 | + | |
| 908 | + | |
| 909 | + | |
| 910 | + | |
875 | 911 | | |
876 | 912 | | |
877 | 913 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
458 | 458 | | |
459 | 459 | | |
460 | 460 | | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
461 | 464 | | |
462 | | - | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
463 | 472 | | |
464 | 473 | | |
465 | 474 | | |
466 | 475 | | |
467 | | - | |
468 | | - | |
| 476 | + | |
| 477 | + | |
469 | 478 | | |
470 | 479 | | |
471 | 480 | | |
472 | 481 | | |
473 | 482 | | |
474 | 483 | | |
475 | | - | |
476 | | - | |
477 | | - | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
478 | 487 | | |
479 | | - | |
| 488 | + | |
480 | 489 | | |
481 | 490 | | |
482 | 491 | | |
| |||
0 commit comments