提交 b7673fb6 编写于 作者: R Rob Lourens

💄

上级 d862e321
......@@ -56,6 +56,10 @@ function createGroupIterator(group: SettingsTreeGroupElement): Iterator<ITreeEle
const $ = DOM.$;
interface IFocusEventFromScroll extends KeyboardEvent {
fromScroll: true;
}
const SETTINGS_EDITOR_STATE_KEY = 'settingsEditorState';
export class SettingsEditor2 extends BaseEditor {
......@@ -586,7 +590,7 @@ export class SettingsEditor2 extends BaseEditor {
this.renderTree();
this.settingsTree.scrollTop = 0;
}
} else if (element && (!e.browserEvent || !(<any>e.browserEvent).fromScroll)) {
} else if (element && (!e.browserEvent || !(<IFocusEventFromScroll>e.browserEvent).fromScroll)) {
this.settingsTree.reveal(element, 0);
}
}));
......@@ -709,7 +713,7 @@ export class SettingsEditor2 extends BaseEditor {
this.tocTree.setSelection([element]);
const fakeKeyboardEvent = new KeyboardEvent('keydown');
(<any>fakeKeyboardEvent).fromScroll = true;
(<IFocusEventFromScroll>fakeKeyboardEvent).fromScroll = true;
this.tocTree.setFocus([element], fakeKeyboardEvent);
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册