Show only the email clients in Feedback Feature (#1203)

Instead of showing only the email clients, The Feedback feature was showing multiple unsupported clients (WhatsApp, Bluetooth etc)

* Changes made to let the user choose from the available email related clients only.
This commit is contained in:
Ayushi 2018-02-26 04:17:19 +05:30
parent 215c97e132
commit 81064dee10

View file

@ -5,6 +5,7 @@ import android.accounts.AccountManager;
import android.content.ActivityNotFoundException;
import android.content.Context;
import android.content.Intent;
import android.net.Uri;
import android.support.annotation.NonNull;
import android.support.design.widget.NavigationView;
import android.support.v4.widget.DrawerLayout;
@ -119,8 +120,9 @@ public abstract class NavigationBaseActivity extends BaseActivity
return true;
case R.id.action_feedback:
drawerLayout.closeDrawer(navigationView);
Intent feedbackIntent = new Intent(Intent.ACTION_SEND);
Intent feedbackIntent = new Intent(Intent.ACTION_SENDTO);
feedbackIntent.setType("message/rfc822");
feedbackIntent.setData(Uri.parse("mailto:"));
feedbackIntent.putExtra(Intent.EXTRA_EMAIL,
new String[]{CommonsApplication.FEEDBACK_EMAIL});
feedbackIntent.putExtra(Intent.EXTRA_SUBJECT,