So far, we’ve learned to create a GUI and switch between panels in the GUI, but we’ve not really looked at how to make our GUI buttons responsive and perform the actions we want when the user clicks on them. In this chapter, we’ll dive into event-driven programming , which is the programming paradigm we use to construct applications that use GUIs and event handlers.
We’ll see how we can build our application to include multiple threads, making our application appear responsive to the user even if the application is performing calculations in another thread. This will build on the parallelism we learned in a prior chapter.
Some key terms we’ll cover in this chapter:
- GUI Event
- Event Handler / Callback / Listener
- Event Loop
- Binding Events
- GUI Focus
After this chapter, we’ll be able to update our applications to respond to user button clicks and other events.