diff options
Diffstat (limited to 'src/console')
-rw-r--r-- | src/console/actions/console.ts | 14 | ||||
-rw-r--r-- | src/console/components/Console.tsx | 8 |
2 files changed, 2 insertions, 20 deletions
diff --git a/src/console/actions/console.ts b/src/console/actions/console.ts index b17754d..e44c974 100644 --- a/src/console/actions/console.ts +++ b/src/console/actions/console.ts @@ -232,18 +232,6 @@ const getPropertyCompletions = async( } }; -const getCompletions = async(text: string): Promise<actions.SetCompletionsAction> => { - const completions = await browser.runtime.sendMessage({ - type: messages.CONSOLE_QUERY_COMPLETIONS, - text, - }); - return { - type: actions.CONSOLE_SET_COMPLETIONS, - completions, - completionSource: text, - }; -}; - const completionNext = (): actions.CompletionNextAction => { return { type: actions.CONSOLE_COMPLETION_NEXT, @@ -258,6 +246,6 @@ const completionPrev = (): actions.CompletionPrevAction => { export { hide, showCommand, showFind, showError, showInfo, hideCommand, setConsoleText, enterCommand, enterFind, - getCompletions, getCommandCompletions, getOpenCompletions, getTabCompletions, getPropertyCompletions, + getCommandCompletions, getOpenCompletions, getTabCompletions, getPropertyCompletions, completionNext, completionPrev, }; diff --git a/src/console/components/Console.tsx b/src/console/components/Console.tsx index 77f1b09..3fe5cee 100644 --- a/src/console/components/Console.tsx +++ b/src/console/components/Console.tsx @@ -175,22 +175,16 @@ class Console extends React.Component<Props> { this.props.dispatch(consoleActions.getTabCompletions(text, cmd.command, cmd.args, false)); break; case Command.BufferDelete: - this.props.dispatch(consoleActions.getTabCompletions(text, cmd.command, cmd.args, true)); - break; - case Command.BufferDeleteForce: - this.props.dispatch(consoleActions.getTabCompletions(text, cmd.command, cmd.args, false)); - break; case Command.BuffersDelete: this.props.dispatch(consoleActions.getTabCompletions(text, cmd.command, cmd.args, true)); break; + case Command.BufferDeleteForce: case Command.BuffersDeleteForce: this.props.dispatch(consoleActions.getTabCompletions(text, cmd.command, cmd.args, false)); break; case Command.Set: this.props.dispatch(consoleActions.getPropertyCompletions(text, cmd.command, cmd.args)); break; - default: - this.props.dispatch(consoleActions.getCompletions(text)); } } } |