Closed 9teen90nine closed 10 years ago
Hi! Thank you for reporting.
Hmm... Can you show me your code? Where and when are you calling methods etc?
I am getting following error:
I have changed my app ID to a random one, so you could use your own app ID. I would never post such an issue if I had some info in debugger.
my code
//SKPViewController.m
//SKPViewController.h
@interface SKPViewController : UIViewController
@end
My delegate methods are in the upper post.
@9teen90nine hm... can you just change your app ID in my standard project which comes in VK iOS SDK and rerun it? Want to see which delegate methods are called at all.
and also, don't import each class apart, import VkontakteSDK.h file.
2013-11-08 18:59:09.632 Project[66432:70b] -[ASAAppDelegate VKConnector:willShowModalView:] 2013-11-08 18:59:16.985 Project[66432:70b] -[ASAAppDelegate VKConnector:accessTokenRenewalFailed:] 2013-11-08 18:59:16.985 Project[66432:70b] -[ASAAppDelegate VKConnector:willHideModalView:] I have clicked "Cancel" on login popup. All done with my app ID.
@9teen90nine so, as I can see all is working fine?
In your test app for sure, but it doesn't work in my app at all. Not a single line in the debugger.
@9teen90nine need to see your code (project), cannot say what is wrong with information you gave.
@9teen90nine if there is any other way I can help you, let me know.
Maybe you forgot to add QuartzCore.framework? Maybe your requests are timed out?
I recommend you to implement all VKConnectorDelegate's methods and to check which one are called.
I'm kinda drunk now, so I'll try tomorrow. I have installed the framework using cocoapods, but also added the quartzcore framework manually. I'll post some more code tomorrow.
@9teen90nine tomorrow has come! please, update your version of SDK and try again.
So I have updated to v. 4.1.7 (using cocoapods), and updated the auth call UIWebView *wview = [[UIWebView alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; [[VKConnector sharedInstance] startWithAppID:@"3985619" permissons:[NSArray arrayWithObject:@"wall"] webView:wview delegate:self]; but I still don't see any webviews presented. Now I'm getting these messages in debugger: 2013-11-11 09:23:36.663 Skyport[12208:907] +[VKConnector sharedInstance] 2013-11-11 09:23:36.664 Skyport[12208:907] -[VKConnector startWithAppID:permissons:webView:delegate:] each time I press login button. I use navigation controller as a rootviewcontroller and storyboards, if that helps.
@9teen90nine your uiwebview is hidden or not when a call to startWithApp: starts?
So, I've figured it out. I don't know what was the original issue in v.3.2.1, but in 4.1.7 the issue was in weak UIWebView (which got deleted by the ARC). Actually, I'd suggest keeping function defenitions between versions, because it would be a bit painful to update the code for each upgrade. You can deprecate methods, but as soon as there's no on-line documentation there's no way to figure it out without diving into your code.
@9teen90nine I am testing now SDK, installed from pods and have the same problem - white screen and thats all... no uiwebview. I'll fix this as soon as possible.
About deprecated methods - you are right, but its quite uncomfortable to have 2-3 methods with the same code logic but with different names. It's my fault that I have created all new versions in a single branch. New version = new branch. Online documentation is coming. Few days and I'll translate code comments (documentation) and after that add GH-Pages tutorials.
@9teen90nine it works fine. See my code:
- (void)viewDidLoad
{
[super viewDidLoad];
// Do any additional setup after loading the view, typically from a nib.
webView = [[UIWebView alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
[self.view addSubview:webView];
[[VKConnector sharedInstance] startWithAppID:@"3541027"
permissons:@[@"wall"]
webView:webView
delegate:self];
}
Yep, I've already got it working - the issue was that I created UIWebView in the IBAction call, and it was deleted by ARC.
@9teen90nine glad to hear that!
[[VKConnector sharedInstance] startWithAppID:@"3985619" permissons:[NSArray arrayWithObject:@"wall"] delegate:self]; This call neither shows auth window, nor calls any of
-(void)VKConnector:(VKConnector )connector accessTokenRenewalFailed:(VKAccessToken )accessToken { NSLog(@"Fail :("); } delegate methods. Am I doing something wrong? Xcode 5.0.1, ios 6.1.3