Giter VIP home page Giter VIP logo

expandabletableview's People

Contributors

rondinellimorais avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

expandabletableview's Issues

Support for expanding multiple sections at once

It currently closes the other sections upon opening a new section, which doesn't allow for proper animations for UITableViewRowAnimations like .top, .bottom, .none. It only works well for .automatic, .fade, and .middle. I can provide an example if you would like.

Swift 3 remove C-Style for Statement

Hello, it is possible resolve the problem from Swift 3, now C-style for statement has been removed in Swift 3.

This lines of code:

for var i = 0; i < numberOfRows; i += 1 {
indexesPathToInsert.append(IndexPath(row: i, section: section))
}

And

for var i = 0 ; i < numberOfRows; i += 1 {
indexesPathToDelete.append(IndexPath(row: i, section: section))
}

Thank you

error on reloading tableView

my table gets reload after every 10 sec, and then if I tap on a section, app gets crashes with the error that before update no of rows in a section were different

customize header

hi, thanks for sharing this lib!

i just wanna ask, is it possible to customize header? lets say i wanna add some view / button in the header.
thanks

only one section

If only one section is need to show meanwhile section not expend

Change header after selecting a row in that section

How can I change the text in thelabel that I add to the the header view when a row in the table for that section is selected.

I tried the following. Here is my code

  • (UIView *)tableView:(UITableView *)myTableView viewForHeaderInSection:(NSInteger)section {
    NSLog(@"viewForHeaderInSection");
    HeaderView *headerView = [[HeaderView alloc] initWithTableView:tableView section:section];

    headerView.backgroundColor = [UIColor groupTableViewBackgroundColor];
    UILabel *label = [[UILabel alloc] init];
    label.frame = headerView.frame;
    label.tag = 101;
    [label setFrame:CGRectMake(headerView.frame.origin.x+10, headerView.frame.origin.y, headerView.frame.size.width-10, headerView.frame.size.height-1)];
    label.font = [UIFont systemFontOfSize:15.0f];
    label.text = [tableSections objectAtIndex:section];

    label.textColor = [UIColor blackColor];
    [headerView addSubview:label];

    CGRect sepFrame = CGRectMake(0, headerView.frame.size.height-1, 320, 1);
    UIView *seperatorView =[[UIView alloc] initWithFrame:sepFrame]; seperatorView.backgroundColor = [UIColor colorWithWhite:224.0/255.0 alpha:1.0];
    [headerView addSubview:seperatorView];

    return headerView;
    }

  • (void)tableView:(UITableView *)myTableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{
    changeSectionHeader = TRUE;
    selectedVenue = self.nearbyVenues[indexPath.row];
    NSLog(@"selected venue %@ - %@",[selectedVenue title], selectedVenue.category);
    UIView *headerView = [self tableView:self.tableView viewForHeaderInSection:whereSection];
    UILabel *label = (UILabel *)[headerView viewWithTag:101];
    label.text = selectedVenue.title;
    [myTableView deselectRowAtIndexPath:indexPath animated:TRUE];
    }

How do I access the label in the header view to change it's value?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.