Giter Site home page Giter Site logo

Comments (15)

randyarrowood avatar randyarrowood commented on September 25, 2024

i think i got it...

I changed the AppDelegate.m to have:

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{    
    RightViewController *rvc = [self.window.rootViewController.storyboard instantiateViewControllerWithIdentifier:@"rightViewID"];
    LeftViewController *lvc = [self.window.rootViewController.storyboard instantiateViewControllerWithIdentifier:@"leftViewID"];
    PaperFoldNavigationController *paperFoldNavController = [[PaperFoldNavigationController alloc] initWithRootViewController:self.window.rootViewController];
    [self.window setRootViewController:paperFoldNavController];

    [paperFoldNavController setLeftViewController:lvc width:150];
    [paperFoldNavController setRightViewController:rvc width:320.0 rightViewFoldCount:3 rightViewPullFactor:0.9];

    return YES;
}

from paperfold-for-ios.

honcheng avatar honcheng commented on September 25, 2024

So this is working now?
Thanks for letting me know.

from paperfold-for-ios.

randyarrowood avatar randyarrowood commented on September 25, 2024

yes... great control... thanks

from paperfold-for-ios.

honcheng avatar honcheng commented on September 25, 2024

Thanks

from paperfold-for-ios.

texastoland avatar texastoland commented on September 25, 2024

I subclassed nav controller to set side view controllers, view widths, and fold counts in IB interconnecting in storyboards them with custom segues. It probably wouldn't be too hard to encapsulate top and bottom folds too.

from paperfold-for-ios.

lucalodi avatar lucalodi commented on September 25, 2024

Hi,
I really cant get PaperFold to work with storyboard.
Any help or a tutorial would be great!

Thanks in advance,
Luca

from paperfold-for-ios.

texastoland avatar texastoland commented on September 25, 2024

Which class are you using and what problem are you running into?

from paperfold-for-ios.

lucalodi avatar lucalodi commented on September 25, 2024

I have a blank project just to test and build a solid prototype before implement into my def app.
So my setup:
storyboard with 2 tab and navigation control.

Now how can I implement PaperFold to whole app and slide a view from storyboard?

from paperfold-for-ios.

texastoland avatar texastoland commented on September 25, 2024
  • Subclass PaperFoldNavigationController
  • Add properties like @property (nonatomic, copy, readonly) NSString *rootViewControllerID, *leftViewControllerID, *rightViewControllerID;
  • Override -awakeFromNib like:
- (void)awakeFromNib {
  [super awakeFromNib];
  if (self.rootViewControllerID) {
    self.rootViewController = [self.storyboard instantiateViewControllerWithIdentifier:self.rootViewControllerID];
  }
  if (self.leftViewControllerID) {
    self.leftViewController = [self.storyboard instantiateViewControllerWithIdentifier:self.leftViewControllerID];
  }
  if (self.rightViewControllerID) {
    self.rightViewController = [self.storyboard instantiateViewControllerWithIdentifier:self.rightViewControllerID];
  }
}
  • Give the view controllers you want to embed Storyboard IDs
  • Add your custom PaperFoldNavigationController to the storyboard
  • Add User Defined Runtime Attributes linking your Storyboard IDs to your custom properties

This should get you mostly working?

@honcheng Would you be interested in a PR to improve storyboard integration?

from paperfold-for-ios.

honcheng avatar honcheng commented on September 25, 2024

Hi Jonathan,

What do you mean by PR?

On 26 Jan, 2013, at 12:34 PM, Jonathan Toland [email protected] wrote:

Subclass PaperFoldNavigationController
Add properties like @Property (nonatomic, copy, readonly) NSString *rootViewControllerID, *leftViewControllerID, *rightViewControllerID;
Override -awakeFromNib like:

  • (void)awakeFromNib {
    [super awakeFromNib];
    if (self.rootViewControllerID) {
    self.rootViewController = [self.storyboard instantiateViewControllerWithIdentifier:self.rootViewControllerID];
    }
    if (self.leftViewControllerID) {
    self.leftViewController = [self.storyboard instantiateViewControllerWithIdentifier:self.leftViewControllerID];
    }
    if (self.rightViewControllerID) {
    self.rightViewController = [self.storyboard instantiateViewControllerWithIdentifier:self.rightViewControllerID];
    }
    }
    Give the view controllers you want to embed Storyboard IDs
    Add your custom PaperFoldNavigationController to the storyboard
    Add User Defined Runtime Attributes linking your Storyboard IDs to your custom properties
    This should get you mostly working?

@honcheng Would you be interested in a PR to improve storyboard integration?


Reply to this email directly or view it on GitHub.

from paperfold-for-ios.

texastoland avatar texastoland commented on September 25, 2024

@honcheng Pull Request :neckbeard: I didn't know if you'd prefer to keep PaperfoldNavigationController simple. I also think PaperfoldMenuController should extend it. @lucalodi Any luck?

from paperfold-for-ios.

rlove1221 avatar rlove1221 commented on September 25, 2024

hello guys, having a little trouble trying to get it going into storyboard

from paperfold-for-ios.

seanherman avatar seanherman commented on September 25, 2024

Hey guys - can anybody post up there working version of this with storyboards? I've tried countless times to get this working with my storyboards, but it just isn't working. Any help would be GREATLY appreciated! :)

from paperfold-for-ios.

rlove1221 avatar rlove1221 commented on September 25, 2024

Hello ,i'm still having a little trouble as well . Would love to get some help also.

On Mar 17, 2013, at 9:13 PM, seanherman [email protected] wrote:

Hey guys - can anybody post up there working version of this with storyboards? I've tried countless times to get this working with my storyboards, but it just isn't working. Any help would be GREATLY appreciated! :)


Reply to this email directly or view it on GitHub.

from paperfold-for-ios.

amroelsherif avatar amroelsherif commented on September 25, 2024

why the content of left and right didn't appear while I see in the log that the views opened

from paperfold-for-ios.

Related Issues (20)

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.