Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
アプリケーションの UITableView に subView を追加しましたが、追加した後でも tableViewCell はクリック可能です。これを防ぐにはどうすればよいですか?pls help
今回の問題を理解した場合、サブビューを画面のサイズにすることができれば、サブビューで userInteractionEnabled を TRUE に設定するだけです。
シンプルな UITableView とその上の UIImageView でテストしました。userInteractionEnabled を無効にすると、tableView デリゲートの willSelectRowAtIndexPath が呼び出されます。TRUE に設定すると、何も起こりません。