Coder Social home page Coder Social logo

rgpageviewcontroller's People

Contributors

ergoon avatar hsoi avatar ronnygym 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  avatar

rgpageviewcontroller's Issues

two func is missing in the RGPageViewControllerDelegate

cannot find the following 2 optional func on RGPageViewControllerDelegate,and these two func was introduced in the README.md
qq20150729-1 2x

optional func colorForTabIndicator() -> UIColor

optional func tintColorForTabBar() -> UIColor?
qq20150729-2 2x

Navbar bottom border line

I have RGPageViewController in NavigationController. It is working as expected. However, the bottom border line is missing from Navigation Bar when user opens a view controller from the RGPageViewController. I am not sure if this is related with RGPageViewController.

"bar view" and "navigationItem" has a blank

It seems that barTop no fit for me ,I ignore by adding a debug flag

let yeshen_debug = false
"
var barTop: CGFloat = tabbarTop
// remove hairline image in navigation bar if attached to top
if let navController = navigationController where !navController.navigationBar.hidden {
barTop = tabbarTop + 44
navController.navigationBar.hideHairline()
}
"
if(yeshen_debug){ barTop = 0 }

viewControllerForPageAtIndex being called twice

Hello,
I have a problem that sometimes, the viewControllerForPageAtIndex function is being called twice when a new page is loaded. This prevents me from calling javascript on the current web view.

Use Auto Layout and SizeClasses

2015-02-02 20:15:46.899 微事通[7571:208641] The view hierarchy is not prepared for the constraint: <NSLayoutConstraint:0x7f947bd87220 V:[_UILayoutGuide:0x7f947bd700f0]-(0)-[UIToolbar:0x7f947bf22390]>
When added to a view, the constraint's items must be descendants of that view (or the view itself). This will crash if the constraint needs to be resolved before the view hierarchy is assembled. Break on -[UIView _viewHierarchyUnpreparedForConstraint:] to debug.
2015-02-02 20:15:46.900 微事通[7571:208641] *** Assertion failure in -[UIView _layoutEngine_didAddLayoutConstraint:roundingAdjustment:mutuallyExclusiveConstraints:], /SourceCache/UIKit_Sim/UIKit-3318.16.14/NSLayoutConstraint_UIKitAdditions.m:560
2015-02-02 20:15:46.903 微事通[7571:208641] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Impossible to set up layout with view hierarchy unprepared for constraint.'
*** First throw call stack:
(
0 CoreFoundation 0x0000000107483f35 __exceptionPreprocess + 165
1 libobjc.A.dylib 0x0000000109478bb7 objc_exception_throw + 45
2 CoreFoundation 0x0000000107483d9a +[NSException raise:format:arguments:] + 106
3 Foundation 0x0000000107b5e5df -[NSAssertionHandler handleFailureInMethod:object:file:lineNumber:description:] + 195
4 UIKit 0x000000010883acf2 __120-[UIView(UIConstraintBasedLayout) _layoutEngine_didAddLayoutConstraint:roundingAdjustment:mutuallyExclusiveConstraints:]_block_invoke_2 + 177
5 UIKit 0x000000010883abe7 -[UIView(UIConstraintBasedLayout) _layoutEngine_didAddLayoutConstraint:roundingAdjustment:mutuallyExclusiveConstraints:] + 377
6 UIKit 0x000000010883aea4 -[UIView(UIConstraintBasedLayout) _tryToAddConstraintWithoutUpdatingConstraintsArray:roundingAdjustment:mutuallyExclusiveConstraints:] + 30
7 UIKit 0x000000010883afcc -[UIView(UIConstraintBasedLayout) _tryToAddConstraint:roundingAdjustment:mutuallyExclusiveConstraints:] + 243
8 UIKit 0x000000010883b30b __50-[UIView(UIConstraintBasedLayout) addConstraints:]_block_invoke + 188
9 Foundation 0x0000000107ae7d6e -[NSISEngine withBehaviors:performModifications:] + 155
10 UIKit 0x000000010883b240 -[UIView(UIConstraintBasedLayout) addConstraints:] + 263
11 微事通 0x0000000107134cad TFCX11DkqqBDbtsAb20RGPageViewController14layoutSubviewsfS0_FT_T + 10301
12 微事通 0x000000010713239c TFCX11DkqqBDbtsAb20RGPageViewController22viewWillLayoutSubviewsfS0_FT_T + 60
13 微事通 0x00000001071323d2 TToFCX11DkqqBDbtsAb20RGPageViewController22viewWillLayoutSubviewsfS0_FT_T + 34
14 UIKit 0x00000001082398da -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 368
15 QuartzCore 0x000000010804bde8 -[CALayer layoutSublayers] + 150
16 QuartzCore 0x0000000108040a0e _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 380
17 UIKit 0x000000010822d847 -[UIView(Hierarchy) layoutBelowIfNeeded] + 611
18 UIKit 0x0000000108321f06 -[UITabBarController _layoutViewController:] + 500
19 UIKit 0x0000000108322014 -[UITabBarController _wrapperViewForViewController:] + 252
20 UIKit 0x0000000108328e92 -[UITabBarController transitionFromViewController:toViewController:transition:shouldSetSelected:] + 378
21 UIKit 0x0000000108325069 -[UITabBarController _setSelectedViewController:] + 311
22 UIKit 0x00000001082315ce +[UIView(Animation) performWithoutAnimation:] + 65
23 UIKit 0x0000000108322106 -[UITabBarController _selectDefaultViewControllerIfNecessaryWithAppearanceTransitions:] + 221
24 UIKit 0x0000000108322dfe -[UITabBarController viewWillAppear:] + 121
25 UIKit 0x00000001082e9821 -[UIViewController _setViewAppearState:isAnimating:] + 487
26 UIKit 0x00000001082c3cd8 __56-[UIPresentationController runTransitionForCurrentState]_block_invoke + 567
27 UIKit 0x00000001081e3331 _applyBlockToCFArrayCopiedToStack + 314
28 UIKit 0x00000001081e31ab _afterCACommitHandler + 516
29 CoreFoundation 0x00000001073b8dc7 CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION + 23
30 CoreFoundation 0x00000001073b8d20 __CFRunLoopDoObservers + 368
31 CoreFoundation 0x00000001073aeb53 __CFRunLoopRun + 1123
32 CoreFoundation 0x00000001073ae486 CFRunLoopRunSpecific + 470
33 GraphicsServices 0x000000010c1679f0 GSEventRunModal + 161
34 UIKit 0x00000001081c0420 UIApplicationMain + 1282
35 微事通 0x000000010715ad3e top_level_code + 78
36 微事通 0x000000010715ad7a main + 42
37 libdyld.dylib 0x0000000109c52145 start + 1
38 ??? 0x0000000000000001 0x0 + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException

Center Tabs

Is there a way I can center the tabs to have equal widths. My tabs are only 2 displayed at the top

Compile errors

As suggested in "Install" section of Readme, I just copy RGPageViewController.swift file in my project.

Unfortunately there are a lot of compile errors, first at line 142:

        self.view.addConstraints(constraints)

"Cannot invoke 'addContraints' with an argument list of type '(NSMutableArray!)'"

Other errors are all where you use "as" with the error:

" 'Any object' is not convertible to .... :did you mean to use 'as!' to force downcast?"

How to add rightBarButtonItem

This is a awesome lib and thank you for that , Can you tell how to add navigationItem.rightBarButtonItem in UIViewController i have try adding rightButton in UIViewController but it will not showed in my UI, but when i add bar button on RGPageViewController it showed perfectly can you tell me how to add button from my UIViewContorller ? because it need to access the content of my UIViewController when button clicked

Working with Vertical and Vertical ScrollView

Does anyone have this working well? It seems to not be consistent, instead of switching views at bottom of list it switches sometimes before. Sometimes it does not switch at all. I believe this is because the two gestures (ScrollView down/up swipe) and PageView are conflicting.

willChangePageTo not being called

Hi,

above mentioned problem presents itself when adding:
func pageViewController(_ pageViewController: RGPageViewController, willChangePageTo index: Int, fromIndex from: Int) { print("Will change page") }

I inserted it into your example and it wasn't called either.

FloatRatingView Error

Error overriding touchesBegan, touchesMoved, touchesEnded

"Error overriding method with selector 'touchesMoved:
withEvent' has incompatible type.... "

[Issue] Working with UITabBarController

First of all, thanks for sharing your pager with us...Unfortunately I am having problem when using your library.

When I applied this example with UITabBarController, there are some issue.

1. View Between Pager Tab and TabBarItem can't scroll to down completely.
tabbar portrait mode

2. This issue may be related to view controller constraints inside pager and tabbar. Can't tell for sure yet. But, please take a look
tabbar landscape mode

If you don't mind, updating example project with UITabBarController and TopBar support is appreciated. So, I can check if I am doing anything wrong.

Best Regards

How to add rightBarButtonItem

This is a awesome lib and thank you for that , Can you tell how to add navigationItem.rightBarButtonItem in UIViewController i have try adding rightButton in UIViewController but it will not showed in my UI, but when i add bar button on RGPageViewController it showed perfectly can you tell me how to add button from my UIViewContorller ? because it need to access the content of my UIViewController when button clicked

[FAQ] Working with others UIViewController

This was just a request for your example project update because it only show using it with Single View Controller inside Pager.

So, how do we use it for different UIViewController?

Any Help?

Attempt to present view whose view is not in the window hierarchy

Hello,
How to present an alert view from my content view controller ? When I perform alertView.show() I got this error in the console:

Attempt to present <UIAlertController: 0x7fb321cdba20> on <_UIAlertShimPresentingViewController: 0x7fb321c68390> whose view is not in the window hierarchy!

Thanks for your help

hi. need your help

if i use your code like this :
let cv = MainViewController()
window!.rootViewController = UINavigationController(rootViewController: cv)

view look some bugs.

Tab bar hidding content

Hello,
I used your awesome project in my app but the tab bar hide a part of my table view. How to fix that ?

Thanks

Working as one tab

Hi I'm using RGPageViewController with multiple tabs and its working good
But when I try to use it with only 1 tab its freezing in the below line

  tabScrollView.layoutIfNeeded()

Do you know how can I fix that?

if a page is UITableViewController, then tabBar is covering some top area of UITableViewController page.

  1. I add UITableiViewController to Example's storyboard

  2. code change below
    ` func pageViewController(_ pageViewController: RGPageViewController, viewControllerForPageAt index: Int) -> UIViewController? {
    if (movies.count == 0) || (index >= movies.count) {
    return nil
    }

    // Create a new view controller and pass suitable data.
    let dataViewController = storyboard!.instantiateViewController(withIdentifier: "tableView") as! UITableViewController

    //dataViewController.movieData = movies[index]

    return dataViewController
    }`

  3. tab bar cover top part of UITableViewController
    simulator screen shot may 18 2017 4 38 29 pm

Rotating Issue?

First of all,its the first library which can use dynamic tab and dynamic content for each tab without need to initiate view controllers manually like other library do.You just use one controller and change data according to each index.Yeah pretty smart one.Thanks for your hard work...

But,I really do have some problem.If you have some time,can you fix it?
screenshot 2016-04-14 02 34 00

When rotating the device,it appear like that..

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.