Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added context.Context support #180

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

Zaba505
Copy link

@Zaba505 Zaba505 commented Nov 21, 2018

Added the method MainLoopWithContext, which allows for callers to supply their own context for running a Gui. I made this addition because of a project I'm personally working on (and hope to add to the README list soon). My project is heavily concurrent and their exists an abstraction layer between the Gui and a backend. The abstraction layer handles many things, mainly monitoring os.Signals, which means I couldn't/(don't want to) allow Gui to handle termination. Currently, there is no way to solve my problem. Hence, this pull request adds the solution to my problem and hopefully brings even more possibilities to what can be done with gocui.

Added the method `MainLoopWithContext`, which allows for callers to supply their own context for running a `Gui`. I made this addition because of a project I'm personally working on (and hope to add to the README list soon). My project is heavily concurrent and their exists an abstraction layer between the `Gui` and a backend. The abstraction layer handles many things, mainly monitoring `os.Signal`s and others, which means I couldn't/(don't want to) allow `Gui` to handle termination. Currently, there is no way to solve my problem. Hence, this pull request adds the solution to my problem and hopefully brings even more possibilities to what can be done with `gocui`.
makyo pushed a commit to makyo/gotui that referenced this pull request Feb 4, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant