Skip to content

Instantly share code, notes, and snippets.

@ralphtheninja
Created October 18, 2018 16:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ralphtheninja/09311a546cc73c736d5abed5c8e31060 to your computer and use it in GitHub Desktop.
Save ralphtheninja/09311a546cc73c736d5abed5c8e31060 to your computer and use it in GitHub Desktop.

Whenever something happens in src/main/deltachat.js, the render() function will be called. For example here:

https://github.com/deltachat/deltachat-desktop/blob/master/src/main/deltachat.js#L109

The render() function is passed into the .login() method here:

https://github.com/deltachat/deltachat-desktop/blob/master/src/main/deltachat.js#L57

from src/main/ipc.js here:

https://github.com/deltachat/deltachat-desktop/blob/master/src/main/ipc.js#L50

When render() is called in deltachat.js it will trigger this function:

https://github.com/deltachat/deltachat-desktop/blob/master/src/main/ipc.js#L96-L98

Which in turn sends the 'render' message to the view, which has a handler here:

https://github.com/deltachat/deltachat-desktop/blob/master/src/renderer/main.js#L39-L41

which calls update()

https://github.com/deltachat/deltachat-desktop/blob/master/src/renderer/main.js#L67-L71

The bottom line here is the call to app.setState(state), which will trigger render() in App.js, which propagates down.

So I'm guessing something in the split view PR has broken that chain on the view side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment