Merge "Always show from field in compose"

This commit is contained in:
Ben Komalo 2011-07-22 16:10:24 -07:00 committed by Android (Google) Code Review
commit 30183e536e
2 changed files with 14 additions and 6 deletions

View File

@ -35,6 +35,18 @@
android:visibility="gone"
/>
<!-- Not actually editable -->
<TextView
android:id="@+id/from"
style="?android:attr/editTextStyle"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="6dip"
android:layout_marginRight="6dip"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="?android:attr/textColorSecondary"
/>
<include android:id="@+id/to"
layout="@layout/address_text_view"
android:layout_width="match_parent"

View File

@ -345,6 +345,7 @@ public class MessageCompose extends Activity implements OnClickListener, OnFocus
throw new IllegalArgumentException();
}
mAccount = account;
mFromView.setText(account.mEmailAddress);
mAddressAdapterTo
.setAccount(new android.accounts.Account(account.mEmailAddress, "unknown"));
mAddressAdapterCc
@ -352,11 +353,6 @@ public class MessageCompose extends Activity implements OnClickListener, OnFocus
mAddressAdapterBcc
.setAccount(new android.accounts.Account(account.mEmailAddress, "unknown"));
if (mFromView != null) {
// Some configurations don't show the from field.
mFromView.setText(account.mEmailAddress);
}
new QuickResponseChecker(mTaskTracker).executeParallel((Void) null);
}
@ -676,6 +672,7 @@ public class MessageCompose extends Activity implements OnClickListener, OnFocus
mBccView.setHint(R.string.message_compose_bcc_hint);
}
mFromView = UiUtilities.getView(this, R.id.from);
mCcBccContainer = UiUtilities.getView(this, R.id.cc_bcc_container);
mSubjectView = UiUtilities.getView(this, R.id.subject);
mMessageContentView = UiUtilities.getView(this, R.id.message_content);
@ -733,7 +730,6 @@ public class MessageCompose extends Activity implements OnClickListener, OnFocus
mMessageContentView.setOnFocusChangeListener(this);
mFromView = UiUtilities.getViewOrNull(this, R.id.from);
mActionSpinner = UiUtilities.getViewOrNull(this, R.id.action_spinner);
updateAttachmentContainer();