|
|
@ -73,15 +73,9 @@ public class LightningChromeClient extends WebChromeClient { |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
Uri uri = Uri.parse(url); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (uri.getHost() == null) { |
|
|
|
|
|
|
|
return; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
mFaviconModel.cacheFaviconForUrl(icon, url) |
|
|
|
mFaviconModel.cacheFaviconForUrl(icon, url) |
|
|
|
.subscribeOn(Schedulers.io()) |
|
|
|
.subscribeOn(Schedulers.io()) |
|
|
|
.subscribe(); |
|
|
|
.subscribe(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -114,21 +108,21 @@ public class LightningChromeClient extends WebChromeClient { |
|
|
|
org = origin; |
|
|
|
org = origin; |
|
|
|
} |
|
|
|
} |
|
|
|
builder.setMessage(org + mActivity.getString(R.string.message_location)) |
|
|
|
builder.setMessage(org + mActivity.getString(R.string.message_location)) |
|
|
|
.setCancelable(true) |
|
|
|
.setCancelable(true) |
|
|
|
.setPositiveButton(mActivity.getString(R.string.action_allow), |
|
|
|
.setPositiveButton(mActivity.getString(R.string.action_allow), |
|
|
|
new DialogInterface.OnClickListener() { |
|
|
|
new DialogInterface.OnClickListener() { |
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public void onClick(DialogInterface dialog, int id) { |
|
|
|
public void onClick(DialogInterface dialog, int id) { |
|
|
|
callback.invoke(origin, true, remember); |
|
|
|
callback.invoke(origin, true, remember); |
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
}) |
|
|
|
.setNegativeButton(mActivity.getString(R.string.action_dont_allow), |
|
|
|
.setNegativeButton(mActivity.getString(R.string.action_dont_allow), |
|
|
|
new DialogInterface.OnClickListener() { |
|
|
|
new DialogInterface.OnClickListener() { |
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public void onClick(DialogInterface dialog, int id) { |
|
|
|
public void onClick(DialogInterface dialog, int id) { |
|
|
|
callback.invoke(origin, false, remember); |
|
|
|
callback.invoke(origin, false, remember); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
AlertDialog alert = builder.create(); |
|
|
|
AlertDialog alert = builder.create(); |
|
|
|
alert.show(); |
|
|
|
alert.show(); |
|
|
|
BrowserDialog.setDialogSize(mActivity, alert); |
|
|
|
BrowserDialog.setDialogSize(mActivity, alert); |
|
|
|