mirror of
https://github.com/moparisthebest/k-9
synced 2024-11-11 20:15:03 -05:00
Remove test data and check for duplicate accounts on the device.
This commit is contained in:
parent
5aa0dce062
commit
8e9da5cf5b
@ -353,7 +353,7 @@ http://k9mail.googlecode.com/
|
||||
<string name="accounts_setup_help">
|
||||
Select an account here to setup, press menu to load more backup files or create an new account.
|
||||
</string>
|
||||
<string name="account_setup_device_sectionheader">Device</string>
|
||||
<string name="account_setup_device_sectionheader">Found on Device</string>
|
||||
<string name="account_setup_basics_instructions">Enter this account\'s email address:</string>
|
||||
<string name="account_setup_basics_email_hint">Email address</string>
|
||||
<string name="account_setup_basics_password_hint">Password</string>
|
||||
|
@ -20,6 +20,7 @@ import java.io.UnsupportedEncodingException;
|
||||
import java.net.URI;
|
||||
import java.net.URISyntaxException;
|
||||
import java.net.URLEncoder;
|
||||
import java.util.HashSet;
|
||||
|
||||
/**
|
||||
* User: dzan
|
||||
@ -197,17 +198,20 @@ public class AccountSetupIndex extends K9ListActivity implements OnItemClickList
|
||||
*/
|
||||
private void fillFromDevice(SectionListAdapter<AccountSuggestion> adp){
|
||||
|
||||
HashSet<String> tmpDeDup = new HashSet<String>();
|
||||
|
||||
for( android.accounts.Account acc : AccountManager.get(this).getAccounts() )
|
||||
if( mEmailValidator.isValidAddressOnly(acc.name) )
|
||||
adp.add(getString(R.string.account_setup_device_sectionheader), new AccountSuggestion(acc.name, SuggestionType.DEVICE));
|
||||
if( tmpDeDup.add(acc.name) )
|
||||
adp.add(getString(R.string.account_setup_device_sectionheader), new AccountSuggestion(acc.name, SuggestionType.DEVICE));
|
||||
|
||||
// TEMP DATA TO TEST
|
||||
accountAdapter.add("file1", new AccountSuggestion("piet@snot.com",SuggestionType.BACKUP));
|
||||
/*accountAdapter.add("file1", new AccountSuggestion("piet@snot.com",SuggestionType.BACKUP));
|
||||
accountAdapter.add("file1", new AccountSuggestion("piet@snot.com",SuggestionType.BACKUP));
|
||||
accountAdapter.add("file1", new AccountSuggestion("piet@snot.com",SuggestionType.BACKUP));
|
||||
accountAdapter.add("file2", new AccountSuggestion("piet@snot.com",SuggestionType.BACKUP));
|
||||
accountAdapter.add("file2", new AccountSuggestion("piet@snot.com",SuggestionType.BACKUP));
|
||||
accountAdapter.add("file3", new AccountSuggestion("piet@snot.com",SuggestionType.BACKUP));
|
||||
accountAdapter.add("file3", new AccountSuggestion("piet@snot.com",SuggestionType.BACKUP));*/
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user