How to use the electron-better-ipc.ipcRenderer.send function in electron-better-ipc

To help you get started, we’ve selected a few electron-better-ipc 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 npezza93 / archipelago / app / renderer / sessions / session.js View on Github external
fit() {
    this.fitAddon.fit()
    ipc.send(`pty-resize-${this.id}`, {cols: this.xterm.cols, rows: this.xterm.rows})
  }
github npezza93 / archipelago / app / renderer / sessions / session.js View on Github external
async kill() {
    this.subscriptions.dispose()
    this.xterm.dispose()

    if (this._wrapperElement) {
      this._container.removeChild(this._wrapperElement)
      this._wrapperElement = null
    }

    const ptyId = await this.ptyId
    this.xterm = null

    await ipc.send(`pty-kill-${ptyId}`)
  }
github npezza93 / archipelago / app / renderer / utils / keybinding-capturer.jsx View on Github external
cleanup() {
    this.subscriptions.dispose()
    ipc.send('enable-shortcuts')
    this.props.deactivate()
  }
github npezza93 / archipelago / app / renderer / sessions / session.js View on Github external
this.subscriptions.add(this.onData(data => {
      ipc.send(`pty-write-${this.id}`, data)
    }))
    this.subscriptions.add(this.onTitle(this.setTitle))
github npezza93 / archipelago / app / renderer / sessions / session.js View on Github external
keybindingHandler(e) {
    let caught = false
    const mapping = this.keymaps[keystrokeForKeyboardEvent(e)]

    if (mapping) {
      ipc.send(`pty-write-${this.id}`, mapping)
      caught = true
    }

    return !caught
  }