diff --git a/accountdetails.cpp b/accountdetails.cpp index 4e5726711f2d0a4f9ff692d14cb71f5d5df9da70..0ea405d6f2bf75060bd9ca85165290f9259f0185 100644 --- a/accountdetails.cpp +++ b/accountdetails.cpp @@ -113,6 +113,8 @@ AccountDetails::setAccount(Account* currentAccount) { return; if (currentAccount_->protocol() == Account::Protocol::RING) { + ui->usernameLabel->setText(tr("RingID")); + ui->lrcfg_username->setReadOnly(true); if (currentAccount_->registeredName().isEmpty() ){ // If our user isn't registered on the blockhain ui->lrcfg_registeredName->clear(); ui->lrcfg_registeredName->setReadOnly(false); @@ -124,6 +126,9 @@ AccountDetails::setAccount(Account* currentAccount) { ui->lrcfg_registeredName->setReadOnly(true); ui->registerButton->hide(); } + } else { // If currentAccount_ is of type SIP + ui->usernameLabel->setText(tr("Username")); + ui->lrcfg_username->setReadOnly(false); } codecModel_ = currentAccount->codecModel(); diff --git a/accountdetails.ui b/accountdetails.ui index d7afdb1071172dd4d324bb64888dce1f5d457a6b..cfd13525f2ae5e6226c77a5e93db02b9fdc169c5 100644 --- a/accountdetails.ui +++ b/accountdetails.ui @@ -324,7 +324,7 @@ </widget> </item> <item row="1" column="0"> - <widget class="QLabel" name="usernameLabel"> + <widget class="QLabel" name="registeredNameLabel"> <property name="sizePolicy"> <sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred"> <horstretch>0</horstretch> @@ -340,7 +340,7 @@ <string notr="true">color: rgb(77, 77, 77);</string> </property> <property name="text"> - <string>Username</string> + <string>Public username</string> </property> <property name="buddy"> <cstring>lrcfg_registeredName</cstring> @@ -389,7 +389,7 @@ </item> </layout> </item> - <item row="3" column="0"> + <item row="4" column="0"> <widget class="QLabel" name="passwordLabel"> <property name="sizePolicy"> <sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred"> @@ -413,7 +413,7 @@ </property> </widget> </item> - <item row="3" column="1"> + <item row="4" column="1"> <widget class="QLineEdit" name="lrcfg_password"> <property name="sizePolicy"> <sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed"> @@ -432,7 +432,7 @@ </property> </widget> </item> - <item row="4" column="0"> + <item row="5" column="0"> <widget class="QLabel" name="proxyLabel"> <property name="sizePolicy"> <sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred"> @@ -456,7 +456,7 @@ </property> </widget> </item> - <item row="4" column="1"> + <item row="5" column="1"> <widget class="QLineEdit" name="lrcfg_proxy"> <property name="sizePolicy"> <sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed"> @@ -472,7 +472,7 @@ </property> </widget> </item> - <item row="5" column="0"> + <item row="6" column="0"> <widget class="QLabel" name="voicemailLabel"> <property name="sizePolicy"> <sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred"> @@ -496,7 +496,7 @@ </property> </widget> </item> - <item row="5" column="1"> + <item row="6" column="1"> <widget class="QLineEdit" name="lrcfg_mailbox"> <property name="sizePolicy"> <sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed"> @@ -512,7 +512,7 @@ </property> </widget> </item> - <item row="6" column="0"> + <item row="7" column="0"> <widget class="QCheckBox" name="lrcfg_autoAnswer"> <property name="font"> <font> @@ -527,7 +527,7 @@ </property> </widget> </item> - <item row="7" column="0"> + <item row="8" column="0"> <widget class="QCheckBox" name="lrcfg_upnpEnabled"> <property name="enabled"> <bool>true</bool> @@ -545,7 +545,7 @@ </property> </widget> </item> - <item row="8" column="0"> + <item row="9" column="0"> <widget class="QLabel" name="label"> <property name="font"> <font> @@ -560,7 +560,7 @@ </property> </widget> </item> - <item row="8" column="1"> + <item row="9" column="1"> <layout class="QHBoxLayout" name="horizontalLayout_2"> <item> <widget class="QRadioButton" name="rtpRadio"> @@ -650,6 +650,40 @@ </property> </widget> </item> + <item row="3" column="1"> + <widget class="QLineEdit" name="lrcfg_username"> + <property name="sizePolicy"> + <sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="minimumSize"> + <size> + <width>0</width> + <height>30</height> + </size> + </property> + </widget> + </item> + <item row="3" column="0"> + <widget class="QLabel" name="usernameLabel"> + <property name="font"> + <font> + <pointsize>11</pointsize> + </font> + </property> + <property name="styleSheet"> + <string notr="true">color: rgb(77, 77, 77);</string> + </property> + <property name="text"> + <string>Username</string> + </property> + <property name="buddy"> + <cstring>lrcfg_username</cstring> + </property> + </widget> + </item> </layout> </item> <item> diff --git a/stylesheet.css b/stylesheet.css index 38198f81c231b121593eefd3c33fe37f8699b6b4..2bd0e0efbe060cf5920be8fe194899ba0298ff8e 100644 --- a/stylesheet.css +++ b/stylesheet.css @@ -504,7 +504,7 @@ QLineEdit#lrcfg_alias, QLineEdit#lrcfg_hostname, QLineEdit#lrcfg_password, QLine QLineEdit#lrcfg_mailbox, QLineEdit#lrcfg_tlsPassword, QLineEdit#lrcfg_tlsServerName, QLineEdit#lrcfg_turnServerRealm, QLineEdit#lrcfg_turnServerUsername, QLineEdit#lrcfg_turnServerPassword, QLineEdit#lrcfg_turnServer, QLineEdit#lrcfg_publishedAddress, QLineEdit#lrcfg_registeredName, -QLineEdit#lrcfg_nameServiceURL{ +QLineEdit#lrcfg_nameServiceURL, QLineEdit#lrcfg_username{ background: transparent; border-radius: 0px; border-style: solid; @@ -528,7 +528,7 @@ QLineEdit#lrcfg_alias:focus, QLineEdit#lrcfg_hostname:focus, QLineEdit#lrcfg_pas QLineEdit#lrcfg_proxy:focus, QLineEdit#lrcfg_mailbox:focus, QLineEdit#lrcfg_tlsPassword:focus, QLineEdit#lrcfg_tlsServerName:focus, QLineEdit#lrcfg_turnServerRealm:focus, QLineEdit#lrcfg_turnServerUsername:focus, QLineEdit#lrcfg_turnServerPassword:focus, QLineEdit#lrcfg_turnServer:focus, QLineEdit#lrcfg_publishedAddress:focus, -QLineEdit#lrcfg_registeredName:focus, QLineEdit#lrcfg_nameServiceURL:focus{ +QLineEdit#lrcfg_registeredName:focus, QLineEdit#lrcfg_nameServiceURL:focus, QLineEdit#lrcfg_username:focus{ border-color: #3AC0D2; }