mirror of
https://github.com/oxen-io/session-android.git
synced 2024-11-27 12:05:22 +00:00
Switch to "home as up" button on new contact selection activity.
Fixes #3687 // FREEBIE
This commit is contained in:
parent
905b4f0a6b
commit
1daea51cfb
@ -17,7 +17,11 @@
|
||||
package org.thoughtcrime.securesms;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
import android.view.MenuItem;
|
||||
import android.view.View;
|
||||
|
||||
import org.thoughtcrime.securesms.crypto.MasterSecret;
|
||||
import org.thoughtcrime.securesms.database.DatabaseFactory;
|
||||
import org.thoughtcrime.securesms.database.ThreadDatabase;
|
||||
import org.thoughtcrime.securesms.recipients.RecipientFactory;
|
||||
@ -33,6 +37,14 @@ public class NewConversationActivity extends ContactSelectionActivity {
|
||||
|
||||
private static final String TAG = NewConversationActivity.class.getSimpleName();
|
||||
|
||||
@Override
|
||||
public void onCreate(Bundle bundle, MasterSecret masterSecret) {
|
||||
super.onCreate(bundle, masterSecret);
|
||||
|
||||
action.setVisibility(View.GONE);
|
||||
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onContactSelected(String number) {
|
||||
Recipients recipients = RecipientFactory.getRecipientsFromString(this, number, true);
|
||||
@ -54,4 +66,15 @@ public class NewConversationActivity extends ContactSelectionActivity {
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onOptionsItemSelected(MenuItem item) {
|
||||
super.onOptionsItemSelected(item);
|
||||
|
||||
switch (item.getItemId()) {
|
||||
case android.R.id.home: super.onBackPressed(); return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user