1
0
Fork 1

Better no app message for some schemes

(cherry picked from commit 1c272b1fff878d32edc1c8457a8f0381a07cf225)
This commit is contained in:
Stephen Paul Weber 2024-11-09 16:39:58 -05:00 committed by Arne
parent 79a105ca33
commit 8af639590c

View file

@ -117,7 +117,11 @@ public class FixedURLSpan extends URLSpan {
context.startActivity(intent);
widget.playSoundEffect(SoundEffectConstants.CLICK);
} catch (ActivityNotFoundException e) {
Toast.makeText(context, R.string.no_application_found_to_open_link, Toast.LENGTH_SHORT).show();
if ("bitcoin".equals(uri.getScheme()) || "bitcoincash".equals(uri.getScheme()) || "monero".equals(uri.getScheme())) {
Toast.makeText(context, "No compatible wallet app found", Toast.LENGTH_SHORT).show();
} else {
Toast.makeText(context, R.string.no_application_found_to_open_link, Toast.LENGTH_SHORT).show();
}
}
}
}