am 23a27697: Merge branch \'readonly-p4-donut\' into donut

Merge commit '23a27697963642d6450b70dd83709492c1bdde72'

* commit '23a27697963642d6450b70dd83709492c1bdde72':
  AI 149607: Add relevant title to attachment file chooser.
This commit is contained in:
Mihai Preda 2009-06-05 11:41:33 -07:00 committed by The Android Open Source Project
commit da93b380d1
2 changed files with 9 additions and 4 deletions

View File

@ -80,6 +80,8 @@
<string name="add_attachment_action">Add attachment</string>
<!-- Menu item (debug screen) -->
<string name="dump_settings_action">Dump settings</string>
<!-- Appears in choose attachment dialog title -->
<string name="choose_attachment_dialog_title">Choose attachment</string>
<!-- Title of account context menu -->
<string name="accounts_context_menu_title">Account options</string>
<!-- Appears in message list view while messages are being loaded -->

View File

@ -723,11 +723,12 @@ public class MessageCompose extends Activity implements OnClickListener, OnFocus
else {
/*
* Send the message
* TODO Is it possible for us to be editing a draft with a null source message? Don't
* think so. Could probably remove below check.
* If the source message is in other folder than draft, it should not be deleted while
* sending message.
*/
if (ACTION_EDIT_DRAFT.equals(getIntent().getAction())
&& mSourceMessageUid != null) {
&& mSourceMessageUid != null
&& mFolder.equals(mAccount.getDraftsFolderName())) {
/*
* We're sending a previously saved draft, so delete the old draft first.
*/
@ -795,7 +796,9 @@ public class MessageCompose extends Activity implements OnClickListener, OnFocus
Intent i = new Intent(Intent.ACTION_GET_CONTENT);
i.addCategory(Intent.CATEGORY_OPENABLE);
i.setType(Email.ACCEPTABLE_ATTACHMENT_SEND_TYPES[0]);
startActivityForResult(Intent.createChooser(i, null), ACTIVITY_REQUEST_PICK_ATTACHMENT);
startActivityForResult(
Intent.createChooser(i, getString(R.string.choose_attachment_dialog_title)),
ACTIVITY_REQUEST_PICK_ATTACHMENT);
}
private void addAttachment(Uri uri) {