diff --git a/app/src/main/java/fr/free/nrw/commons/AboutActivity.java b/app/src/main/java/fr/free/nrw/commons/AboutActivity.java index 6ed1bba1d..309dfba95 100644 --- a/app/src/main/java/fr/free/nrw/commons/AboutActivity.java +++ b/app/src/main/java/fr/free/nrw/commons/AboutActivity.java @@ -1,6 +1,9 @@ package fr.free.nrw.commons; +import android.content.Intent; +import android.net.Uri; import android.os.Bundle; +import android.view.View; import android.widget.TextView; import butterknife.BindView; @@ -33,4 +36,29 @@ public class AboutActivity extends NavigationBaseActivity { versionText.setText(BuildConfig.VERSION_NAME); initDrawer(); } + + public void getOpenFacebookIntent(View view) { + + Intent intent; + try { + intent = new Intent(Intent.ACTION_VIEW, Uri.parse("fb://page/" + "1921335171459985")); + intent.setPackage("com.facebook.katana"); + startActivity(intent); + } catch (Exception e) { + startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("https://www.facebook.com/" + "1921335171459985"))); + } + + } + + public void getOpenGithubIntent(View view) { + + Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("https://github.com/commons-app/apps-android-commons\\")); + startActivity(browserIntent); + } + + public void getOpenWebsiteIntent(View view) { + + Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("https://commons-app.github.io/\\")); + startActivity(browserIntent); + } } \ No newline at end of file