Rename "other" to "sms"

// FREEBIE
This commit is contained in:
Moxie Marlinspike 2017-05-07 18:59:18 -07:00
parent 1b75d00de5
commit b0b08a37db
3 changed files with 9 additions and 9 deletions

View File

@ -59,9 +59,9 @@ public class ContactSelectionListFragment extends Fragment
public final static String MULTI_SELECT = "multi_select";
public final static String REFRESHABLE = "refreshable";
public final static int DISPLAY_MODE_ALL = ContactsCursorLoader.MODE_ALL;
public final static int DISPLAY_MODE_PUSH_ONLY = ContactsCursorLoader.MODE_PUSH_ONLY;
public final static int DISPLAY_MODE_OTHER_ONLY = ContactsCursorLoader.MODE_OTHER_ONLY;
public final static int DISPLAY_MODE_ALL = ContactsCursorLoader.MODE_ALL;
public final static int DISPLAY_MODE_PUSH_ONLY = ContactsCursorLoader.MODE_PUSH_ONLY;
public final static int DISPLAY_MODE_SMS_ONLY = ContactsCursorLoader.MODE_SMS_ONLY;
private TextView emptyText;

View File

@ -59,7 +59,7 @@ public class InviteActivity extends PassphraseRequiredActionBarActivity implemen
protected void onCreate(Bundle savedInstanceState, @NonNull MasterSecret masterSecret) {
this.masterSecret = masterSecret;
getIntent().putExtra(ContactSelectionListFragment.DISPLAY_MODE, ContactSelectionListFragment.DISPLAY_MODE_OTHER_ONLY);
getIntent().putExtra(ContactSelectionListFragment.DISPLAY_MODE, ContactSelectionListFragment.DISPLAY_MODE_SMS_ONLY);
getIntent().putExtra(ContactSelectionListFragment.MULTI_SELECT, true);
getIntent().putExtra(ContactSelectionListFragment.REFRESHABLE, false);

View File

@ -45,9 +45,9 @@ public class ContactsCursorLoader extends CursorLoader {
private static final String TAG = ContactsCursorLoader.class.getSimpleName();
public final static int MODE_ALL = 0;
public final static int MODE_PUSH_ONLY = 1;
public final static int MODE_OTHER_ONLY = 2;
public final static int MODE_ALL = 0;
public final static int MODE_PUSH_ONLY = 1;
public final static int MODE_SMS_ONLY = 2;
private final String filter;
private final int mode;
@ -64,13 +64,13 @@ public class ContactsCursorLoader extends CursorLoader {
ContactsDatabase contactsDatabase = DatabaseFactory.getContactsDatabase(getContext());
ArrayList<Cursor> cursorList = new ArrayList<>(3);
if (mode != MODE_OTHER_ONLY) {
if (mode != MODE_SMS_ONLY) {
cursorList.add(contactsDatabase.queryTextSecureContacts(filter));
}
if (mode == MODE_ALL) {
cursorList.add(contactsDatabase.querySystemContacts(filter));
} else if (mode == MODE_OTHER_ONLY) {
} else if (mode == MODE_SMS_ONLY) {
cursorList.add(filterNonPushContacts(contactsDatabase.querySystemContacts(filter)));
}