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

[MRG] Allow Slideshow to be used as a context manager #18

Merged
merged 1 commit into from
Aug 21, 2020
Merged

[MRG] Allow Slideshow to be used as a context manager #18

merged 1 commit into from
Aug 21, 2020

Conversation

clint-lawrence
Copy link
Contributor

Add enter and exit methods. This required re-ordering
some of the initialisation of Slideshow, so that the Screen
object isn't created until enter is called

This makes cleaning up the terminal state more reliable and
removes the need for the os.system() call to reset.

Add __enter__ and __exit__ methods. This required re-ordering
some of the initialisation of Slideshow, so that the Screen
object isn't created until __enter__ is called
@vinayak-mehta
Copy link
Owner

@clint-lawrence Thanks for looking into and fixing this! This re-ordering makes much more sense.

@vinayak-mehta vinayak-mehta changed the title Allow Slideshow to be used as a context manager. [MRG] Allow Slideshow to be used as a context manager Aug 21, 2020
@vinayak-mehta vinayak-mehta merged commit 0c35151 into vinayak-mehta:master Aug 21, 2020
@vinayak-mehta
Copy link
Owner

💚 💙 💜 💛 ❤️

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.

2 participants