title: UITableView's didSelectRowAtIndexPath method not getting called
body: <p>I have a<code>UIViewController</code> with a<code>UITableView</code> in it. The tableview has customized cells, with textfields inside it. The delegates of the textfield are set to that class. </p>
  
  <p>On edit of a textfield(<code>textFieldDidBeginEditing</code>) I have a drop down(<code>UIView</code>with a tableview in it). The dropdown is created programmatically.
  The problem I am facing is, the<code>didSelectRowAtIndexPath</code> of the dropdown tableview isn't being called. I have set the delegate, datasource to the class rightly. I have removed all other gestures too. I have made sure that the tableview isn't in editing mode. </p>
  
  <p>On the clicks of cells in the dropdown, the only thing that works is my background tableview's textfield's delegate methods.</p>
  
  <pre><code>//UITableView class(with textfield from where dropdown is loaded.)
  - (void)textFieldDidBeginEditing:(UITextField *)textField{
  
  if(textField.tag == 3){
      if(dropDown == nil) {
          CGFloat f = 200;
          dropDown = [[SFTextFieldDropDown alloc] showDropDownWithSender:textField withHeight:f andElements:self.list];
          dropDown.delegate = self;
          }
      }
  }
  
  // Custom Drop down class.
  - (id)showDropDownWithSender:(UITextField *)senderTextField withHeight:(CGFloat)height andElements:(NSArray *)array{
  
      table = [[UITableView alloc] initWithFrame:CGRectMake(0, 0, btn.size.width, 0)];
      table.delegate = self;
      table.dataSource = self;
      table.layer.cornerRadius = 5;
      table.backgroundColor = [UIColor colorWithRed:0.239 green:0.239 blue:0.239 alpha:1];
      table.separatorStyle = UITableViewCellSeparatorStyleSingleLine;
      table.separatorColor = [UIColor grayColor];
      [table setAllowsSelection:YES];
      table.frame = CGRectMake(0, 0, btn.size.width, *height);
      [table setEditing:NO];
      [self addSubview:table];
  }
  return self;
  }
  
  - (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView {
  return 1;
  }
  
  -(CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
  return 40;
  }
  
  - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
  return [self.list count];
  }
  
  
  - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
  static NSString *CellIdentifier = @"Cell";
  
  UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
  if (cell == nil) {
      cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier];
      cell.textLabel.font = [UIFont systemFontOfSize:15];
      cell.textLabel.textAlignment = NSTextAlignmentLeft;
      cell.selectionStyle = UITableViewCellSelectionStyleDefault;
  }
  if([list count] &gt; 0)
      cell.textLabel.text = [list objectAtIndex:indexPath.row];
  
  return cell;
  }
  </code></pre>