> This PR fixes a bunch of NPEs when a null `SelectionModel` or `FocusModel` is > set on a `ListView`. > > The following NPEs are fixed (all are also covered by exactly one test case): > NPEs with null selection model: > - Mouse click on a `ListCell` > - SPACE key press > - KP_UP (arrow up) key press > - HOME key press > - END key press > - BACK_SLASH + CTRL key press > > NPEs with null focus model: > - SPACE key press > - Select an items: getSelectionModel().select(1) > - Clear-Select an item and add one after: > `listView.getSelectionModel().clearAndSelect(1); > listView.getItems().add("3");`
Marius Hanl has updated the pull request incrementally with one additional commit since the last revision: Cleanup unneeded Toolkit.getToolkit().firePulse() and stageLoader.dispose(); ------------- Changes: - all: https://git.openjdk.org/jfx/pull/711/files - new: https://git.openjdk.org/jfx/pull/711/files/9146e080..5f61fe0a Webrevs: - full: https://webrevs.openjdk.org/?repo=jfx&pr=711&range=03 - incr: https://webrevs.openjdk.org/?repo=jfx&pr=711&range=02-03 Stats: 5 lines in 1 file changed: 0 ins; 5 del; 0 mod Patch: https://git.openjdk.org/jfx/pull/711.diff Fetch: git fetch https://git.openjdk.org/jfx pull/711/head:pull/711 PR: https://git.openjdk.org/jfx/pull/711