1 /* 2 SPDX-FileCopyrightText: 2021 Laurent Montel <montel@kde.org> 3 4 SPDX-License-Identifier: GPL-2.0-or-later 5 */ 6 7 #include "scamconfigureutils.h" 8 #include <KLocalizedString> convertEnumToString(MessageViewer::ScamDetectionInfo::ScamDetectionField flag)9QString ScamConfigureUtils::convertEnumToString(MessageViewer::ScamDetectionInfo::ScamDetectionField flag) 10 { 11 switch (flag) { 12 case MessageViewer::ScamDetectionInfo::ScamDetectionField::None: 13 break; 14 case MessageViewer::ScamDetectionInfo::ScamDetectionField::DisableAll: 15 return i18n("Disable All Check"); 16 case MessageViewer::ScamDetectionInfo::ScamDetectionField::RedirectUrl: 17 return i18n("Redirect Url"); 18 case MessageViewer::ScamDetectionInfo::ScamDetectionField::HasIp: 19 return i18n("Has Ip"); 20 } 21 return {}; 22 } 23