mirror of
https://github.com/M66B/FairEmail.git
synced 2025-12-30 17:40:34 +01:00
Revised link handling
This commit is contained in:
@@ -2415,22 +2415,14 @@ public class FragmentCompose extends FragmentBase {
|
||||
};
|
||||
|
||||
private void handleFileShare() {
|
||||
final Intent intent = new Intent(Intent.ACTION_VIEW);
|
||||
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
|
||||
intent.setData(Uri.parse(Helper.FAQ_URI + "#user-content-faq49"));
|
||||
boolean resolves = (intent.resolveActivity(getContext().getPackageManager()) != null);
|
||||
|
||||
Snackbar sb = Snackbar.make(view,
|
||||
R.string.title_no_stream,
|
||||
resolves ? Snackbar.LENGTH_INDEFINITE : Snackbar.LENGTH_LONG);
|
||||
if (resolves)
|
||||
sb.setAction(R.string.title_info, new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
startActivity(intent);
|
||||
finish();
|
||||
}
|
||||
});
|
||||
Snackbar sb = Snackbar.make(view, R.string.title_no_stream, Snackbar.LENGTH_INDEFINITE);
|
||||
sb.setAction(R.string.title_info, new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
Helper.viewFAQ(getContext(), 49);
|
||||
finish();
|
||||
}
|
||||
});
|
||||
sb.show();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user