Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

layoutSubviews not always called in ATPagingView custom page views #3

Open
angian00 opened this issue Jun 1, 2011 · 0 comments
Open

Comments

@angian00
Copy link

angian00 commented Jun 1, 2011

Hello. I'd like to use just like I use a TableViewCOntroller with custom cells, that is: in viewForPage... I set a data property for my custom view:

  • (UIView *)viewForPageInPagingView:(ATPagingView *)pagingView atIndex:(NSInteger)index
    {
    GalleryPageView *view = (GalleryPageView *)[pagingView dequeueReusablePage];
    if (view == nil) {
    view = [[[GalleryPageView alloc] init] autorelease];
    }

    FeedItem *feedItem = [dataRoot objectAtIndex:index];
    view.feedItem = feedItem;

and then I perform some modifications to custom subviews of view by overwriting its layoutSubviews method.
But that method seems to be called only for the first couple of cells. so I can't do that. Am I missing something in TableView programming model? Where do you suggest I put my custom-subviews-code?

By the way: Thank you, good job.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant