mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-26 20:33:53 +01:00
Use custom tabs for nearby web views (#1347)
This commit is contained in:
parent
120130bfc7
commit
e122bf3a54
2 changed files with 4 additions and 4 deletions
|
|
@ -53,6 +53,7 @@ import javax.inject.Named;
|
|||
|
||||
import dagger.android.support.DaggerFragment;
|
||||
import fr.free.nrw.commons.R;
|
||||
import fr.free.nrw.commons.Utils;
|
||||
import fr.free.nrw.commons.contributions.ContributionController;
|
||||
import fr.free.nrw.commons.utils.UriDeserializer;
|
||||
import timber.log.Timber;
|
||||
|
|
@ -700,8 +701,7 @@ public class NearbyMapFragment extends DaggerFragment {
|
|||
}
|
||||
|
||||
private void openWebView(Uri link) {
|
||||
Intent browserIntent = new Intent(Intent.ACTION_VIEW, link);
|
||||
startActivity(browserIntent);
|
||||
Utils.handleWebUrl(getContext(), link);
|
||||
}
|
||||
|
||||
private void animateFAB(boolean isFabOpen) {
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@ import butterknife.BindView;
|
|||
import butterknife.ButterKnife;
|
||||
import fr.free.nrw.commons.CommonsApplication;
|
||||
import fr.free.nrw.commons.R;
|
||||
import fr.free.nrw.commons.Utils;
|
||||
import fr.free.nrw.commons.contributions.ContributionController;
|
||||
import fr.free.nrw.commons.di.ApplicationlessInjection;
|
||||
import timber.log.Timber;
|
||||
|
|
@ -200,8 +201,7 @@ public class PlaceRenderer extends Renderer<Place> {
|
|||
}
|
||||
|
||||
private void openWebView(Uri link) {
|
||||
Intent browserIntent = new Intent(Intent.ACTION_VIEW, link);
|
||||
view.getContext().startActivity(browserIntent);
|
||||
Utils.handleWebUrl(getContext(), link);
|
||||
}
|
||||
|
||||
private boolean showMenu() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue