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

IOS 11 not show Button "Done" #140

Open
0xhakawai opened this issue Oct 3, 2017 · 7 comments
Open

IOS 11 not show Button "Done" #140

0xhakawai opened this issue Oct 3, 2017 · 7 comments

Comments

@0xhakawai
Copy link

simulator screen shot - iphone 6 - 2017-10-03 at 23 33 18

@drosenstark
Copy link

drosenstark commented Nov 5, 2017

Weirder: for me this happens only on iPhone (not iPad)... looking into this now.

@drosenstark
Copy link

I'll have to actually do a fork and fix this, but for now, you can create this method in ELCAssetTablePicker

- (void) prepInstanceVariablesWithNavigationItem:(UINavigationItem *)item {
    if (self.immediateReturn) { return ; }
    UIBarButtonItem *doneButtonItem = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemDone target:self action:@selector(doneAction:)];
    [item setRightBarButtonItem:doneButtonItem];
    [item setTitle:NSLocalizedString(@"Loading...", nil)];
}

and then you need to call it from didSelectRowAtIndexPath in ELCAlbumPickerController.m

[picker prepInstanceVariablesWithNavigationItem:self.navigationItem];

@stasian23
Copy link

but what about back button? how did you fix it?

@sashakid
Copy link

sashakid commented Jul 7, 2018

@drosenstark didn't find any fork in your account, so I've made it by myself as temp solution https://github.com/sashakid/ELCImagePickerController

@WeiLiangTan
Copy link

Have anyone found the root cause for this?
It doesn't seems to be this image picker's problem.
I tried adding 2 viewcontrollers and presenting it modally with a navigation controller and the same issue occurs

https://forums.developer.apple.com/thread/103854

@WeiLiangTan
Copy link

WeiLiangTan commented Jul 30, 2018

I'm not sure if my case is same as yours. I hope this would help.

In my project, my main navigation controller's view is a subview of the another ViewController with only one line of code
[self.containerView addSubview:containedNavigationController.view];

As the containedNavigationController wasn't added as a child view controller, according to Apple's engineer, it breaks many of the connections needed for this to work properly.

So I was suggested to update the code to
[containedNavigationController willMoveToParentViewController:self];
[self.containerView addSubview:containedNavigationController.view];
[self addChildViewController:containedNavigationController];

And this resolved the problem in my project.

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

6 participants
@drosenstark @sashakid @0xhakawai @WeiLiangTan @stasian23 and others