Some debugging later...
.1. Bring up the widget picker. It shows the code picking two random events, one each for the small and medium widgets. It picked the "Gallery Opening" event for both of them.
.2. Log output shows:
snapshot: inPreview, returning random events // One for the small widget
snapshot: inPreview, returning random events // Medium widget
WidgetMedium: event.name = 'Gallery Opening' // Medium widget called to display the "Gallery Opening" event
snapshot: inPreview, returning random events // Not sure why there's a third call, but anyway...
.3. Despite having selected the medium widget that showed "Gallery Opening", the widget is added to the Home Screen without an event selected:
.4. I didn't pick the "Paris Trip" event, but the log shows the medium widget being called multiple times for that event:
timeline: event.name = Paris Trip
WidgetMedium: event.name = 'Paris Trip'
WidgetMedium: event.name = 'Paris Trip'
WidgetMedium: event.name = 'Paris Trip'
... repeated lots of times
.5. Edit the widget. No event has been chosen. I would assume this should be "Gallery Opening" since that's what I picked from the widget picker earlier. How do you link the event picked in the widget picker to the event it should display?!:
.6. From the events list, I picked "London Party", and this shows in the log:
theEvent: caller: 'timeline': looking for id = London Party!
theEvent: caller: 'timeline': event.name = 'London Party!, event.location = 'London'
timeline: event.name = London Party!
WidgetMedium: event.name = 'London Party!'
WidgetMedium: event.name = 'London Party!'
WidgetMedium: event.name = 'London Party!'
... repeated lots of times
So it is definitely calling the medium widget with the correct event that I've picked, but...
.7. Close the event picker, and the widget remains redacted and as though no event has been selected. It doesn't get updated:
I'm really at the end of my tether with this. It's not entirely obvious how this stuff is supposed to work. I've based this off the Backyard Birds example, but while it works fine there, it fails here. I just don't understand how to get this to work properly.