Linux compatibility fixes
This commit is contained in:
parent
9e83bfec47
commit
80bf6388c9
4 changed files with 5 additions and 3 deletions
|
@ -45,6 +45,8 @@
|
|||
}
|
||||
|
||||
- (void)webView:(WebView *)sender didFinishLoadForFrame:(WebFrame *)frame {
|
||||
|
||||
[sender stringByEvaluatingJavaScriptFromString:@"var OS_TYPE = 'mac';"];
|
||||
|
||||
if (sender == oauthView) {
|
||||
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<link rel="stylesheet" href="css/default.css" type="text/css" />
|
||||
<script data-main="scripts/main" src="scripts/lib/vendor/require-jquery.js"></script>
|
||||
<script type="text/javascript">alert(go)</script>
|
||||
</head>
|
||||
<body>
|
||||
</body>
|
||||
|
|
|
@ -52,6 +52,7 @@ function(HostApp, Paths, Hmac) {
|
|||
var those = this;
|
||||
Paths.findProfileURL(entity,
|
||||
function(profile_url) {
|
||||
|
||||
if (profile_url && (profile_url.startsWith("http://") || profile_url.startsWith("https://"))) {
|
||||
those.register(profile_url);
|
||||
} else {
|
||||
|
@ -92,7 +93,7 @@ function(HostApp, Paths, Hmac) {
|
|||
|
||||
this.state = Hmac.makeid(19);
|
||||
var auth = "/oauth/authorize?client_id=" + register_data["id"]
|
||||
+ "&redirect_uri=" + escape(this.app_info["redirect_uris"][0])
|
||||
+ "&redirect_uri=" + this.app_info["redirect_uris"][0] // Check if this still works on mac
|
||||
+ "&scope=" + Object.keys(this.app_info["scopes"]).join(",")
|
||||
+ "&state=" + this.state
|
||||
+ "&tent_post_types=all";
|
||||
|
|
|
@ -25,7 +25,7 @@ define(function() {
|
|||
if (OS_TYPE == "mac") {
|
||||
controller.openURL_(url);
|
||||
} else {
|
||||
controller.openURL(URL);
|
||||
controller.openURL(url);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Reference in a new issue