2 * Copyright (C) 2014 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/>.
18#include "GreeterPrivate.h"
19#include <QtCore/QCoreApplication>
25Greeter::Greeter(QObject *parent)
27 d_ptr(new GreeterPrivate(this))
35QString Greeter::authenticationUser() const
38 return d->authenticationUser;
41bool Greeter::hasGuestAccountHint() const
46QString Greeter::getHint(const QString &name) const
52QString Greeter::defaultSessionHint() const
57bool Greeter::hideUsersHint() const
62bool Greeter::showManualLoginHint() const
67bool Greeter::showRemoteLoginHint() const
72bool Greeter::lockHint () const
77QString Greeter::selectUserHint() const
82bool Greeter::selectGuestHint() const
87QString Greeter::autologinUserHint() const
92bool Greeter::autologinGuestHint() const
97int Greeter::autologinTimeoutHint() const
102bool Greeter::inAuthentication() const
107QString Greeter::hostname() const
112bool Greeter::isAuthenticated() const
115 return d->authenticated;
118bool Greeter::connectSync()
123void Greeter::authenticate(const QString &username)
127 d->authenticated = false;
128 d->authenticationUser = username;
129 d->twoFactorDone = false;
130 QTimer::singleShot(0, this, SLOT(delayedAuthentication()));
133void Greeter::delayedAuthentication()
136 d->handleAuthenticate();
139void Greeter::authenticateAsGuest()
142void Greeter::authenticateAutologin()
145void Greeter::authenticateRemote(const QString &session, const QString &username)
151void Greeter::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 (qgetenv("UNITY_TESTING").isEmpty()) {
175 // simulate PAM's delay
176 QTimer::singleShot(1000, this, SIGNAL(authenticationComplete()));
178 Q_EMIT authenticationComplete();
182QString Greeter::mockMode() const
189void Greeter::setMockMode(QString mockMode)
193 if (d->mockMode != mockMode) {
194 d->mockMode = mockMode;
195 Q_EMIT mockModeChanged(mockMode);
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