February 2019
Intermediate to advanced
450 pages
11h 59m
English
Now that we have all of the layout completed, we need to connect up a data source and handle the appropriate interaction events. We start by importing the client email package used in the previous examples. Once imported, we set up a new test server and cache the current message (this will be changed later by clicking an item). As outlined before, we must save all state within the application code, not the user interface:
import "github.com/PacktPublishing/Hands-On-GUI-Application-Development-in-Go/client"var server = client.NewTestServer()var current = server.CurrentMessage()
Updating the email list group is as simple as wrapping the label creation in a for loop that iterates the range of server.ListMessages() ...
Read now
Unlock full access