修复应用后台后点击应用新建页面的问题
This commit is contained in:
parent
1384aa0307
commit
b137252a00
|
@ -1554,7 +1554,7 @@ public class MainActivity extends Activity {
|
||||||
super.onGeolocationPermissionsShowPrompt(origin, callback);
|
super.onGeolocationPermissionsShowPrompt(origin, callback);
|
||||||
}
|
}
|
||||||
|
|
||||||
// target="_blank" 处理,Android >11 崩溃无Log
|
// target="_blank" 处理,Android>11 崩溃无Log
|
||||||
@Override
|
@Override
|
||||||
public boolean onCreateWindow(WebView view, boolean isDialog, boolean isUserGesture, Message resultMsg) {
|
public boolean onCreateWindow(WebView view, boolean isDialog, boolean isUserGesture, Message resultMsg) {
|
||||||
Log.e("_blank", view + ", " + isDialog + "," + isUserGesture + ", " + resultMsg);
|
Log.e("_blank", view + ", " + isDialog + "," + isUserGesture + ", " + resultMsg);
|
||||||
|
@ -1584,7 +1584,7 @@ public class MainActivity extends Activity {
|
||||||
if (urln.contains("\n"))
|
if (urln.contains("\n"))
|
||||||
urln = urln.substring(urln.indexOf("\n") + 1);
|
urln = urln.substring(urln.indexOf("\n") + 1);
|
||||||
newWindow(urln);
|
newWindow(urln);
|
||||||
} else {
|
} else if (list_webView.size() == 0){
|
||||||
String surl = sharedPreferences.getString("homepage", "file:///android_asset/home.htm");
|
String surl = sharedPreferences.getString("homepage", "file:///android_asset/home.htm");
|
||||||
if (surl.equals(""))
|
if (surl.equals(""))
|
||||||
surl = "file:///android_asset/home.htm";
|
surl = "file:///android_asset/home.htm";
|
||||||
|
|
Loading…
Reference in New Issue