|
|
@@ -167,20 +167,20 @@ public class WebActivity extends Activity { |
|
|
|
public void showSource(final String html) { |
|
|
|
//获取网页内容,用于判断是否成功绑定关系id |
|
|
|
|
|
|
|
try { |
|
|
|
if (html.contains("成功")) {//成功 |
|
|
|
// Toast.makeText(WebActivity.this, "授权成功", Toast.LENGTH_SHORT).show(); |
|
|
|
setResult(222222); |
|
|
|
finish(); |
|
|
|
} else {//失败 |
|
|
|
setResult(111111); |
|
|
|
mainWeb.setAlpha(0); |
|
|
|
finish(); |
|
|
|
} |
|
|
|
|
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
// try { |
|
|
|
// if (html.contains("成功")) {//成功 |
|
|
|
// // Toast.makeText(WebActivity.this, "授权成功", Toast.LENGTH_SHORT).show(); |
|
|
|
// setResult(222222); |
|
|
|
// finish(); |
|
|
|
// } else {//失败 |
|
|
|
// setResult(111111); |
|
|
|
// mainWeb.setAlpha(0); |
|
|
|
// finish(); |
|
|
|
// } |
|
|
|
// |
|
|
|
// } catch (Exception e) { |
|
|
|
// e.printStackTrace(); |
|
|
|
// } |
|
|
|
} |
|
|
|
|
|
|
|
@JavascriptInterface |
|
|
|