File indexing completed on 2025-01-26 04:57:25

0001 /*
0002   SPDX-FileCopyrightText: 2016-2024 Laurent Montel <montel@kde.org>
0003 
0004   SPDX-License-Identifier: LGPL-2.0-or-later
0005 
0006 */
0007 
0008 #include "submittedformwarningwidget.h"
0009 
0010 #include <KLocalizedString>
0011 
0012 using namespace WebEngineViewer;
0013 
0014 SubmittedFormWarningWidget::SubmittedFormWarningWidget(QWidget *parent)
0015     : KMessageWidget(parent)
0016 {
0017     setVisible(false);
0018     setCloseButtonVisible(true);
0019     setMessageType(Warning);
0020     setPosition(KMessageWidget::Header);
0021     setWordWrap(true);
0022     setText(i18n("Submit form is not allowed in mailer. Please open url in a browser."));
0023 }
0024 
0025 SubmittedFormWarningWidget::~SubmittedFormWarningWidget() = default;
0026 
0027 void SubmittedFormWarningWidget::showWarning()
0028 {
0029     animatedShow();
0030 }
0031 
0032 #include "moc_submittedformwarningwidget.cpp"