Hello, i'm programming a native module for iOS to integrate an oauth2 native SDK(i.e., FB, TW or G+), i've made almost everything but at least a problem is left. After the authorization phase the browser returns to the app passing to it the result of the authentication, well, i need to catch that result from within the module and pass it to a native function. In a native app i can add the following code inside the application delegate class:
- (BOOL)application: (UIApplication *)application openURL: (NSURL *)url sourceApplication: (NSString *)sourceApplication annotation: (id)annotation { // call the G+ sdk to handle the URL }In Titanium i can use Ti.App.getArguments()(although no sourceApplication is passed and this could be a problem), but what can i do to achieve this internally to a native iOS module? Perhaps registering a listener or something else? Is there a way to capture those arguments(url and sourceApplication)? Any help is really appreciated!
Thanx in advance for the answer!
-Giuseppe