File indexing completed on 2026-06-07 09:05:10

0001 /*
0002    SPDX-FileCopyrightText: 2023-2024 Laurent Montel <montel.org>
0003 
0004    SPDX-License-Identifier: LGPL-2.0-or-later
0005 */
0006 
0007 #include "githubpluginauthentication.h"
0008 #include "githubauthenticationinterface.h"
0009 #include <KLocalizedString>
0010 #include <KPluginFactory>
0011 
0012 K_PLUGIN_CLASS_WITH_JSON(GitHubPluginAuthentication, "ruqola_githubauthenticationplugin.json")
0013 
0014 GitHubPluginAuthentication::GitHubPluginAuthentication(QObject *parent, const QVariantList &)
0015     : PluginAuthentication(parent)
0016 {
0017 }
0018 
0019 GitHubPluginAuthentication::~GitHubPluginAuthentication() = default;
0020 
0021 PluginAuthenticationInterface *GitHubPluginAuthentication::createInterface(QObject *parent)
0022 {
0023     return new GitHubAuthenticationInterface(parent);
0024 }
0025 
0026 AuthenticationManager::AuthMethodType GitHubPluginAuthentication::type() const
0027 {
0028     return AuthenticationManager::AuthMethodType::GitHub;
0029 }
0030 
0031 QString GitHubPluginAuthentication::name() const
0032 {
0033     return i18n("GitHub");
0034 }
0035 
0036 QString GitHubPluginAuthentication::iconName() const
0037 {
0038     return QStringLiteral("dialog-password");
0039 }
0040 
0041 #include "githubpluginauthentication.moc"
0042 #include "moc_githubpluginauthentication.cpp"