ActivityNotFoundException fix
This commit is contained in:
@ -8,6 +8,7 @@
|
||||
* configuring addressbook subscriptions
|
||||
* using a configuration wizard
|
||||
* saving tunnel settings
|
||||
* installing a browser without a market app
|
||||
* Update Firefox browser config instructions for Firefox Quantum
|
||||
* Translation updates
|
||||
|
||||
|
@ -1,5 +1,6 @@
|
||||
package net.i2p.android.help;
|
||||
|
||||
import android.content.ActivityNotFoundException;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.graphics.ColorMatrix;
|
||||
@ -11,6 +12,7 @@ import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.TextView;
|
||||
import android.widget.Toast;
|
||||
|
||||
import net.i2p.android.router.R;
|
||||
|
||||
@ -84,7 +86,11 @@ public class BrowserAdapter extends RecyclerView.Adapter<BrowserAdapter.ViewHold
|
||||
String uriMarket = "market://search?q=pname:" + browser.packageName;
|
||||
Uri uri = Uri.parse(uriMarket);
|
||||
Intent intent = new Intent(Intent.ACTION_VIEW, uri);
|
||||
mCtx.startActivity(intent);
|
||||
try {
|
||||
mCtx.startActivity(intent);
|
||||
} catch (ActivityNotFoundException e) {
|
||||
Toast.makeText(mCtx, R.string.no_market_app, Toast.LENGTH_LONG).show();
|
||||
}
|
||||
}
|
||||
});
|
||||
holder.mStatus.setVisibility(View.VISIBLE);
|
||||
|
@ -410,6 +410,7 @@
|
||||
<string name="logs_copied_to_clipboard">Logs copied to clipboard</string>
|
||||
|
||||
<string name="label_browser_configuration">Browser configuration</string>
|
||||
<string name="no_market_app">No market app found, please install manually</string>
|
||||
|
||||
<string name="unset">Unset</string>
|
||||
</resources>
|
||||
|
Reference in New Issue
Block a user