Commit 55ee263e authored by Emmanuel Lepage's avatar Emmanuel Lepage

Fix "same as local" account setting, fix IP2IP LED color

parent 59951e2d
......@@ -32,7 +32,7 @@ void AccountView::initItemWidget()
if(isNew() || !enabled)
itemWidget->setState(AccountItemWidget::Unregistered);
else if(getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_REGISTERED)
else if(getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_REGISTERED || getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_READY)
itemWidget->setState(AccountItemWidget::Registered);
else
itemWidget->setState(AccountItemWidget::NotWorking);
......@@ -53,7 +53,7 @@ QColor AccountView::getStateColor()
{
if(getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_UNREGISTERED)
return Qt::black;
if(getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_REGISTERED)
if(getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_REGISTERED || getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_READY)
return Qt::darkGreen;
return Qt::red;
}
......@@ -63,7 +63,7 @@ QString AccountView::getStateColorName()
{
if(getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_UNREGISTERED)
return "black";
if(getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_REGISTERED)
if(getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_REGISTERED || getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_READY)
return "darkGreen";
return "red";
}
......@@ -105,7 +105,7 @@ void AccountView::updateState()
qDebug() << "itemWidget->setState(AccountItemWidget::Unregistered);";
itemWidget->setState(AccountItemWidget::Unregistered);
}
else if(getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_REGISTERED) {
else if(getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_REGISTERED || getAccountDetail(ACCOUNT_STATUS) == ACCOUNT_STATE_READY) {
qDebug() << "itemWidget->setState(AccountItemWidget::Registered);";
itemWidget->setState(AccountItemWidget::Registered);
}
......
......@@ -17,7 +17,7 @@
* along with this program; if not, write to the *
* Free Software Foundation, Inc., *
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
***************************************************************************/
**************************************************************************/
#include "ConfigurationDialog.h"
#include "conf/ConfigurationSkeleton.h"
......
This diff is collapsed.
......@@ -150,6 +150,7 @@ private slots:
void selectCredential(QListWidgetItem* item, QListWidgetItem* previous);
void loadCredentails(QString accountId);
void saveCredential(QString accountId);
void enablePublished();
signals:
......
......@@ -177,6 +177,7 @@
/** Account States */
#define ACCOUNT_STATE_REGISTERED "REGISTERED"
#define ACCOUNT_STATE_READY "READY"
#define ACCOUNT_STATE_UNREGISTERED "UNREGISTERED"
#define ACCOUNT_STATE_TRYING "TRYING"
#define ACCOUNT_STATE_ERROR "ERROR"
......
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