Fix l10n when searching for "Note to Self".

This commit is contained in:
Rashad Sookram
2022-01-26 16:23:12 -05:00
committed by Cody Henthorne
parent 33f4bb0000
commit 125ff83bac
8 changed files with 43 additions and 22 deletions

View File

@@ -10,7 +10,6 @@ import android.text.TextUtils;
import androidx.annotation.NonNull;
import androidx.annotation.WorkerThread;
import org.thoughtcrime.securesms.R;
import org.thoughtcrime.securesms.database.RecipientDatabase;
import org.thoughtcrime.securesms.database.SignalDatabase;
import org.thoughtcrime.securesms.phonenumbers.PhoneNumberFormatter;
@@ -101,9 +100,9 @@ public class ContactRepository {
}));
}};
public ContactRepository(@NonNull Context context) {
public ContactRepository(@NonNull Context context, @NonNull String noteToSelfTitle) {
this.recipientDatabase = SignalDatabase.recipients();
this.noteToSelfTitle = context.getString(R.string.note_to_self);
this.noteToSelfTitle = noteToSelfTitle;
this.context = context.getApplicationContext();
}

View File

@@ -75,7 +75,7 @@ public class ContactsCursorLoader extends AbstractContactsCursorLoader {
this.mode = mode;
this.recents = recents;
this.contactRepository = new ContactRepository(context);
this.contactRepository = new ContactRepository(context, context.getString(R.string.note_to_self));
}
protected final List<Cursor> getUnfilteredResults() {