Because the selected movies have the same director and same writer, those values are displayed in the master-detail fields at the bottom. However, since they have different titles and release dates, those fields use a stand-in "multi value" instead.
Editing the release date field simultaneously changes the release date of all movies in the selection.
Here's the code that was used to hook up the detail fields to the multi-selection of the viewer:
IObservableList selections = ViewerProperties.multipleSelection()See the full code listing for this snippet here.
.observe(viewer);
dbc.bindValue(
WidgetProperties.text(SWT.Modify).observe(title),
DuplexingObservableValue.withDefaults(
BeanProperties.value("title").observeDetail(selections),
"", "<Multiple titles>"));
dbc.bindValue(
WidgetProperties.text(SWT.Modify).observe(releaseDate),
DuplexingObservableValue.withDefaults(
BeanProperties.value("releaseDate").observeDetail(selections),
"", "<Multiple dates>"));
dbc.bindValue(
WidgetProperties.text(SWT.Modify).observe(director),
DuplexingObservableValue.withDefaults(
BeanProperties.value("director").observeDetail(selections),
"", "<Multiple directors>"));
dbc.bindValue(
WidgetProperties.text(SWT.Modify).observe(writer),
DuplexingObservableValue.withDefaults(
BeanProperties.value("writer").observeDetail(selections),
"", "<Multiple writers>"));
Disclaimer: The method DuplexingObservableValue.withDefaults() was added after the 3.5M5 milestone, so in order to use it you need to check out the databinding projects from CVS HEAD, or be using a more recent integration build.