mirror of
https://github.com/moparisthebest/k-9
synced 2024-11-27 11:42:16 -05:00
Move initializeViewListeners() to onPostCreate()
Per comments in PR #474 https://github.com/k9mail/k-9/pull/474#commitcomment-7417262
This commit is contained in:
parent
f7fb0cca41
commit
b39f9b95f1
@ -86,11 +86,6 @@ public class AccountSetupBasics extends K9Activity
|
|||||||
|
|
||||||
mNextButton.setOnClickListener(this);
|
mNextButton.setOnClickListener(this);
|
||||||
mManualSetupButton.setOnClickListener(this);
|
mManualSetupButton.setOnClickListener(this);
|
||||||
|
|
||||||
if (savedInstanceState == null) {
|
|
||||||
initializeViewListeners();
|
|
||||||
validateFields();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void initializeViewListeners() {
|
private void initializeViewListeners() {
|
||||||
@ -129,6 +124,12 @@ public class AccountSetupBasics extends K9Activity
|
|||||||
|
|
||||||
updateViewVisibility(mClientCertificateCheckBox.isChecked());
|
updateViewVisibility(mClientCertificateCheckBox.isChecked());
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onPostCreate(Bundle savedInstanceState) {
|
||||||
|
super.onPostCreate(savedInstanceState);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* We wait until now to initialize the listeners because we didn't want
|
* We wait until now to initialize the listeners because we didn't want
|
||||||
* the OnCheckedChangeListener active while the
|
* the OnCheckedChangeListener active while the
|
||||||
|
@ -295,11 +295,6 @@ public class AccountSetupIncoming extends K9Activity implements OnClickListener
|
|||||||
mCurrentPortViewSetting = mPortView.getText().toString();
|
mCurrentPortViewSetting = mPortView.getText().toString();
|
||||||
|
|
||||||
mSubscribedFoldersOnly.setChecked(mAccount.subscribedFoldersOnly());
|
mSubscribedFoldersOnly.setChecked(mAccount.subscribedFoldersOnly());
|
||||||
|
|
||||||
if (savedInstanceState == null) {
|
|
||||||
initializeViewListeners();
|
|
||||||
validateFields();
|
|
||||||
}
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
failure(e);
|
failure(e);
|
||||||
}
|
}
|
||||||
@ -383,8 +378,8 @@ public class AccountSetupIncoming extends K9Activity implements OnClickListener
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void onRestoreInstanceState(Bundle savedInstanceState) {
|
protected void onPostCreate(Bundle savedInstanceState) {
|
||||||
super.onRestoreInstanceState(savedInstanceState);
|
super.onPostCreate(savedInstanceState);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* We didn't want the listeners active while the state was being restored
|
* We didn't want the listeners active while the state was being restored
|
||||||
|
@ -191,11 +191,6 @@ public class AccountSetupOutgoing extends K9Activity implements OnClickListener,
|
|||||||
updatePortFromSecurityType();
|
updatePortFromSecurityType();
|
||||||
}
|
}
|
||||||
mCurrentPortViewSetting = mPortView.getText().toString();
|
mCurrentPortViewSetting = mPortView.getText().toString();
|
||||||
|
|
||||||
if (savedInstanceState == null) {
|
|
||||||
initializeViewListeners();
|
|
||||||
validateFields();
|
|
||||||
}
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
/*
|
/*
|
||||||
* We should always be able to parse our own settings.
|
* We should always be able to parse our own settings.
|
||||||
@ -316,6 +311,11 @@ public class AccountSetupOutgoing extends K9Activity implements OnClickListener,
|
|||||||
} else {
|
} else {
|
||||||
mRequireLoginSettingsView.setVisibility(View.GONE);
|
mRequireLoginSettingsView.setVisibility(View.GONE);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onPostCreate(Bundle savedInstanceState) {
|
||||||
|
super.onPostCreate(savedInstanceState);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* We didn't want the listeners active while the state was being restored
|
* We didn't want the listeners active while the state was being restored
|
||||||
|
Loading…
Reference in New Issue
Block a user