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

Nativescript iOS 5.1.1 #1

Open
mspusta78 opened this issue Feb 11, 2019 · 2 comments
Open

Nativescript iOS 5.1.1 #1

mspusta78 opened this issue Feb 11, 2019 · 2 comments

Comments

@mspusta78
Copy link

iOS simulator as well as the real device experience issues when using this plugin

Here are the errors:

platforms/ios/Pods/JSQWebViewController/Source/WebViewController.swift:171:14: error: 'bringSubview(toFront:)' has been renamed to 'bringSubviewToFront(_:)'

I was able to get this error fixed by changing
view.bringSubview(toFront: progressBar)
to
view.bringSubviewToFront(_: progressBar)

But then I keep getting more errors with RealmSwift
invalid redeclaration of 'replacesubrange(_:with:)' realmswift

@mspusta78
Copy link
Author

Here is a solution to this issue:

  1. In the FolioReaderKit.swift you need to add
    @objc open func presentReader

  2. Replace FolioReaderPage.swift with the
    https://github.com/FolioReader/FolioReaderKit/blob/master/Source/FolioReaderPage.swift

  3. in the epub-reader.ios.js change

FolioReader.presentReaderWithParentViewControllerWithEpubPathAndConfigShouldRemoveEpubAnimated(frame_1.topmost().currentPage.ios, bookPath, this._config, false, true);

to

var fr = FolioReader.alloc();
fr.presentReaderWithParentViewControllerWithEpubPathUnzipPathAndConfigShouldRemoveEpubAnimated(frame_1.topmost().currentPage.ios, bookPath, null, this._config, false, true);

@pravinkumarputta
Copy link
Owner

@mspusta78 Thanks for the solution. I'll update this with my library.

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

2 participants