Search in sources :

Example 1 with AccountCredentials

use of cx.ring.model.AccountCredentials in project ring-client-android by savoirfairelinux.

the class SecurityAccountFragment method addAllCredentials.

@Override
public void addAllCredentials(ArrayList<AccountCredentials> credentials) {
    int i = 0;
    for (AccountCredentials cred : credentials) {
        CredentialsPreference toAdd = new CredentialsPreference(getPreferenceManager().getContext());
        toAdd.setKey("credential" + i);
        toAdd.setPersistent(false);
        toAdd.setCreds(cred);
        toAdd.setIcon(null);
        credentialsCategory.addPreference(toAdd);
        i++;
        toAdd.setOnPreferenceChangeListener(editCredentialListener);
    }
}
Also used : CredentialsPreference(cx.ring.views.CredentialsPreference) AccountCredentials(cx.ring.model.AccountCredentials)

Aggregations

AccountCredentials (cx.ring.model.AccountCredentials)1 CredentialsPreference (cx.ring.views.CredentialsPreference)1