XLForm icon indicating copy to clipboard operation
XLForm copied to clipboard

Crash when using SelectorLeftRight as row template

Open colinrblake opened this issue 6 years ago • 0 comments

I have a section with a row of type XLFormRowDescriptorTypeSelectorLeftRight which works fine. But when I define a template row the same way, at run time when I click on the row the creation of a duplicate causes an exception:

-[XLFormOptionsObject copyWithZone:]: unrecognized selector sent to instance 0x6000004240a0`

This is at the following line in XLFormRowDescriptor.m

rowDescriptorCopy.leftRightSelectorLeftOptionSelected = [self.leftRightSelectorLeftOptionSelected copy];

Seems that an XLFormOptionsObject can't be copied, because this simple test fails in the same way:

XLFormOptionsObject *x1 = [XLFormOptionsObject formOptionsObjectWithValue:@(0) displayText:@"Select Entry Type"];
XLFormOptionsObject *x2 = [x1 copy];

colinrblake avatar Apr 24 '18 00:04 colinrblake