2 * Copyright (C) 2013 Canonical, Ltd.
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; version 3.
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 * Author: Michael Terry <michael.terry@canonical.com>
20/* !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
21 * CHANGES MADE HERE MUST BE REFLECTED ON THE MOCK LIB
22 * COUNTERPART IN tests/mocks/Lightdm/liblightdm
23 * !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! */
27#include "GreeterPrivate.h"
28#include <QtCore/QCoreApplication>
34Greeter::Greeter(QObject *parent)
36 d_ptr(new GreeterPrivate(this))
44QString Greeter::authenticationUser() const
47 return d->authenticationUser;
50bool Greeter::hasGuestAccountHint() const
55QString Greeter::getHint(const QString &name) const
58 return QLatin1String("");
61QString Greeter::defaultSessionHint() const
63 return QStringLiteral("ubuntu");
66bool Greeter::hideUsersHint() const
71bool Greeter::showManualLoginHint() const
76bool Greeter::showRemoteLoginHint() const
81QString Greeter::selectUserHint() const
83 return QLatin1String("");
86bool Greeter::selectGuestHint() const
91QString Greeter::autologinUserHint() const
93 return QLatin1String("");
96bool Greeter::autologinGuestHint() const
101int Greeter::autologinTimeoutHint() const
106bool Greeter::inAuthentication() const
111QString Greeter::hostname() const
113 return QStringLiteral("hostname1");
116bool Greeter::isAuthenticated() const
119 return d->authenticated;
122bool Greeter::connectSync()
127void Greeter::authenticate(const QString &username)
131 d->authenticated = false;
132 d->authenticationUser = username;
133 d->handleAuthenticate();
136void Greeter::authenticateAsGuest()
139void Greeter::authenticateAutologin()
142void Greeter::authenticateRemote(const QString &session, const QString &username)
148void Greeter::cancelAuthentication()
151 d->cancelAuthentication();
154void Greeter::setLanguage (const QString &language)
159bool Greeter::startSessionSync(const QString &session)
165void Greeter::respond(const QString &response)
169 d->handleRespond(response);
172void Greeter::sendAuthenticationComplete()
174 if (qEnvironmentVariableIsEmpty("UNITY_TESTING")) {
175 // simulate PAM's delay
176 QTimer::singleShot(1000, this, &Greeter::authenticationComplete);
178 Q_EMIT authenticationComplete();
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list