mirror of https://github.com/keeweb/keeweb.git
Scroll to selected entry on open
This commit is contained in:
parent
7fee323f68
commit
4a4551a199
|
@ -320,7 +320,11 @@ class AppModel {
|
|||
this.activeEntryId = firstEntry ? firstEntry.id : null;
|
||||
}
|
||||
Events.emit('filter', { filter: this.filter, sort: this.sort, entries });
|
||||
Events.emit('entry-selected', entries.get(this.activeEntryId));
|
||||
const activeEntry = entries.get(this.activeEntryId);
|
||||
Events.emit('entry-selected', activeEntry);
|
||||
if (this.activeEntryId && activeEntry) {
|
||||
Events.emit('select-list-item', activeEntry);
|
||||
}
|
||||
}
|
||||
|
||||
refresh() {
|
||||
|
|
|
@ -62,6 +62,7 @@ class ListView extends View {
|
|||
this.listenTo(Events, 'filter', this.filterChanged);
|
||||
this.listenTo(Events, 'entry-updated', this.entryUpdated);
|
||||
this.listenTo(Events, 'set-locale', this.render);
|
||||
this.listenTo(Events, 'select-list-item', this.selectItem);
|
||||
|
||||
this.listenTo(this.model.settings, 'change:tableView', this.setTableView);
|
||||
|
||||
|
|
Loading…
Reference in New Issue