summaryrefslogtreecommitdiff
path: root/user.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'user.cxx')
-rw-r--r--user.cxx113
1 files changed, 0 insertions, 113 deletions
diff --git a/user.cxx b/user.cxx
index 59229da..8bc593c 100644
--- a/user.cxx
+++ b/user.cxx
@@ -1,5 +1,3 @@
-#include <cstddef>
-#include <rtclient.h>
#include "qrtclient/user.hxx"
namespace RTClient {
@@ -201,117 +199,6 @@ void User::setDisabled(bool disabled)
if (m_disabled != disabled) {
m_disabled = disabled;
emit disabledChanged();
- void User::update(rtclient_user* user)
- {
- if (user) {
- if (user->id) {
- m_id = user->id;
- emit idChanged();
- }
- if (user->email_address) {
- m_emailAddress = user->email_address;
- emit emailAddressChanged();
- }
- if (user->real_name) {
- m_realName = user->real_name;
- emit realNameChanged();
- }
- if (user->nick_name) {
- m_nickName = user->nick_name;
- emit nickNameChanged();
- }
- if (user->organization) {
- m_organization = user->organization;
- emit organizationChanged();
- }
- if (user->address1) {
- m_address1 = user->address1;
- emit address1Changed();
- }
- if (user->address2) {
- m_address2 = user->address2;
- emit address2Changed();
- }
- if (user->city) {
- m_city = user->city;
- emit cityChanged();
- }
- if (user->state) {
- m_state = user->state;
- emit stateChanged();
- }
- if (user->zip) {
- m_zip = user->zip;
- emit zipChanged();
- }
- if (user->country) {
- m_country = user->country;
- emit countryChanged();
- }
- if (user->home_phone) {
- m_homePhone = user->home_phone;
- emit homePhoneChanged();
- }
- if (user->work_phone) {
- m_workPhone = user->work_phone;
- emit workPhoneChanged();
- }
- if (user->mobile_phone) {
- m_mobilePhone = user->mobile_phone;
- emit mobilePhoneChanged();
- }
- if (user->pager_phone) {
- m_pagerPhone = user->pager_phone;
- emit pagerPhoneChanged();
- }
- if (user->gecos) {
- m_gecos = user->gecos;
- emit gecosChanged();
- }
- if (user->timezone) {
- m_timezone = user->timezone;
- emit timezoneChanged();
- }
- if (user->lang) {
- m_lang = user->lang;
- emit langChanged();
- }
- if (user->privileged) {
- m_privileged = user->privileged;
- emit privilegedChanged();
- }
- if (!user->disabled) {
- m_disabled = user->disabled;
- emit disabledChanged();
- }
- rtclient_user_free(user);
- } else {
- m_id = 0;
- m_name = "";
- m_password = "";
- m_emailAddress = "";
- m_realName = "";
- m_nickName = "";
- m_organization = "";
- m_address1 = "";
- m_address2 = "";
- m_city = "";
- m_state = "";
- m_zip = "";
- m_country = "";
- m_homePhone = "";
- m_workPhone = "";
- m_mobilePhone = "";
- m_pagerPhone = "";
- m_contactInfo = "";
- m_comments = "";
- m_signature = "";
- m_gecos = "";
- m_lang = RTCLIENT_USER_LANG_NONE;
- m_timezone = RTCLIENT_USER_TIMEZONE_NONE;
- m_privileged = false;
- m_disabled = true;
- }
}
}