|
|
@ -334,6 +334,13 @@ void LDAPConfig::reBondToRealm() {
|
|
|
|
passdlg.m_base->ldapAdminRealm->setText(realmName);
|
|
|
|
passdlg.m_base->ldapAdminRealm->setText(realmName);
|
|
|
|
if (passdlg.exec() == TQDialog::Accepted) {
|
|
|
|
if (passdlg.exec() == TQDialog::Accepted) {
|
|
|
|
setEnabled(false);
|
|
|
|
setEnabled(false);
|
|
|
|
|
|
|
|
if (LDAPManager::unbondRealm(m_realms[realmName], passdlg.m_base->ldapAdminUsername->text(), passdlg.m_base->ldapAdminPassword->password(), passdlg.m_base->ldapAdminRealm->text(), &errorString) == 0) {
|
|
|
|
|
|
|
|
// Success!
|
|
|
|
|
|
|
|
realmcfg.bonded = false;
|
|
|
|
|
|
|
|
m_realms.remove(realmName);
|
|
|
|
|
|
|
|
m_realms.insert(realmName, realmcfg);
|
|
|
|
|
|
|
|
save();
|
|
|
|
|
|
|
|
|
|
|
|
if (LDAPManager::bondRealm(passdlg.m_base->ldapAdminUsername->text(), passdlg.m_base->ldapAdminPassword->password(), passdlg.m_base->ldapAdminRealm->text(), &errorString) == 0) {
|
|
|
|
if (LDAPManager::bondRealm(passdlg.m_base->ldapAdminUsername->text(), passdlg.m_base->ldapAdminPassword->password(), passdlg.m_base->ldapAdminRealm->text(), &errorString) == 0) {
|
|
|
|
// Success!
|
|
|
|
// Success!
|
|
|
|
realmcfg.bonded = true;
|
|
|
|
realmcfg.bonded = true;
|
|
|
@ -344,6 +351,10 @@ void LDAPConfig::reBondToRealm() {
|
|
|
|
else {
|
|
|
|
else {
|
|
|
|
KMessageBox::error(this, i18n("<qt><b>Unable to bond to realm!</b><p>Details: %1</qt>").arg(errorString), i18n("Unable to Bond to Realm"));
|
|
|
|
KMessageBox::error(this, i18n("<qt><b>Unable to bond to realm!</b><p>Details: %1</qt>").arg(errorString), i18n("Unable to Bond to Realm"));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
else {
|
|
|
|
|
|
|
|
KMessageBox::error(this, i18n("<qt><b>Unable to unbond from realm!</b><p>%1</qt>").arg(errorString), i18n("Unable to Unbond from Realm"));
|
|
|
|
|
|
|
|
}
|
|
|
|
setEnabled(true);
|
|
|
|
setEnabled(true);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|