Git Product home page Git Product logo

cotalkerpartners / mbxpageviewcontroller Goto Github PK

View Code? Open in Web Editor NEW
159.0 159.0 36.0 22.8 MB

A library that allows to have a UIPageController with control buttons (One per VC / Left-Right Buttons) or an UISegmentController. This is not a difficult task, but the intention of this library is to make it extremely easy, clean and fast. We resemble the use of a UITableView in a UIViewController.

License: MIT License

Objective-C 98.07% Ruby 1.93%

mbxpageviewcontroller's People

Contributors

gustavogervasio avatar nicarq avatar readmecritic 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  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  avatar

mbxpageviewcontroller's Issues

Scrolling Issue

Hi Using Your MBX(*segment) Control everything is fine but when we scroll(swiping) thirdViewController methods gets called in secondViewController any help

跳转问题

好像直接点击segementItem...他的每个控制器的数据请求都会走一遍?

I want Xib into code, but can not add?

Hi,Thank you Code!
I want Xib into code, but can not add, I hope to help me.
Thanks again!

@interface AcceptPKViewController () <MBXPageControllerDataSource, MBXPageControllerDataDelegate>
@Property (nonatomic, strong) UISegmentedControl segmentController;
@Property (nonatomic, strong) UIView *containerView;
@Property (nonatomic, strong) MBXPageViewController
MBXPageController;

@EnD

@implementation AcceptPKViewController

  • (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.

    self.MBXPageController = [[MBXPageViewController alloc] init];
    self.MBXPageController.MBXDataSource = self;
    self.MBXPageController.MBXDataDelegate = self;
    self.MBXPageController.pageMode = MBX_SegmentController;
    [self.MBXPageController reloadPages];

}

pragma mark - MBXPageViewController Data Source

  • (NSArray *)MBXPageButtons
    {
    self.segmentController = [[UISegmentedControl alloc] initWithItems:@[@"BOSS",@"TASK"]];
    self.segmentController.selectedSegmentIndex = 0;
    self.segmentController.highlighted = NO;
    self.segmentController.frame = CGRectMake(10, 5, 300, 35);
    return @[self.segmentController];
    }

  • (UIView *)MBXPageContainer
    {
    self.containerView = [[UIView alloc] init];
    self.containerView.frame = DF_FRAME(0, 80, kScreenWidth, 49);
    self.containerView.backgroundColor = [UIColor yellowColor];

    return self.containerView;
    }

  • (NSArray *)MBXPageControllers
    {
    VisitBossViewController *visitBossViewController = [[VisitBossViewController alloc] init];
    TasksViewController *taskViewController = [[TasksViewController alloc] init];

    return @[visitBossViewController,taskViewController];
    }

pragma mark - MBXPageViewController Delegate

  • (void)MBXPageChangedToIndex:(NSInteger)index
    {
    NSLog(@"%@ %ld", [self class], (long)index);
    }

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.