Subclassing DataGrid


#1

I am trying to subclass the datagrid. Adopting the protocols as 

@interface myDataGrid : ShinobiDataGrid<SDataGridDelegate,SDataGridDataSource>

 Everything works fine till i scroll the grid. When scroll I get the error  EXC_BAD_ACCESS (code=2, adress=0xb7fffec) with bactrace as below. Selecting a cell or dragging a cell works ok but not scrolling the grid. Any ideas what am i doing wrong?

* thread #1: tid = 0x6a20d, 0x01d4f05c libobjc.A.dylib`lookUpImpOrForward + 9, queue = 'com.apple.main-thread, stop reason = EXC_BAD_ACCESS (code=2, address=0xbf7fffec)
    frame #0: 0x01d4f05c libobjc.A.dylib`lookUpImpOrForward + 9
    frame #1: 0x01d4f004 libobjc.A.dylib`lookUpImpOrNil + 62
    frame #2: 0x01d4681b libobjc.A.dylib`class_respondsToSelector + 66
    frame #3: 0x01d59462 libobjc.A.dylib`-[NSObject respondsToSelector:] + 53
    frame #4: 0x000532e7 Funds`-[ShinobiDataGrid scrollViewWillBeginDragging:] + 71
    frame #5: 0x00053317 Funds`-[ShinobiDataGrid scrollViewWillBeginDragging:] + 119
    frame #6: 0x00053317 Funds`-[ShinobiDataGrid scrollViewWillBeginDragging:] + 119
    frame #7: 0x00053317 Funds`-[ShinobiDataGrid scrollViewWillBeginDragging:] + 119
     frame #8: 0x00053317 Funds`-[ShinobiDataGrid scrollViewWillBeginDragging:] + 119
 ....(repeats the same here)
frame #174505: 0x00053317 RasyonetFunds`-[ShinobiDataGrid scrollViewWillBeginDragging:] + 119
    frame #174506: 0x000181d2 Funds`-[ShinobiGrid scrollViewWillBeginDragging:] + 1506
    frame #174507: 0x00b47cff UIKit`-[UIScrollView(UIScrollViewInternal) _scrollViewWillBeginDragging] + 171
    frame #174508: 0x00b307f8 UIKit`-[UIScrollView _updatePanGesture] + 266
    frame #174509: 0x00b36286 UIKit`-[UIScrollView handlePan:] + 306
    frame #174510: 0x00e2de8c UIKit`_UIGestureRecognizerSendActions + 230
    frame #174511: 0x00e2cb00 UIKit`-[UIGestureRecognizer _updateGestureWithEvent:buttonEvent:] + 383
    frame #174512: 0x00e2e56d UIKit`-[UIGestureRecognizer _delayedUpdateGesture] + 60
    frame #174513: 0x00e31acd UIKit`___UIGestureRecognizerUpdate_block_invoke + 57
    frame #174514: 0x00e31a4e UIKit`_UIGestureRecognizerRemoveObjectsFromArrayAndApplyBlocks + 317
    frame #174515: 0x00e28148 UIKit`_UIGestureRecognizerUpdate + 199
    frame #174516: 0x01f8c4ce CoreFoundation` __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 30
    frame #174517: 0x01f8c41f CoreFoundation`__CFRunLoopDoObservers + 399
    frame #174518: 0x01f6a344 CoreFoundation`__CFRunLoopRun + 1076
    frame #174519: 0x01f69ac3 CoreFoundation`CFRunLoopRunSpecific + 467
    frame #174520: 0x01f698db CoreFoundation`CFRunLoopRunInMode + 123
    frame #174521: 0x024719e2 GraphicsServices`GSEventRunModal + 192
    frame #174522: 0x02471809 GraphicsServices`GSEventRun + 104
 
    frame #174523: 0x00ab5d3b UIKit`UIApplicationMain + 1225

#2

Greetings Program!

I created an empty subclass of the ShinobiDataGrid (with and without implementing the delegates in the @interface) and used it in the Getting Started sample app without any issues. I would say that something in your custom code is the cause.

The version probably has nothing to do with it but what version are you using?

Wg