TLYShyNavBar icon indicating copy to clipboard operation
TLYShyNavBar copied to clipboard

Navigation controller is jumping while scroll

Open ikousik opened this issue 9 years ago • 14 comments

I have integrated TLYShyNavBar with UITableView in my project. After a couple weeks I found that there is one very basic bug. Navigation controller is keep on jumping unexpectedly for a fix number of cell. Most of the time if TableView height is almost equal to the ViewController.

Just run the demo project and change in TLYTableViewController.m file numberOfSectionsInTableView and numberOfRowsInSection

numberOfSectionsInTableView = 1 numberOfRowsInSection = 13 or 14 (for 12 and 15 it's working fine) in iphone 5 and 6

- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
{
    return 1;
}

- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
{
    return 13;
}

ikousik avatar Feb 22 '16 15:02 ikousik

Very strange, I will try looking into it as soon as I find the time.

Mazyod avatar Feb 23 '16 15:02 Mazyod

Thanks :)

ikousik avatar Feb 23 '16 15:02 ikousik

@ikousik give this a shot https://github.com/telly/TLYShyNavBar/pull/123

szweier avatar Feb 23 '16 16:02 szweier

@szweier have tried but issue is not fixed.It's jumps with section 1 and 13 rows.

ikousik avatar Feb 23 '16 18:02 ikousik

Which view are you picking from the demo?

szweier avatar Feb 23 '16 19:02 szweier

@ikousik also, what simulator are you using, what OS.

szweier avatar Feb 23 '16 19:02 szweier

I see it jumping for an iPhone 5. Sorry taking a look.

szweier avatar Feb 23 '16 19:02 szweier

Looks like the issue is that when the frame changes it thinks it can fit the cells which then jumps back down. Not sure how to fix this one at the moment.

szweier avatar Feb 23 '16 20:02 szweier

Yea sorry about that it looks like this fixes the alignment issue on other devices rather than specifying a frame but it doesn't address the issue you are seeing.

Sent from my iPhone

On Feb 23, 2016, at 1:58 PM, 200 Ok [email protected] wrote:

@szweier have tried but issue is not fixed.It's jumps with section 1 and 13 rows.

— Reply to this email directly or view it on GitHub.

szweier avatar Feb 23 '16 22:02 szweier

@mazyod my PR fixed one part of this issue but not the entire problem. It looks like there's a deeper issue with adjusting the frame resulting in the jumping.

szweier avatar Feb 24 '16 01:02 szweier

@szweier @Mazyod I have uploaded one video in youtube please look into this.Video.

Xcode version - Version 7.2.1 (7C1002), iOS version : 9.2 Issue is coming If Section is 1 and no of row is 11 for iPhone 4s, 13 for iPhone 5 and 15 for iPhone 6

ikousik avatar Feb 24 '16 07:02 ikousik

Yea this seems to be happening when the table view frame becomes large enough to fit the cells again. In my opinion it's an edge case but would still be interesting to find a solution for. Granted I'm new to this code base so I'm not sure where to start to find this one just yet.

szweier avatar Feb 24 '16 12:02 szweier

@szweier any update ?

ikousik avatar Mar 15 '16 07:03 ikousik

@Mazyod issue is not fixed. why did u close the issue?

ikousik avatar Nov 04 '16 14:11 ikousik