17 #include "DBusGreeterList.h"
20 #include <QDBusMessage>
21 #include <QStringList>
23 DBusGreeterList::DBusGreeterList(Greeter *greeter,
const QString &path)
24 : UnityDBusObject(path,
"com.canonical.UnityGreeter", true, greeter),
27 connect(m_greeter, SIGNAL(authenticationUserChanged(
const QString &)),
this, SLOT(authenticationUserChangedHandler(
const QString &)));
28 connect(m_greeter, SIGNAL(promptlessChanged()),
this, SLOT(promptlessChangedHandler()));
31 QString DBusGreeterList::GetActiveEntry()
const
33 return m_greeter->authenticationUser();
36 void DBusGreeterList::SetActiveEntry(
const QString &entry)
38 Q_EMIT m_greeter->requestAuthenticationUser(entry);
41 bool DBusGreeterList::entryIsLocked()
const
43 return !m_greeter->promptless();
46 void DBusGreeterList::authenticationUserChangedHandler(
const QString &user)
48 notifyPropertyChanged(
"ActiveEntry", user);
49 Q_EMIT EntrySelected(user);
52 void DBusGreeterList::promptlessChangedHandler()
54 notifyPropertyChanged(
"EntryIsLocked", entryIsLocked());
55 Q_EMIT entryIsLockedChanged();