Commit 8611345d authored by Alexandre Bourget's avatar Alexandre Bourget

Remove all that useless initConfig stuff!

parent fd87e1d6
......@@ -37,21 +37,6 @@ Account::~Account()
}
void
Account::initConfig(Conf::ConfigTree& config) {
/*
std::string section(_accountID);
std::string type_str("string");
std::string type_int("int");
config.addConfigTreeItem(section, Conf::ConfigTreeItem(CONFIG_ACCOUNT_ENABLE,"1", type_int));
config.addConfigTreeItem(section, Conf::ConfigTreeItem(CONFIG_ACCOUNT_AUTO_REGISTER, "1", type_int));
config.addConfigTreeItem(section, Conf::ConfigTreeItem(CONFIG_ACCOUNT_ALIAS, _("My account"), type_str));
*/
}
void
Account::loadConfig()
{
......
......@@ -57,14 +57,9 @@ typedef std::string AccountID;
*/
class Account{
public:
Account(const AccountID& accountID);
Account(const AccountID& accountID);
virtual ~Account();
/**
* Load the default properties for the account
*/
virtual void initConfig(Conf::ConfigTree& config);
virtual ~Account();
/**
* Load the settings for this account.
......
......@@ -71,26 +71,6 @@ IAXAccount::terminate()
return true;
}
void
IAXAccount::initConfig(Conf::ConfigTree& config)
{
/*
std::string section(_accountID);
std::string type_str("string");
std::string type_int("int");
// Account generic
Account::initConfig(config);
// IAX specific
config.verifyConfigTreeItem(section, CONFIG_ACCOUNT_TYPE, "IAX", type_str);
config.verifyConfigTreeItem(section, IAX_FULL_NAME, "", type_str);
config.verifyConfigTreeItem(section, IAX_HOST, "", type_str);
config.verifyConfigTreeItem(section, IAX_USER, "", type_str);
config.verifyConfigTreeItem(section, IAX_PASS, "", type_str);
*/
}
void
IAXAccount::loadConfig()
{
......
......@@ -34,8 +34,6 @@ public:
~IAXAccount();
/* virtual Account function implementation */
void initConfig(Conf::ConfigTree& config);
/** Actually unuseful, since config loading is done in init() */
void loadConfig();
void registerVoIPLink();
......
......@@ -1070,8 +1070,6 @@ ManagerImpl::initConfigFile (void)
fill_config_str(VOICEMAIL_NUM, DFT_VOICEMAIL);
fill_config_int(CONFIG_ZEROCONF, CONFIG_ZEROCONF_DEFAULT_STR);
initConfigAccount();
if (createSettingsPath() == 1) {
_exist = _config.populateFromFile(_path);
}
......@@ -2007,16 +2005,6 @@ ManagerImpl::getAccountLink(const AccountID& accountID)
return 0;
}
void
ManagerImpl::initConfigAccount() {
AccountMap::iterator iter = _accountMap.begin();
while ( iter != _accountMap.end() ) {
if (iter->second!=0) {
iter->second->initConfig(_config);
}
iter++;
}
}
#ifdef TEST
/**
......
......@@ -584,11 +584,6 @@ private:
*/
VoIPLink* getAccountLink(const AccountID& accountID);
/**
* load default account variable for each protocol
*/
void initConfigAccount();
#ifdef TEST
bool testCallAccountMap();
......
......@@ -81,30 +81,6 @@ SIPAccount::terminate()
return true;
}
void
SIPAccount::initConfig(Conf::ConfigTree& config)
{
/*
std::string section(_accountID);
std::string type_str("string");
std::string type_int("int");
// Account generic
Account::initConfig(config);
// SIP specific
config.verifyConfigTreeItem(section, CONFIG_ACCOUNT_TYPE, "SIP", type_str);
config.verifyConfigTreeItem(section, SIP_FULL_NAME, "", type_str);
config.verifyConfigTreeItem(section, SIP_USER_PART, "", type_str);
config.verifyConfigTreeItem(section, SIP_HOST_PART, "", type_str);
config.verifyConfigTreeItem(section, SIP_AUTH_NAME, "", type_str);
config.verifyConfigTreeItem(section, SIP_PASSWORD, "", type_str);
config.verifyConfigTreeItem(section, SIP_PROXY, "", type_str);
config.verifyConfigTreeItem(section, SIP_STUN_SERVER, "stun.fwdnet.net:3478", type_str);
config.verifyConfigTreeItem(section, SIP_USE_STUN, "0", type_int);
*/
}
void
SIPAccount::loadConfig()
{
......
......@@ -34,8 +34,6 @@ public:
virtual ~SIPAccount();
/* virtual Account function implementation */
void initConfig(Conf::ConfigTree& config);
/** Actually unuseful, since config loading is done in init() */
void loadConfig();
void registerVoIPLink();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment