本文整理汇总了Java中org.telegram.messenger.browser.Browser.isInternalUrl方法的典型用法代码示例。如果您正苦于以下问题:Java Browser.isInternalUrl方法的具体用法?Java Browser.isInternalUrl怎么用?Java Browser.isInternalUrl使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.telegram.messenger.browser.Browser
的用法示例。
在下文中一共展示了Browser.isInternalUrl方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: showOpenUrlAlert
import org.telegram.messenger.browser.Browser; //导入方法依赖的package包/类
public void showOpenUrlAlert(final String url) {
if (Browser.isInternalUrl(url)) {
Browser.openUrl(getParentActivity(), url, inlineReturn == 0);
} else {
AlertDialog.Builder builder = new AlertDialog.Builder(getParentActivity());
builder.setMessage(LocaleController.formatString("OpenUrlAlert", R.string.OpenUrlAlert, url));
builder.setTitle(LocaleController.getString("AppName", R.string.AppName));
builder.setPositiveButton(LocaleController.getString("Open", R.string.Open), new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialogInterface, int i) {
Browser.openUrl(getParentActivity(), url, inlineReturn == 0);
}
});
builder.setNegativeButton(LocaleController.getString("Cancel", R.string.Cancel), null);
showDialog(builder.create());
}
}
示例2: showOpenUrlAlert
import org.telegram.messenger.browser.Browser; //导入方法依赖的package包/类
public void showOpenUrlAlert(final String url, boolean ask) {
if (Browser.isInternalUrl(url) || !ask) {
Browser.openUrl(getParentActivity(), url, inlineReturn == 0);
} else {
AlertDialog.Builder builder = new AlertDialog.Builder(getParentActivity());
builder.setTitle(LocaleController.getString("AppName", R.string.AppName));
builder.setMessage(LocaleController.formatString("OpenUrlAlert", R.string.OpenUrlAlert, url));
builder.setPositiveButton(LocaleController.getString("Open", R.string.Open), new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialogInterface, int i) {
Browser.openUrl(getParentActivity(), url, inlineReturn == 0);
}
});
builder.setNegativeButton(LocaleController.getString("Cancel", R.string.Cancel), null);
showDialog(builder.create());
}
}
示例3: showOpenUrlAlert
import org.telegram.messenger.browser.Browser; //导入方法依赖的package包/类
public void showOpenUrlAlert(final String url, boolean ask) {
if (Browser.isInternalUrl(url) || !ask) {
Browser.openUrl(getParentActivity(), url, true);
} else {
AlertDialog.Builder builder = new AlertDialog.Builder(getParentActivity());
builder.setTitle(LocaleController.getString("AppName", R.string.AppName));
builder.setMessage(LocaleController.formatString("OpenUrlAlert", R.string.OpenUrlAlert, url));
builder.setPositiveButton(LocaleController.getString("Open", R.string.Open), new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialogInterface, int i) {
Browser.openUrl(getParentActivity(), url, true);
}
});
builder.setNegativeButton(LocaleController.getString("Cancel", R.string.Cancel), null);
showDialog(builder.create());
}
}
示例4: showOpenUrlAlert
import org.telegram.messenger.browser.Browser; //导入方法依赖的package包/类
public void showOpenUrlAlert(final String url, boolean ask) {
if (Browser.isInternalUrl(url, null) || !ask) {
Browser.openUrl(getParentActivity(), url, true);
} else {
AlertDialog.Builder builder = new AlertDialog.Builder(getParentActivity());
builder.setTitle(LocaleController.getString("AppName", R.string.AppName));
builder.setMessage(LocaleController.formatString("OpenUrlAlert", R.string.OpenUrlAlert, url));
builder.setPositiveButton(LocaleController.getString("Open", R.string.Open), new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialogInterface, int i) {
Browser.openUrl(getParentActivity(), url, true);
}
});
builder.setNegativeButton(LocaleController.getString("Cancel", R.string.Cancel), null);
showDialog(builder.create());
}
}
示例5: showOpenUrlAlert
import org.telegram.messenger.browser.Browser; //导入方法依赖的package包/类
public void showOpenUrlAlert(final String url, boolean ask) {
if (Browser.isInternalUrl(url, null) || !ask) {
Browser.openUrl(getParentActivity(), url, inlineReturn == 0);
} else {
AlertDialog.Builder builder = new AlertDialog.Builder(getParentActivity());
builder.setTitle(LocaleController.getString("AppName", R.string.AppName));
builder.setMessage(LocaleController.formatString("OpenUrlAlert", R.string.OpenUrlAlert, url));
builder.setPositiveButton(LocaleController.getString("Open", R.string.Open), new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialogInterface, int i) {
Browser.openUrl(getParentActivity(), url, inlineReturn == 0);
}
});
builder.setNegativeButton(LocaleController.getString("Cancel", R.string.Cancel), null);
showDialog(builder.create());
}
}