From bce0fe62217e1f174559354b1a0dc06fd9663385 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dominik=20Sch=C3=BCrmann?= Date: Tue, 10 Mar 2015 01:44:07 +0100 Subject: [PATCH] Add additional email addresses in create key --- Graphics/get-material-icons.sh | 1 + .../keychain/ui/CreateKeyEmailFragment.java | 180 ++++++++++++++- .../keychain/ui/CreateKeyFinalFragment.java | 33 ++- .../ui/CreateKeyPassphraseFragment.java | 10 +- .../keychain/ui/EditKeyFragment.java | 1 - .../ui/dialog/AddEmailDialogFragment.java | 215 ++++++++++++++++++ .../res/drawable-hdpi/ic_email_grey_24dp.png | Bin 0 -> 372 bytes .../res/drawable-mdpi/ic_email_grey_24dp.png | Bin 0 -> 307 bytes .../res/drawable-xhdpi/ic_email_grey_24dp.png | Bin 0 -> 439 bytes .../drawable-xxhdpi/ic_email_grey_24dp.png | Bin 0 -> 563 bytes .../drawable-xxxhdpi/ic_email_grey_24dp.png | Bin 0 -> 805 bytes .../src/main/res/layout/add_email_dialog.xml | 26 +++ .../res/layout/create_key_email_fragment.xml | 7 + .../layout/create_key_email_list_footer.xml | 23 ++ .../res/layout/create_key_email_list_item.xml | 28 +++ OpenKeychain/src/main/res/values/strings.xml | 5 +- 16 files changed, 522 insertions(+), 7 deletions(-) create mode 100644 OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/dialog/AddEmailDialogFragment.java create mode 100644 OpenKeychain/src/main/res/drawable-hdpi/ic_email_grey_24dp.png create mode 100644 OpenKeychain/src/main/res/drawable-mdpi/ic_email_grey_24dp.png create mode 100644 OpenKeychain/src/main/res/drawable-xhdpi/ic_email_grey_24dp.png create mode 100644 OpenKeychain/src/main/res/drawable-xxhdpi/ic_email_grey_24dp.png create mode 100644 OpenKeychain/src/main/res/drawable-xxxhdpi/ic_email_grey_24dp.png create mode 100644 OpenKeychain/src/main/res/layout/add_email_dialog.xml create mode 100644 OpenKeychain/src/main/res/layout/create_key_email_list_footer.xml create mode 100644 OpenKeychain/src/main/res/layout/create_key_email_list_item.xml diff --git a/Graphics/get-material-icons.sh b/Graphics/get-material-icons.sh index 248dcd532..299ae9713 100755 --- a/Graphics/get-material-icons.sh +++ b/Graphics/get-material-icons.sh @@ -40,6 +40,7 @@ python copy OpenKeychain communication grey vpn_key 24 python copy OpenKeychain navigation grey chevron_left 24 python copy OpenKeychain navigation grey chevron_right 24 python copy OpenKeychain social grey person 48 +python copy OpenKeychain communication grey email 24 # navigation drawer sections python copy OpenKeychain communication black vpn_key 24 diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/CreateKeyEmailFragment.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/CreateKeyEmailFragment.java index d9f391149..66424e012 100644 --- a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/CreateKeyEmailFragment.java +++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/CreateKeyEmailFragment.java @@ -20,17 +20,30 @@ package org.sufficientlysecure.keychain.ui; import android.app.Activity; import android.content.Context; import android.os.Bundle; +import android.os.Handler; +import android.os.Message; +import android.os.Messenger; import android.support.v4.app.Fragment; +import android.support.v7.widget.DefaultItemAnimator; +import android.support.v7.widget.LinearLayoutManager; +import android.support.v7.widget.RecyclerView; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; -import android.view.inputmethod.InputMethodManager; +import android.widget.Button; import android.widget.EditText; +import android.widget.ImageButton; +import android.widget.TextView; import org.sufficientlysecure.keychain.R; import org.sufficientlysecure.keychain.ui.CreateKeyActivity.FragAction; +import org.sufficientlysecure.keychain.ui.dialog.AddEmailDialogFragment; +import org.sufficientlysecure.keychain.ui.dialog.SetPassphraseDialogFragment; import org.sufficientlysecure.keychain.ui.widget.EmailEditText; +import java.util.ArrayList; +import java.util.List; + public class CreateKeyEmailFragment extends Fragment { public static final String ARG_NAME = "name"; @@ -38,10 +51,14 @@ public class CreateKeyEmailFragment extends Fragment { CreateKeyActivity mCreateKeyActivity; EmailEditText mEmailEdit; + RecyclerView mEmailsRecyclerView; View mBackButton; View mNextButton; String mName; + ArrayList mAdditionalEmailModels; + + EmailAdapter mEmailAdapter; /** * Creates new instance of this fragment @@ -86,6 +103,7 @@ public class CreateKeyEmailFragment extends Fragment { mEmailEdit = (EmailEditText) view.findViewById(R.id.create_key_email); mBackButton = view.findViewById(R.id.create_key_back_button); mNextButton = view.findViewById(R.id.create_key_next_button); + mEmailsRecyclerView = (RecyclerView) view.findViewById(R.id.create_key_emails); // initial values mName = getArguments().getString(ARG_NAME); @@ -108,10 +126,45 @@ public class CreateKeyEmailFragment extends Fragment { createKeyCheck(); } }); + mEmailsRecyclerView.setHasFixedSize(true); + mEmailsRecyclerView.setLayoutManager(new LinearLayoutManager(getActivity())); + mEmailsRecyclerView.setItemAnimator(new DefaultItemAnimator()); + + mAdditionalEmailModels = new ArrayList<>(); + mEmailAdapter = new EmailAdapter(mAdditionalEmailModels, new View.OnClickListener() { + @Override + public void onClick(View v) { + addEmail(); + } + }); + mEmailsRecyclerView.setAdapter(mEmailAdapter); return view; } + private void addEmail() { + Handler returnHandler = new Handler() { + @Override + public void handleMessage(Message message) { + if (message.what == SetPassphraseDialogFragment.MESSAGE_OKAY) { + Bundle data = message.getData(); + + // add new user id + mEmailAdapter.add( + data.getString(AddEmailDialogFragment.MESSAGE_DATA_EMAIL) + ); + } + } + }; + + // Create a new Messenger for the communication back + Messenger messenger = new Messenger(returnHandler); + + AddEmailDialogFragment addEmailDialog = AddEmailDialogFragment.newInstance(messenger); + + addEmailDialog.show(getActivity().getSupportFragmentManager(), "addEmailDialog"); + } + @Override public void onAttach(Activity activity) { super.onAttach(activity); @@ -121,14 +174,137 @@ public class CreateKeyEmailFragment extends Fragment { private void createKeyCheck() { if (isEditTextNotEmpty(getActivity(), mEmailEdit)) { + ArrayList emails = new ArrayList<>(); + for (EmailAdapter.ViewModel holder : mAdditionalEmailModels) { + emails.add(holder.toString()); + } + CreateKeyPassphraseFragment frag = CreateKeyPassphraseFragment.newInstance( mName, - mEmailEdit.getText().toString() + mEmailEdit.getText().toString(), + emails ); mCreateKeyActivity.loadFragment(null, frag, FragAction.TO_RIGHT); } } + public static class EmailAdapter extends RecyclerView.Adapter { + private List mDataset; + private View.OnClickListener mFooterOnClickListener; + private static final int TYPE_FOOTER = 0; + private static final int TYPE_ITEM = 1; + + public static class ViewModel { + String email; + + ViewModel(String email) { + this.email = email; + } + + @Override + public String toString() { + return email; + } + } + + // Provide a reference to the views for each data item + // Complex data items may need more than one view per item, and + // you provide access to all the views for a data item in a view holder + public static class ViewHolder extends RecyclerView.ViewHolder { + // each data item is just a string in this case + public TextView mTextView; + public ImageButton mDeleteButton; + + public ViewHolder(View itemView) { + super(itemView); + mTextView = (TextView) itemView.findViewById(R.id.create_key_email_item_email); + mDeleteButton = (ImageButton) itemView.findViewById(R.id.create_key_email_item_delete_button); + } + } + + class FooterHolder extends RecyclerView.ViewHolder { + public Button mAddButton; + + public FooterHolder(View itemView) { + super(itemView); + mAddButton = (Button) itemView.findViewById(R.id.create_key_add_email); + } + } + + // Provide a suitable constructor (depends on the kind of dataset) + public EmailAdapter(List myDataset, View.OnClickListener onFooterClickListener) { + mDataset = myDataset; + mFooterOnClickListener = onFooterClickListener; + } + + // Create new views (invoked by the layout manager) + @Override + public RecyclerView.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) { + if (viewType == TYPE_FOOTER) { + View v = LayoutInflater.from(parent.getContext()) + .inflate(R.layout.create_key_email_list_footer, parent, false); + return new FooterHolder(v); + } else { + //inflate your layout and pass it to view holder + View v = LayoutInflater.from(parent.getContext()) + .inflate(R.layout.create_key_email_list_item, parent, false); + return new ViewHolder(v); + } + } + + // Replace the contents of a view (invoked by the layout manager) + @Override + public void onBindViewHolder(RecyclerView.ViewHolder holder, final int position) { + if (holder instanceof ViewHolder) { + ViewHolder thisHolder = (ViewHolder) holder; + // - get element from your dataset at this position + // - replace the contents of the view with that element + final ViewModel model = mDataset.get(position); + + thisHolder.mTextView.setText(model.email); + thisHolder.mDeleteButton.setOnClickListener(new View.OnClickListener() { + @Override + public void onClick(View v) { + remove(model); + } + }); + } else if (holder instanceof FooterHolder) { + FooterHolder thisHolder = (FooterHolder) holder; + thisHolder.mAddButton.setOnClickListener(mFooterOnClickListener); + } + } + + // Return the size of your dataset (invoked by the layout manager) + @Override + public int getItemCount() { + return mDataset.size() + 1; + } + + @Override + public int getItemViewType(int position) { + if (isPositionFooter(position)) { + return TYPE_FOOTER; + } else { + return TYPE_ITEM; + } + } + + private boolean isPositionFooter(int position) { + return position == mDataset.size(); + } + + public void add(String email) { + mDataset.add(new ViewModel(email)); + notifyItemInserted(mDataset.size() - 1); + } + + public void remove(ViewModel model) { + int position = mDataset.indexOf(model); + mDataset.remove(position); + notifyItemRemoved(position); + } + } + } diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/CreateKeyFinalFragment.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/CreateKeyFinalFragment.java index dc9f3d4ad..4853c61c5 100644 --- a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/CreateKeyFinalFragment.java +++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/CreateKeyFinalFragment.java @@ -47,6 +47,9 @@ import org.sufficientlysecure.keychain.ui.CreateKeyActivity.FragAction; import org.sufficientlysecure.keychain.util.Log; import org.sufficientlysecure.keychain.util.Preferences; +import java.util.ArrayList; +import java.util.Iterator; + public class CreateKeyFinalFragment extends Fragment { public static final int REQUEST_EDIT_KEY = 0x00008007; @@ -63,10 +66,12 @@ public class CreateKeyFinalFragment extends Fragment { public static final String ARG_NAME = "name"; public static final String ARG_EMAIL = "email"; + public static final String ARG_ADDITIONAL_EMAILS = "emails"; public static final String ARG_PASSPHRASE = "passphrase"; String mName; String mEmail; + ArrayList mAdditionalEmails; String mPassphrase; SaveKeyringParcel mSaveKeyringParcel; @@ -74,12 +79,15 @@ public class CreateKeyFinalFragment extends Fragment { /** * Creates new instance of this fragment */ - public static CreateKeyFinalFragment newInstance(String name, String email, String passphrase) { + public static CreateKeyFinalFragment newInstance(String name, String email, + ArrayList additionalEmails, + String passphrase) { CreateKeyFinalFragment frag = new CreateKeyFinalFragment(); Bundle args = new Bundle(); args.putString(ARG_NAME, name); args.putString(ARG_EMAIL, email); + args.putStringArrayList(ARG_ADDITIONAL_EMAILS, additionalEmails); args.putString(ARG_PASSPHRASE, passphrase); frag.setArguments(args); @@ -102,11 +110,25 @@ public class CreateKeyFinalFragment extends Fragment { // get args mName = getArguments().getString(ARG_NAME); mEmail = getArguments().getString(ARG_EMAIL); + mAdditionalEmails = getArguments().getStringArrayList(ARG_ADDITIONAL_EMAILS); mPassphrase = getArguments().getString(ARG_PASSPHRASE); // set values mNameEdit.setText(mName); - mEmailEdit.setText(mEmail); + if (mAdditionalEmails != null && mAdditionalEmails.size() > 0) { + String emailText = mEmail + ", "; + Iterator it = mAdditionalEmails.iterator(); + while (it.hasNext()) { + Object next = it.next(); + emailText += next; + if (it.hasNext()) { + emailText += ", "; + } + } + mEmailEdit.setText(emailText); + } else { + mEmailEdit.setText(mEmail); + } mCreateButton.setOnClickListener(new View.OnClickListener() { @Override @@ -167,12 +189,19 @@ public class CreateKeyFinalFragment extends Fragment { String userId = KeyRing.createUserId(mName, mEmail, null); mSaveKeyringParcel.mAddUserIds.add(userId); mSaveKeyringParcel.mChangePrimaryUserId = userId; + if (mAdditionalEmails != null && mAdditionalEmails.size() > 0) { + for (String email : mAdditionalEmails) { + String thisUserId = KeyRing.createUserId(mName, email, null); + mSaveKeyringParcel.mAddUserIds.add(thisUserId); + } + } mSaveKeyringParcel.mNewUnlock = mPassphrase != null ? new ChangeUnlockParcel(mPassphrase, null) : null; } } + private void createKey() { Intent intent = new Intent(getActivity(), KeychainIntentService.class); intent.setAction(KeychainIntentService.ACTION_EDIT_KEYRING); diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/CreateKeyPassphraseFragment.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/CreateKeyPassphraseFragment.java index 00ac00ff4..055ea608b 100644 --- a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/CreateKeyPassphraseFragment.java +++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/CreateKeyPassphraseFragment.java @@ -35,14 +35,18 @@ import org.sufficientlysecure.keychain.R; import org.sufficientlysecure.keychain.ui.CreateKeyActivity.FragAction; import org.sufficientlysecure.keychain.ui.widget.PassphraseEditText; +import java.util.ArrayList; + public class CreateKeyPassphraseFragment extends Fragment { public static final String ARG_NAME = "name"; public static final String ARG_EMAIL = "email"; + public static final String ARG_ADDITIONAL_EMAILS = "emails"; // model String mName; String mEmail; + ArrayList mAdditionalEmails; // view CreateKeyActivity mCreateKeyActivity; @@ -55,12 +59,14 @@ public class CreateKeyPassphraseFragment extends Fragment { /** * Creates new instance of this fragment */ - public static CreateKeyPassphraseFragment newInstance(String name, String email) { + public static CreateKeyPassphraseFragment newInstance(String name, String email, + ArrayList additionalEmails) { CreateKeyPassphraseFragment frag = new CreateKeyPassphraseFragment(); Bundle args = new Bundle(); args.putString(ARG_NAME, name); args.putString(ARG_EMAIL, email); + args.putStringArrayList(ARG_ADDITIONAL_EMAILS, additionalEmails); frag.setArguments(args); @@ -114,6 +120,7 @@ public class CreateKeyPassphraseFragment extends Fragment { // initial values mName = getArguments().getString(ARG_NAME); mEmail = getArguments().getString(ARG_EMAIL); + mAdditionalEmails = getArguments().getStringArrayList(ARG_ADDITIONAL_EMAILS); mPassphraseEdit.requestFocus(); mBackButton.setOnClickListener(new View.OnClickListener() { @Override @@ -163,6 +170,7 @@ public class CreateKeyPassphraseFragment extends Fragment { CreateKeyFinalFragment.newInstance( mName, mEmail, + mAdditionalEmails, mPassphraseEdit.getText().toString() ); diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EditKeyFragment.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EditKeyFragment.java index 25ca6e8fd..1e9a90fc8 100644 --- a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EditKeyFragment.java +++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EditKeyFragment.java @@ -528,7 +528,6 @@ public class EditKeyFragment extends LoaderFragment implements } private void addUserId() { - // Message is received after passphrase is cached Handler returnHandler = new Handler() { @Override public void handleMessage(Message message) { diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/dialog/AddEmailDialogFragment.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/dialog/AddEmailDialogFragment.java new file mode 100644 index 000000000..5d5ca533e --- /dev/null +++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/dialog/AddEmailDialogFragment.java @@ -0,0 +1,215 @@ +/* + * Copyright (C) 2015 Dominik Schürmann + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +package org.sufficientlysecure.keychain.ui.dialog; + +import android.app.Activity; +import android.app.AlertDialog; +import android.app.Dialog; +import android.content.Context; +import android.content.DialogInterface; +import android.content.DialogInterface.OnClickListener; +import android.os.Bundle; +import android.os.Message; +import android.os.Messenger; +import android.os.RemoteException; +import android.support.v4.app.DialogFragment; +import android.view.KeyEvent; +import android.view.LayoutInflater; +import android.view.View; +import android.view.inputmethod.EditorInfo; +import android.view.inputmethod.InputMethodManager; +import android.widget.Button; +import android.widget.TextView; +import android.widget.TextView.OnEditorActionListener; + +import org.sufficientlysecure.keychain.Constants; +import org.sufficientlysecure.keychain.R; +import org.sufficientlysecure.keychain.ui.widget.EmailEditText; +import org.sufficientlysecure.keychain.util.Log; + +public class AddEmailDialogFragment extends DialogFragment implements OnEditorActionListener { + private static final String ARG_MESSENGER = "messenger"; + + public static final int MESSAGE_OKAY = 1; + public static final int MESSAGE_CANCEL = 2; + + public static final String MESSAGE_DATA_EMAIL = "email"; + + private Messenger mMessenger; + private EmailEditText mEmail; + + public static AddEmailDialogFragment newInstance(Messenger messenger) { + + AddEmailDialogFragment frag = new AddEmailDialogFragment(); + Bundle args = new Bundle(); + args.putParcelable(ARG_MESSENGER, messenger); + frag.setArguments(args); + + return frag; + } + + /** + * Creates dialog + */ + @Override + public Dialog onCreateDialog(Bundle savedInstanceState) { + final Activity activity = getActivity(); + mMessenger = getArguments().getParcelable(ARG_MESSENGER); + + CustomAlertDialogBuilder alert = new CustomAlertDialogBuilder(activity); + + alert.setTitle(R.string.create_key_add_email); + + LayoutInflater inflater = activity.getLayoutInflater(); + View view = inflater.inflate(R.layout.add_email_dialog, null); + alert.setView(view); + + mEmail = (EmailEditText) view.findViewById(R.id.add_email_address); + + alert.setPositiveButton(android.R.string.ok, new OnClickListener() { + @Override + public void onClick(DialogInterface dialog, int id) { + dismiss(); + + // return new user id back to activity + Bundle data = new Bundle(); + String email = mEmail.getText().toString(); + data.putString(MESSAGE_DATA_EMAIL, email); + sendMessageToHandler(MESSAGE_OKAY, data); + } + }); + + alert.setNegativeButton(android.R.string.cancel, new OnClickListener() { + @Override + public void onClick(DialogInterface dialog, int id) { + dialog.cancel(); + } + }); + + // Hack to open keyboard. + // This is the only method that I found to work across all Android versions + // http://turbomanage.wordpress.com/2012/05/02/show-soft-keyboard-automatically-when-edittext-receives-focus/ + // Notes: * onCreateView can't be used because we want to add buttons to the dialog + // * opening in onActivityCreated does not work on Android 4.4 + mEmail.setOnFocusChangeListener(new View.OnFocusChangeListener() { + @Override + public void onFocusChange(View v, boolean hasFocus) { + mEmail.post(new Runnable() { + @Override + public void run() { + InputMethodManager imm = (InputMethodManager) getActivity() + .getSystemService(Context.INPUT_METHOD_SERVICE); + imm.showSoftInput(mEmail, InputMethodManager.SHOW_IMPLICIT); + } + }); + } + }); + mEmail.requestFocus(); + + mEmail.setImeActionLabel(getString(android.R.string.ok), EditorInfo.IME_ACTION_DONE); + mEmail.setOnEditorActionListener(this); + + return alert.show(); + } + + @Override + public void onCancel(DialogInterface dialog) { + super.onCancel(dialog); + + dismiss(); + sendMessageToHandler(MESSAGE_CANCEL); + } + + @Override + public void onDismiss(DialogInterface dialog) { + super.onDismiss(dialog); + + // hide keyboard on dismiss + hideKeyboard(); + } + + private void hideKeyboard() { + if (getActivity() == null) { + return; + } + InputMethodManager inputManager = (InputMethodManager) getActivity() + .getSystemService(Context.INPUT_METHOD_SERVICE); + + // check if no view has focus: + View v = getActivity().getCurrentFocus(); + if (v == null) + return; + + inputManager.hideSoftInputFromWindow(v.getWindowToken(), 0); + } + + /** + * Associate the "done" button on the soft keyboard with the okay button in the view + */ + @Override + public boolean onEditorAction(TextView v, int actionId, KeyEvent event) { + if (EditorInfo.IME_ACTION_DONE == actionId) { + AlertDialog dialog = ((AlertDialog) getDialog()); + Button bt = dialog.getButton(AlertDialog.BUTTON_POSITIVE); + + bt.performClick(); + return true; + } + return false; + } + + /** + * Send message back to handler which is initialized in a activity + * + * @param what Message integer you want to send + */ + private void sendMessageToHandler(Integer what) { + Message msg = Message.obtain(); + msg.what = what; + + try { + mMessenger.send(msg); + } catch (RemoteException e) { + Log.w(Constants.TAG, "Exception sending message, Is handler present?", e); + } catch (NullPointerException e) { + Log.w(Constants.TAG, "Messenger is null!", e); + } + } + + /** + * Send message back to handler which is initialized in a activity + * + * @param what Message integer you want to send + */ + private void sendMessageToHandler(Integer what, Bundle data) { + Message msg = Message.obtain(); + msg.what = what; + if (data != null) { + msg.setData(data); + } + + try { + mMessenger.send(msg); + } catch (RemoteException e) { + Log.w(Constants.TAG, "Exception sending message, Is handler present?", e); + } catch (NullPointerException e) { + Log.w(Constants.TAG, "Messenger is null!", e); + } + } + +} diff --git a/OpenKeychain/src/main/res/drawable-hdpi/ic_email_grey_24dp.png b/OpenKeychain/src/main/res/drawable-hdpi/ic_email_grey_24dp.png new file mode 100644 index 0000000000000000000000000000000000000000..56c0a8c94fbcc59c37f5a4006395da46aca9fbe5 GIT binary patch literal 372 zcmeAS@N?(olHy`uVBq!ia0vp^Dj>|k0wldT1B8K;Lb6AYF9SoB8UsT^3j@P1pisjL z28L1t28LG&3=CE?7#PG0=Ijcz0ZK3>dAqwX{BQ3+vmeOgEbxddW?<8!WdExI{O;`;XFSW$CYwHBg?Kfn|G|^1F+_?7e#Q^IX;~4f8 zeD`^-b7~!y|F_=Fd45)#8vot;(kr{<|4rol>32QQ?Mt2P+4BEW7O2aO=~G=WkLc z+SA1`#Nzbb%Nu!{93+l@)ZZy)en2&akJ(R2?7!s^&lG`JC#eNfrag(waCyRUN$~S3 z?|bj{zCS&;p>pHWCRx#09=>-PU+xkJWpDA&a9eGj)bi^9$B7K~r_+=V?*7bJcxKU=TKE-@7NQP9iGz xR`xb+{3E)ee${l@j{1uAs<&P1FG^N2oYYmiw&!!)C7`nzJYD@<);T3K0RV~0aD@N> literal 0 HcmV?d00001 diff --git a/OpenKeychain/src/main/res/drawable-xhdpi/ic_email_grey_24dp.png b/OpenKeychain/src/main/res/drawable-xhdpi/ic_email_grey_24dp.png new file mode 100644 index 0000000000000000000000000000000000000000..6d7dd4fc9faf3f6429ff85b8b53e1a4ae4c96da1 GIT binary patch literal 439 zcmeAS@N?(olHy`uVBq!ia0vp^1|ZDA0wn)(8}a}tg=CK)Uj~LMH3o);76yi2K%s^g z3=E|}g|8AA7_4S6Fo+k-*%fF5lweBoc6VX;-`;;_Kaj^+;1OBOz`!jG!i)^F=14Fw zFzS1{IEF+VemmWlugO59W%iD%(l5dyPdk25dzEx<;l0BwUu3E{@2(D<{%>nw^a5R* z1;=KXY-YT5jy+$a(qO~;uF3}XKjI78CDd)QUNwm_2`}h&&i&lq$F-1wJN=uJx9o;; zE{oRn_dslNt;Q1!f0*%l>j-yOW`f?bx14BA>&~BH4HeACI;~G}$F{7RS23yTk<5YB%NEKQw*TY2I&CJ~ zj%>EgGR&e{&fLX^c}197%Jw)^y?7artE$52v+%alTAmYadE8ss6r`CO6}Z?`^@(?&65>T5Bl~` f{1mf|!wXIyi*6ZZnHMs^@MQ3G^>bP0l+XkKx~HOC literal 0 HcmV?d00001 diff --git a/OpenKeychain/src/main/res/drawable-xxhdpi/ic_email_grey_24dp.png b/OpenKeychain/src/main/res/drawable-xxhdpi/ic_email_grey_24dp.png new file mode 100644 index 0000000000000000000000000000000000000000..c50ea840ac65cd6c340e271c785faab6a2b2609d GIT binary patch literal 563 zcmV-30?hr1P)004R> z004l5008;`004mK004C`008P>0026e000+ooVrmw00002VoOIv0RM-N%)bBt010qN zS#tmY3ljhU3ljkVnw%H_00FB>L_t(&-tE~>YQjJi$MFHdZ0rTpUZNgE?@>b1#qS)o zC(%nAD2ADB`mHwLx_vSBcmP zNG)=;h%JGtB3F;tB8ZN>PQ+G0ROBXac4JU+$0N-fdMuR zbNW@sQyu~=acm&v1^n#Y;S)s$F^EA7V$fdzeE~ftIQMN^H`f3F002ovPDHLkV1j5M BI(3)EF2VS{N990fib~ zFff!FFfhDIU|_JC!N4G1FlSew4N!t9$=lt9;eUJonf*W>XMsm#F#`j)FbFd;%$g$s zR591n#WAGf*4tawdBTn|4Ij_9w09riY;uuOaX4Ya$Kb^(`jGDg+fivnMXNgwd<-`v zPA~UZb%Eg#1EV9?0!NRNtOA;k8Vp%mQsnP_+*79h$bPPLb=~Wq$KtBBzFXc{ti-^` z;lRKo(7?c=0AwDpeZa)~%;M<9N$EQdhsRxfyq9mmso=ao&KFMoFN&wXJ;@Lnwo~ds zR^{QXCW_n_p874|-Zy<-q*OuQ*9Bt!HHxu5+a|EtBpN>OU4FWW>qFybMrON0H`X7= zIvW_7S7{wEJD${^e<^L*l9zb`8|SPEW0g>`+ok2R*=6#|CUyHIzTLWR-xwNBf7u!G z;LG(DpTE67_n3tt*u^GkSHsEr<*w}y_piMy$dJ&+XKv$PKeOZPjeG9}7!2MUzT#C1 z3zCoPW31?^GLOn(w3Z2EsBzgVzP9)P*V!Ahj#OUxnDM=T@|NJUnal~@VsFog7YLRb z-P+5&<;3A0?i7X}pT*20PS0uZy%KqG)wC6g3~eP969i{wUU|Hz^|8)IgKs~37#U_u z-uFGTNKSt3E7?${x&n*uOW!WO)_u+LfLYev3|odXi_JQ(2|L(lUC!9c_+^n<|26G| zO)K6my2|$F%Ds!97t2MuMKdVaXUWt{eqlM$eM|4wA%>rUyLT&o;sWwaZXIHLyvVFK zOxobdgvr)xDz3bH_kfG(O+QfGC5GLBkAH;sI5FC_F*LFN;rhm}28y=->Ug z*5LS3-SzV^7WR2|#a0Oi+|R9IIKNZYV1e@zrYjZVA2yzrdacFqC4+^l!p-<<$+L@( z#bY=Ney!hmE + + + + + + + diff --git a/OpenKeychain/src/main/res/layout/create_key_email_fragment.xml b/OpenKeychain/src/main/res/layout/create_key_email_fragment.xml index a24d1a2ee..17cfe54ac 100644 --- a/OpenKeychain/src/main/res/layout/create_key_email_fragment.xml +++ b/OpenKeychain/src/main/res/layout/create_key_email_fragment.xml @@ -4,6 +4,7 @@ android:layout_height="match_parent"> + + diff --git a/OpenKeychain/src/main/res/layout/create_key_email_list_footer.xml b/OpenKeychain/src/main/res/layout/create_key_email_list_footer.xml new file mode 100644 index 000000000..3e58d40e5 --- /dev/null +++ b/OpenKeychain/src/main/res/layout/create_key_email_list_footer.xml @@ -0,0 +1,23 @@ + + + +