Pimcommon

purposemenumessagewidget.cpp
1/*
2 SPDX-FileCopyrightText: 2023-2024 Laurent Montel <montel.org>
3
4 SPDX-License-Identifier: GPL-2.0-or-later
5*/
6
7#include "purposemenumessagewidget.h"
8#include <QDesktopServices>
9#include <QUrl>
10
11using namespace PimCommon;
12PurposeMenuMessageWidget::PurposeMenuMessageWidget(QWidget *parent)
13 : KMessageWidget(parent)
14{
15 setVisible(false);
16 setCloseButtonVisible(true);
17 connect(this, &KMessageWidget::linkActivated, this, [](const QString &contents) {
19 });
20}
21
22PurposeMenuMessageWidget::~PurposeMenuMessageWidget() = default;
23
24void PurposeMenuMessageWidget::slotShareError(const QString &message)
25{
26 setMessageType(KMessageWidget::MessageType::Error);
27 setText(message);
29}
30
31void PurposeMenuMessageWidget::slotShareSuccess(const QString &message)
32{
33 setMessageType(KMessageWidget::MessageType::Information);
34 setText(message);
36}
37
38#include "moc_purposemenumessagewidget.cpp"
void linkActivated(const QString &contents)
void animatedShow()
void setMessageType(KMessageWidget::MessageType type)
void setText(const QString &text)
folderdialogacltab.h
bool openUrl(const QUrl &url)
QFuture< ArgsType< Signal > > connect(Sender *sender, Signal signal)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 4 2024 16:39:22 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.