mirror of
https://github.com/loot/libloot.git
synced 2026-07-27 14:16:01 -07:00
Get the plugin card list directly
Don't get its parent then the lastElementChild, that's more prone to breaking.
This commit is contained in:
@@ -39,7 +39,7 @@ function onChangeGame(evt) {
|
||||
|
||||
/* Reset virtual list positions. */
|
||||
document.getElementById('cardsNav').scrollToIndex(0);
|
||||
document.getElementById('main').lastElementChild.scrollToIndex(0);
|
||||
document.getElementById('pluginCardList').scrollToIndex(0);
|
||||
|
||||
/* Now update virtual lists. */
|
||||
filterPluginData(loot.game.plugins, loot.filters);
|
||||
|
||||
@@ -223,7 +223,7 @@
|
||||
const game = JSON.parse(result, Plugin.fromJson);
|
||||
appData.game = new Game(game, appData.l10n);
|
||||
document.getElementById('cardsNav').items = appData.game.plugins;
|
||||
document.getElementById('main').lastElementChild.items = appData.game.plugins;
|
||||
document.getElementById('pluginCardList').items = appData.game.plugins;
|
||||
applyEnabledFilters(appData.filters, appData.settings, appData.game.plugins);
|
||||
Dialog.closeProgress();
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user