trent234 / minwm

An ncurses based app switcher / launcher / window manager developed with the PinePhone in mind.
MIT License
5 stars 1 forks source link

refactor from while(true) model to event driven model #10

Open trent234 opened 4 years ago

trent234 commented 4 years ago

Lots of unknowns here still, but current strategy has a while(true) loop that waits for user input. so this means user text input is the only event minwm is "listening" for.

instead, what would be way better, is to have a socket where events of all types could come in, and minwm would respond accordingly. this is better because it allows for more types of events e.g. user requests keyboard, user rotates screen, process requests focus (like functionality you would expect when the phone rings), and other events that haven't been thought up yet.

trent234 commented 4 years ago

https://stackoverflow.com/questions/11062674/event-driven-model-in-c-with-sockets https://en.wikipedia.org/wiki/Libevent