Lines 81-86
const QString& InvitationsRfbServer::unattendedPassword() const
Link Here
|
81 |
return m_unattendedPassword; |
81 |
return m_unattendedPassword; |
82 |
} |
82 |
} |
83 |
|
83 |
|
|
|
84 |
bool InvitationsRfbServer::enableSharing() const |
85 |
{ |
86 |
return m_enableSharing; |
87 |
} |
88 |
|
84 |
void InvitationsRfbServer::setUnattendedPassword(const QString& password) |
89 |
void InvitationsRfbServer::setUnattendedPassword(const QString& password) |
85 |
{ |
90 |
{ |
86 |
m_unattendedPassword = password; |
91 |
m_unattendedPassword = password; |
Lines 108-113
void InvitationsRfbServer::stop()
Link Here
|
108 |
RfbServer::stop(); |
113 |
RfbServer::stop(); |
109 |
} |
114 |
} |
110 |
|
115 |
|
|
|
116 |
void InvitationsRfbServer::toggleSharing(bool allow) |
117 |
{ |
118 |
m_enableSharing = allow; |
119 |
} |
120 |
|
111 |
void InvitationsRfbServer::toggleUnattendedAccess(bool allow) |
121 |
void InvitationsRfbServer::toggleUnattendedAccess(bool allow) |
112 |
{ |
122 |
{ |
113 |
m_allowUnattendedAccess = allow; |
123 |
m_allowUnattendedAccess = allow; |
Lines 117-122
InvitationsRfbServer::InvitationsRfbServer()
Link Here
|
117 |
{ |
127 |
{ |
118 |
m_desktopPassword = readableRandomString(4)+"-"+readableRandomString(3); |
128 |
m_desktopPassword = readableRandomString(4)+"-"+readableRandomString(3); |
119 |
m_unattendedPassword = readableRandomString(4)+"-"+readableRandomString(3); |
129 |
m_unattendedPassword = readableRandomString(4)+"-"+readableRandomString(3); |
|
|
130 |
KConfigGroup krfbConfig(KSharedConfig::openConfig(),"MainWindow"); |
131 |
m_enableSharing = krfbConfig.readEntry( |
132 |
"enableSharing", QVariant(false)).toBool(); |
120 |
KConfigGroup krfbConfig(KSharedConfig::openConfig(),"Security"); |
133 |
KConfigGroup krfbConfig(KSharedConfig::openConfig(),"Security"); |
121 |
m_allowUnattendedAccess = krfbConfig.readEntry( |
134 |
m_allowUnattendedAccess = krfbConfig.readEntry( |
122 |
"allowUnattendedAccess", QVariant(false)).toBool(); |
135 |
"allowUnattendedAccess", QVariant(false)).toBool(); |
Lines 125-130
InvitationsRfbServer::InvitationsRfbServer()
Link Here
|
125 |
InvitationsRfbServer::~InvitationsRfbServer() |
138 |
InvitationsRfbServer::~InvitationsRfbServer() |
126 |
{ |
139 |
{ |
127 |
stop(); |
140 |
stop(); |
|
|
141 |
KConfigGroup krfbConfig(KSharedConfig::openConfig(),"MainWindow"); |
142 |
krfbConfig.writeEntry("enableSharing",m_enableSharing); |
128 |
KConfigGroup krfbConfig(KSharedConfig::openConfig(),"Security"); |
143 |
KConfigGroup krfbConfig(KSharedConfig::openConfig(),"Security"); |
129 |
krfbConfig.writeEntry("allowUnattendedAccess",m_allowUnattendedAccess); |
144 |
krfbConfig.writeEntry("allowUnattendedAccess",m_allowUnattendedAccess); |
130 |
if(!KrfbConfig::noWallet()) { |
145 |
if(!KrfbConfig::noWallet()) { |
Lines 145-150
InvitationsRfbServer::~InvitationsRfbServer()
Link Here
|
145 |
KStringHandler::obscure(m_unattendedPassword)); |
160 |
KStringHandler::obscure(m_unattendedPassword)); |
146 |
krfbConfig.writeEntry("allowUnattendedAccess", |
161 |
krfbConfig.writeEntry("allowUnattendedAccess", |
147 |
m_allowUnattendedAccess); |
162 |
m_allowUnattendedAccess); |
|
|
163 |
KConfigGroup krfbConfig(KSharedConfig::openConfig(),"MainWindow"); |
164 |
krfbConfig.writeEntry("enableSharing", |
165 |
m_enableSharing); |
148 |
} |
166 |
} |
149 |
} |
167 |
} |
150 |
|
168 |
|