[ios] Updated to registation through browser.

This commit is contained in:
Ilya Grechuhin 2016-01-25 12:35:46 +03:00 committed by Sergey Yershov
parent 06650b46fd
commit bf29f97dcc
2 changed files with 12 additions and 1 deletions

View file

@ -5,6 +5,10 @@
#import "MWMAuthorizationWebViewLoginViewController.h"
#import "UIColor+MapsMeColor.h"
#include "editor/osm_auth.hpp"
using namespace osm;
@interface MWMAuthorizationLoginViewController ()
@property (weak, nonatomic) IBOutlet UIImageView * backgroundImage;
@ -79,6 +83,13 @@
// TODO: Add login
}
- (IBAction)signup
{
OsmOAuth const auth = OsmOAuth::ServerAuth();
NSURL * url = [NSURL URLWithString:@(auth.GetRegistrationURL().c_str())];
[[UIApplication sharedApplication] openURL:url];
}
- (IBAction)cancel
{
if (!self.isCalledFromSettings)

View file

@ -1852,7 +1852,7 @@ the world. Join us!</string>
<userDefinedRuntimeAttribute type="string" keyPath="localizedText" value="signup_now"/>
</userDefinedRuntimeAttributes>
<connections>
<segue destination="Ez0-RI-stE" kind="custom" customClass="MWMSegue" id="bQL-tw-mLS"/>
<action selector="signup" destination="iZ6-Zi-bkZ" eventType="touchUpInside" id="jMD-gB-R6e"/>
</connections>
</button>
</subviews>