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

Decouple rendering of UI from internal state (such as images held) #28

Closed
gurgalex opened this issue May 9, 2019 · 3 comments
Closed
Assignees
Milestone

Comments

@gurgalex
Copy link
Collaborator

gurgalex commented May 9, 2019

I think this would make writing tests easier, as the internal state of the application (ex. current image index) could be tested before and after without needing to spawn an sdl2 window.

@Davejkane
Copy link
Owner

Yeah, I'm already starting to get a little weary of the Program god struct. Is this something you'd like to take a look at? If you have something in particular in mind?

@gurgalex
Copy link
Collaborator Author

gurgalex commented May 9, 2019

Yeah, I'd like to take a look at it.

Seperating images, dest_folder, index from the UI is a start.

Communicating data changes to and from the UI / data source

Example data structure and communication. I'll see how it goes.
see fn update_counter
https://azul.rs/

I'm sure there are other ways to go about making testing / splitting up easier.

@Davejkane Davejkane self-assigned this May 10, 2019
@Davejkane Davejkane added this to the 0.3 milestone May 10, 2019
@Davejkane
Copy link
Owner

I'm taking care of this in the info bar branch.

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

No branches or pull requests

2 participants