diff options
author | David Edmundson <david@davidedmundson.co.uk> | 2011-11-26 12:40:52 +0000 |
---|---|---|
committer | David Edmundson <david@davidedmundson.co.uk> | 2011-11-26 12:40:52 +0000 |
commit | 5981a0e74a1ec193c3d86f58f8674a4b204de41b (patch) | |
tree | c261c82d60bd526f6cd7448dac1ec3da00a3393f /liblightdm-qt | |
parent | 999d9953b1b1e8e05504bc8f8f808e9d55da13b2 (diff) | |
download | lightdm-5981a0e74a1ec193c3d86f58f8674a4b204de41b.tar.gz |
Fix final methods in greeter
Diffstat (limited to 'liblightdm-qt')
-rw-r--r-- | liblightdm-qt/QLightDM/greeter.h | 8 | ||||
-rw-r--r-- | liblightdm-qt/QLightDM/usersmodel.h | 3 | ||||
-rw-r--r-- | liblightdm-qt/greeter.cpp | 24 |
3 files changed, 26 insertions, 9 deletions
diff --git a/liblightdm-qt/QLightDM/greeter.h b/liblightdm-qt/QLightDM/greeter.h index dea521d2..3888210a 100644 --- a/liblightdm-qt/QLightDM/greeter.h +++ b/liblightdm-qt/QLightDM/greeter.h @@ -38,10 +38,7 @@ public: explicit Greeter(QObject* parent=0); virtual ~Greeter(); - QString timedLoginUser() const; - int timedLoginDelay() const; - - QString getHint(const QString &name) const; + QString getHint(const QString &name) const; QString defaultSessionHint() const; bool hideUsersHint() const; bool hasGuestAccountHint() const; @@ -50,6 +47,7 @@ public: QString autologinUserHint() const; bool autologinGuestHint() const; int autologinTimeoutHint() const; + bool inAuthentication() const; bool isAuthenticated() const; QString authenticationUser() const; @@ -71,7 +69,7 @@ signals: private: GreeterPrivate *d_ptr; - Q_DECLARE_PRIVATE(Greeter); + Q_DECLARE_PRIVATE(Greeter) }; }; diff --git a/liblightdm-qt/QLightDM/usersmodel.h b/liblightdm-qt/QLightDM/usersmodel.h index 280a019b..39b94188 100644 --- a/liblightdm-qt/QLightDM/usersmodel.h +++ b/liblightdm-qt/QLightDM/usersmodel.h @@ -36,9 +36,10 @@ public: QVariant data(const QModelIndex &index, int role) const; protected: - UsersModelPrivate * const d_ptr; private: + UsersModelPrivate * const d_ptr; + Q_DECLARE_PRIVATE(UsersModel) }; diff --git a/liblightdm-qt/greeter.cpp b/liblightdm-qt/greeter.cpp index f8eca222..cf47ec59 100644 --- a/liblightdm-qt/greeter.cpp +++ b/liblightdm-qt/greeter.cpp @@ -147,13 +147,13 @@ bool Greeter::isAuthenticated() const QString Greeter::authenticationUser() const { Q_D(const Greeter); - const gchar* string = lightdm_greeter_get_authentication_user(d->ldmGreeter); - QString authenticationUser = QString::fromLocal8Bit(string); - return authenticationUser; + return QString::fromLocal8Bit(lightdm_greeter_get_authentication_user(d->ldmGreeter)); } void Greeter::setLanguage (const QString &language) { + Q_D(Greeter); + lightdm_greeter_set_language(d->ldmGreeter, language.toLocal8Bit().constData()); } bool Greeter::startSessionSync(const QString &session) @@ -165,38 +165,56 @@ bool Greeter::startSessionSync(const QString &session) QString Greeter::getHint(const QString &name) const { + Q_D(Greeter()); + return lightdm_greeter_get_hint(d->ldmGreeter, name.toLocal8Bit().constData()); } QString Greeter::defaultSessionHint() const { + Q_D(const Greeter); + return QString::fromLocal8Bit(lightdm_greeter_get_default_session_hint(d->ldmGreeter)); } bool Greeter::hideUsersHint() const { + Q_D(const Greeter); + return lightdm_greeter_get_hide_users_hint(d->ldmGreeter); } bool Greeter::hasGuestAccountHint() const { + Q_D(const Greeter); + return lightdm_greeter_get_has_guest_account_hint(d->ldmGreeter); } QString Greeter::selectUserHint() const { + Q_D(const Greeter); + return QString::fromLocal8Bit(lightdm_greeter_get_select_user_hint(d->ldmGreeter)); } bool Greeter::selectGuestHint() const { + Q_D(const Greeter); + return lightdm_greeter_get_select_guest_hint(d->ldmGreeter); } QString Greeter::autologinUserHint() const { + Q_D(const Greeter); + return QString::fromLocal8Bit(lightdm_greeter_get_autologin_user_hint(d->ldmGreeter)); } bool Greeter::autologinGuestHint() const { + Q_D(const Greeter); + return lightdm_greeter_get_autologin_guest_hint(d->ldmGreeter); } int Greeter::autologinTimeoutHint() const { + Q_D(const Greeter); + return lightdm_greeter_get_autologin_timeout_hint(d->ldmGreeter); } #include "greeter_moc.cpp" |