ITeye博客

Cell

xserver · 2013-05-16 14:32 · Objective-C Primer · 编程语言 · Markdown

  • (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { selectedCellIndexPath = indexPath;

    withRowAnimation:UITableViewRowAnimationNone];

    ; }

  • (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath { if(selectedCellIndexPath != nil && == NSOrderedSame)

      return kTableViewExpandRowHeight;
    

    else return kTableViewCollapseRowHeight; }

  • (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { ; }

填星星,demo,AdvancedTableViewCells

  • (void)drawRect:(CGRect)rect { CGPoint ratingImageOrigin = CGPointMake(81.0, 45.0); UIImage *ratingBackgroundImage = ; ;

    UIImage *ratingForegroundImage = ;

    UIRectClip(CGRectMake(ratingImageOrigin.x, ratingImageOrigin.y, ratingForegroundImage.size.width * (_cell.rating / MAX_RATING), ratingForegroundImage.size.height));

    ; }

  • (void)_commonInit { backgroundImageView = initWithImage:]; backgroundImageView.contentMode = UIViewContentModeLeft; ;

    foregroundImageView = initWithImage:]; foregroundImageView.contentMode = UIViewContentModeLeft; foregroundImageView.clipsToBounds = YES; ; }

    UITableView *tab;

    BOOL animations = ; ; ; ; ;

评论(0)

暂无评论。

评论功能维护中,当前仅展示历史评论。