How to use the @lumino/algorithm.ArrayExt.removeAllWhere function in @lumino/algorithm

To help you get started, we’ve selected a few @lumino/algorithm examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github jtpio / ipylab / src / widgets / commands.ts View on Github external
private _removeCommand(bundle: { id: string }): void {
    const { id } = bundle;
    if (Private.customCommands.has(id)) {
      Private.customCommands.get(id).dispose();
    }
    const commands = this.get('_commands').slice();
    ArrayExt.removeAllWhere(commands, (w: any) => w.id === id);
    this.set('_commands', commands);
    this.save_changes();
    this._sendCommandList();
  }
github jtpio / ipylab / src / widgets / shell.ts View on Github external
MessageLoop.installMessageHook(pWidget, (handler: any, msg: Message) => {
      switch (msg.type) {
        case 'close-request': {
          const widgets = this.get('_widgets').slice();
          ArrayExt.removeAllWhere(widgets, (w: any) => w.id === handler.id);
          this.set('_widgets', widgets);
          this.save_changes();
          break;
        }
      }
      return true;
    });
github jupyterlab / lumino / packages / messaging / src / index.ts View on Github external
function cleanupHooks(hooks: Array): void {
    ArrayExt.removeAllWhere(hooks, isNull);
  }
github jupyterlab / jupyterlab / packages / codemirror / src / editor.ts View on Github external
return new DisposableDelegate(() => {
      ArrayExt.removeAllWhere(this._keydownHandlers, val => val === handler);
    });
  }
github jupyterlab / lumino / packages / signaling / src / index.ts View on Github external
function cleanupConnections(connections: IConnection[]): void {
    ArrayExt.removeAllWhere(connections, isDeadConnection);
  }