I've implemented a collectionView in a tableView cell in one my (Swift) projects where each UITableViewCell
contains a UICollectionView
and each collectionView then has UICollectionViewCell
's. And my collectionView cell is again customized in a Xib.
Now when I tried to implement accessibility on this, this is going through some weird behavior. What I did so far -
(1) Since each
UITableViewCell
containsUICollectionView
, so I set tableView cell's accessibility to false.e.g.
dummyTableViewCell.isAccessibilityElement = false
(2) Then I override
UIAccessibilityContainer
methods on my UICollectionView class. e.g.override func accessibilityElementCount() -> Int { return subViews.count }
and so on...
While this reads through each element of collectionView inside tableView cell, but then VO stops after 4th or 5th row and does not scroll past any more. I did try again with implementing UIScrollView
delegate methods, but nothing is working out so far.