@protected
WOAssociation *list;
WOAssociation *item;
- WOAssociation *selection;
+ WOAssociation *selection; // => use 'selections'!
WOAssociation *string; // WO4 => use 'displayString'!
WOAssociation *noSelectionString; // WO4
// non-WO:
WOAssociation *singleSelection; // selection contains an item, not an array
+
+ // WO 4.5
WOAssociation *multiple; // multiple selections allowed
WOAssociation *size;
- // TODO: WO 4.5: selectedValues, escapeHTML, selections
+ // TODO: WO 4.5: selectedValues, escapeHTML
}
@end /* WOBrowser */
if ((self = [super initWithName:_name associations:_config template:_c])) {
self->list = OWGetProperty(_config, @"list");
self->item = OWGetProperty(_config, @"item");
- self->selection = OWGetProperty(_config, @"selection");
self->singleSelection = OWGetProperty(_config, @"singleSelection");
self->multiple = OWGetProperty(_config, @"multiple");
self->size = OWGetProperty(_config, @"size");
@"are set, use only one! ('string' is deprecated!)"];
}
+ if ((self->selection = OWGetProperty(_config, @"selections")) == nil) {
+ if ((self->selection = OWGetProperty(_config, @"selection")) == nil) {
+ [self debugWithFormat:
+ @"Note: using deprecated 'selection' binding, "
+ @"use 'selections' instead."];
+ }
+ }
+ else if (OWGetProperty(_config, @"selection") != nil) {
+ [self debugWithFormat:@"WARNING: 'selections' AND 'selection' bindings "
+ @"are set, use only one! ('selection' is deprecated!)"];
+ }
+
// compatiblity
if (self->noSelectionString == nil)
self->noSelectionString = OWGetProperty(_config, @"nilString");