Merge branch 'command_line_compont' of gitee.com:BearCAD/WebThreeJs into command_line_compont

pull/7/head
ChenX 7 years ago
commit 8b90518f00

@ -217,6 +217,7 @@ export class InputHint extends React.Component<{ commandStore?: CommandStore },
{
this.m_liHover.className = 'hover';
this.props.commandStore.hoverLi = this.m_liHover;
}
}

@ -27,6 +27,7 @@ export class CommandStore
//设置输入框为焦点
isInputFocus: boolean;
hoverLi: Element;
elInput: HTMLInputElement;
outputContainer: HTMLElement;
commandListContainer: HTMLElement;
@ -103,6 +104,11 @@ export class CommandStore
commandMachine.ExecCommand(inpValue);
this.Prompt(inpValue);
this.searchCommand.length = 0;
} else if (this.hoverLi)
{
commandMachine.ExecCommand(this.hoverLi.innerHTML);
this.Prompt(this.hoverLi.innerHTML);
this.searchCommand.length = 0;
}
else
{

Loading…
Cancel
Save