100grams / hgpagescrollview Goto Github PK
View Code? Open in Web Editor NEWUIScrollView for iPhone with horizontal paging like mobile Safari tabs
UIScrollView for iPhone with horizontal paging like mobile Safari tabs
if yes please tell us some steps... thank you
[Session started at 2012-05-29 11:38:10 -0700.]
2012-05-29 11:40:18.146 HGPageScrollViewSample[2446:207] Completion YES
2012-05-29 11:40:22.272 HGPageScrollViewSample[2446:207] Completion NO
2012-05-29 11:40:43.039 HGPageScrollViewSample[2446:207] Completion YES
2012-05-29 11:40:44.905 HGPageScrollViewSample[2446:207] Completion NO
2012-05-29 11:40:46.695 HGPageScrollViewSample[2446:207] Completion YES
2012-05-29 11:40:47.831 HGPageScrollViewSample[2446:207] Completion NO
2012-05-29 12:23:37.462 HGPageScrollViewSample[2446:207] Completion YES
2012-05-29 12:23:39.147 HGPageScrollViewSample[2446:207] Completion NO
2012-05-29 12:23:40.436 HGPageScrollViewSample[2446:207] * Terminating app due to uncaught exception 'NSRangeException', reason: '* -[NSMutableArray objectAtIndex:]: index 2147483646 beyond bounds [0 .. 2]'
*** Call stack at first throw:
(
0 CoreFoundation 0x00f29be9 __exceptionPreprocess + 185
1 libobjc.A.dylib 0x0107e5c2 objc_exception_throw + 47
2 CoreFoundation 0x00f1f6e5 -[__NSArrayM objectAtIndex:] + 261
3 HGPageScrollViewSample 0x0000bf4e -[HGPageScrollView scrollViewDidScroll:] + 878
4 HGPageScrollViewSample 0x0000aff3 -[HGPageScrollView deletePagesAtIndexes:animated:] + 2035
5 HGPageScrollViewSample 0x0000435b -[HGPageScrollViewSampleViewController removePagesAtIndexSet:] + 203
6 HGPageScrollViewSample 0x0000424f -[HGPageScrollViewSampleViewController didClickRemovePage:] + 335
Steps to reproduce:
There's a crash in pageScrollView:viewForPageAtIndex:, "Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[__NSArrayM objectAtIndex:]: index 4294967295 beyond bounds for empty array'"
I'm trying the base implementation, but just can't seem to find a way to get this to work.
In my h file.
``
@interface MyScrollViewController : UIViewController <HGPageScrollViewDataSource, HGPageScrollViewDelegate>``
and m:
#import "MyScrollViewController.h"
@interface MyScrollViewController ()
@end
@implementation MyScrollViewController
- (void)viewDidLoad
`{
[super viewDidLoad];
// Do any additional setup after loading the view, typically from a nib.
HGPageScrollView *pageScrollView = [[[NSBundle mainBundle] loadNibNamed:@"HGPageScrollView" owner:self options:nil] objectAtIndex:0];
[self.view addSubview:pageScrollView];
}
``
In your markdown you note
least the required method in this protocol: pageScrollView:viewForPageAtIndex: But I dont really see anywhere that details this.
I tried mimicing what was in the sample file but I keep returning:
2012-09-10 14:25:48.913 MyScroll[21002:c07] * Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '* -[__NSArrayM insertObject:atIndex:]: object cannot be nil'
*** First throw call stack:
in your .h file it appears as NSMutableIndexSet *indexesToReload.
but you are allocating it as NSIndexSet.
Thanks any way
Great work
Shani
Hi:
I run(iPhone4 (iOS5, Xcode 4.2)) HGPageScrollView crash.I's crash log:
*** Terminating app due to uncaught exception 'UIViewControllerHierarchyInconsistency', reason: 'child view controller:<MyTableViewController: 0x1cc060> should have parent view controller:<HGPageScrollViewSampleViewController: 0x1c3860> but actual parent is:<UINavigationController: 0x1ccdf0>'
*** First throw call stack:
(0x341698bf 0x358851e5 0x341697b9 0x341697db 0x352181b9 0x351d97ef 0x351d92bf 0x351d918b 0x51c3 0x35b3 0x340c3435 0x351f19eb 0x352b73cf 0x340c3435 0x351f19eb 0x351f19a7 0x351f1985 0x351f16f5 0x351f202d 0x351f050f 0x351eff01 0x351d64ed 0x351d5d2d 0x35d00df3 0x3413d553 0x3413d4f5 0x3413c343 0x340bf4dd 0x340bf3a5 0x35cfffcd 0x35204743 0x211d 0x20dc)
help me.
Can I disable scrolling on two screens? I need to scroll no more than one.
I was trying to scroll horizontally from the sample project and I often it crashes with the following error:
2011-12-11 05:11:34.721 HGPageScrollViewSample[9425:f803] *** Terminating app due to uncaught exception 'UIViewControllerHierarchyInconsistency', reason: 'child view controller:<MyTableViewController: 0x6e6d600> should have parent view controller:<HGPageScrollViewSampleViewController: 0x6e633c0> but actual parent is:<UINavigationController: 0x6e6d7b0>'
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.