{"issue":{"title":"unable to reorder using default table reordering methods","created_at":"2011-12-12T16:51:52Z","user":{"login":"djgooner","id":1258019,"url":"https://api.github.com/users/djgooner","gravatar_id":"bbf0e4ac8d6e844f8e1d795de26e4006","avatar_url":"https://secure.gravatar.com/avatar/bbf0e4ac8d6e844f8e1d795de26e4006?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png"},"milestone":null,"labels":[],"state":"open","updated_at":"2011-12-15T21:32:18Z","id":2525247,"html_url":"https://github.com/raweng/StackScrollView/issues/30","pull_request":{"patch_url":null,"html_url":null,"diff_url":null},"closed_at":null,"number":30,"body":"Take the sample app from the github, and place the following in the dataviewcontroller class.\r\n\r\n//this in the - (id)initWithFrame:(CGRect)frame \r\n[_tableView setEditing:YES];\r\n\r\n// then these two methods.\r\n#pragma mark Row reordering\r\n// Determine whether a given row is eligible for reordering or not.\r\n- (BOOL)tableView:(UITableView *)tableView canMoveRowAtIndexPath:(NSIndexPath *)indexPath {\r\n    return YES;\r\n}\r\n\r\n// Process the row move. This means updating the data model to correct the item indices.\r\n- (void)tableView:(UITableView *)tableView moveRowAtIndexPath:(NSIndexPath *)fromIndexPath toIndexPath:(NSIndexPath *)toIndexPath \r\n{\r\n    \r\n    \r\n}\r\n\r\ni see the table with the reordering indicators. but nothing happens when i try to drag. but put a breakpoint on the second method, moveRowAtIndexPath. and tap on the three line icon for reordering, the method gets called. So something is stopping from selecting and dragging. i am still looking in to this but if anyone has any suggestions will be greatly appreciated.","url":"https://api.github.com/repos/raweng/StackScrollView/issues/30","comments":2,"assignee":null},"comment":{"created_at":"2011-12-15T21:32:18Z","user":{"login":"djgooner","id":1258019,"url":"https://api.github.com/users/djgooner","gravatar_id":"bbf0e4ac8d6e844f8e1d795de26e4006","avatar_url":"https://secure.gravatar.com/avatar/bbf0e4ac8d6e844f8e1d795de26e4006?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png"},"updated_at":"2011-12-15T21:32:18Z","id":3169373,"body":"Thanks that partially worked, i had to modify the second the method to\r\n\r\n-(BOOL) gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldReceiveTouch:(UITouch *)touch {\r\n    NSString *className = [NSString stringWithFormat:@\"%@\", touch.view.class];\r\n    if ([className isEqualToString:@\"UITableViewCellReorderControl\"]) {\r\n        return NO;\r\n    }\r\n    return YES;\r\n}\r\n\r\nWhen touching the tableCell with the reorder control, table.view class was returning, \"UITableViewCellReorderControl\"\r\n---------------------------------------------------------------------------------------\r\nbut in the method [touch.view isKindOfClass:[UIControl class]] i could not replace it with\r\n[UITableViewCellReorderControl class] for some reason, even though i imported <UIKit/UIKit.h>","url":"https://api.github.com/repos/raweng/StackScrollView/issues/comments/3169373"},"action":"created"}