mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-28 21:33:53 +01:00
Moved handleWebUrl to its own utility class
This commit is contained in:
parent
181bd3dfa4
commit
b37948ec39
18 changed files with 82 additions and 72 deletions
|
|
@ -7,6 +7,7 @@ import android.view.ViewGroup;
|
|||
import android.widget.TextView;
|
||||
|
||||
import androidx.viewpager.widget.PagerAdapter;
|
||||
import fr.free.nrw.commons.utils.UrlUtils;
|
||||
import fr.free.nrw.commons.utils.Utils;
|
||||
|
||||
public class WelcomePagerAdapter extends PagerAdapter {
|
||||
|
|
@ -48,7 +49,7 @@ public class WelcomePagerAdapter extends PagerAdapter {
|
|||
// Add link to more information
|
||||
TextView moreInfo = layout.findViewById(R.id.welcomeInfo);
|
||||
Utils.setUnderlinedText(moreInfo, R.string.welcome_help_button_text, container.getContext());
|
||||
moreInfo.setOnClickListener(view -> Utils.handleWebUrl(
|
||||
moreInfo.setOnClickListener(view -> UrlUtils.handleWebUrl(
|
||||
container.getContext(),
|
||||
Uri.parse("https://commons.wikimedia.org/wiki/Help:Contents")
|
||||
));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue