Browse Source

Made move action a main action

main
M66B 6 years ago
parent
commit
1be9d6a021
4 changed files with 14 additions and 14 deletions
  1. +7
    -7
      app/src/main/java/eu/faircode/email/FragmentMessage.java
  2. +6
    -0
      app/src/main/res/menu/action_view_bottom.xml
  3. +0
    -6
      app/src/main/res/menu/action_view_top.xml
  4. +1
    -1
      app/src/main/res/values/strings.xml

+ 7
- 7
app/src/main/java/eu/faircode/email/FragmentMessage.java View File

@ -157,9 +157,6 @@ public class FragmentMessage extends Fragment {
case R.id.action_thread:
onActionThread(id);
return true;
case R.id.action_move:
onActionMove(id);
return true;
case R.id.action_forward:
onActionForward(id);
return true;
@ -181,6 +178,9 @@ public class FragmentMessage extends Fragment {
case R.id.action_spam:
onActionSpam(id);
return true;
case R.id.action_move:
onActionMove(id);
return true;
case R.id.action_archive:
onActionArchive(id);
return true;
@ -324,10 +324,6 @@ public class FragmentMessage extends Fragment {
fragmentTransaction.commit();
}
private void onActionMove(final long id) {
Toast.makeText(getContext(), "Not implemented yet", Toast.LENGTH_LONG).show();
}
private void onActionForward(long id) {
startActivity(new Intent(getContext(), ActivityCompose.class)
.putExtra("id", id)
@ -415,6 +411,10 @@ public class FragmentMessage extends Fragment {
.setNegativeButton(android.R.string.cancel, null).show();
}
private void onActionMove(final long id) {
Toast.makeText(getContext(), "Not implemented yet", Toast.LENGTH_LONG).show();
}
private void onActionArchive(final long id) {
executor.submit(new Runnable() {
@Override


+ 6
- 0
app/src/main/res/menu/action_view_bottom.xml View File

@ -14,6 +14,12 @@
android:title="@string/title_spam"
app:showAsAction="ifRoom" />
<item
android:id="@+id/action_move"
android:icon="@drawable/baseline_folder_24"
android:title="@string/title_move"
app:showAsAction="ifRoom" />
<item
android:id="@+id/action_archive"
android:icon="@drawable/baseline_archive_24"


+ 0
- 6
app/src/main/res/menu/action_view_top.xml View File

@ -14,12 +14,6 @@
android:title="@string/title_seen"
app:showAsAction="ifRoom" />
<item
android:id="@+id/action_move"
android:icon="@drawable/baseline_folder_24"
android:title="@string/title_move"
app:showAsAction="ifRoom" />
<item
android:id="@+id/action_forward"
android:icon="@drawable/baseline_forward_24"


+ 1
- 1
app/src/main/res/values/strings.xml View File

@ -85,12 +85,12 @@
<string name="title_thread">Thread</string>
<string name="title_seen">Read</string>
<string name="title_unseen">Unread</string>
<string name="title_move">Move</string>
<string name="title_forward">Forward</string>
<string name="title_reply_all">Reply to all</string>
<string name="title_delete">Delete</string>
<string name="title_spam">Spam</string>
<string name="title_move">Move</string>
<string name="title_archive">Archive</string>
<string name="title_reply">Reply</string>


Loading…
Cancel
Save