File indexing completed on 2024-05-12 05:15:04

0001 /*
0002   This file is part of the kcalutils library.
0003 
0004   SPDX-FileCopyrightText: 1998 Preston Brown <pbrown@kde.org>
0005   SPDX-FileCopyrightText: 2001-2003 Cornelius Schumacher <schumacher@kde.org>
0006 
0007   SPDX-License-Identifier: LGPL-2.0-or-later
0008 */
0009 #pragma once
0010 
0011 #include "kcalutils_export.h"
0012 #include <KCalendarCore/Calendar>
0013 
0014 class QMimeData;
0015 
0016 namespace KCalUtils
0017 {
0018 /**
0019   vCalendar drag&drop class.
0020 */
0021 namespace VCalDrag
0022 {
0023 /**
0024   Mime-type of iCalendar
0025 */
0026 [[nodiscard]] KCALUTILS_EXPORT QString mimeType();
0027 
0028 /**
0029   Return, if drag&drop object can be decode to vCalendar.
0030 */
0031 [[nodiscard]] KCALUTILS_EXPORT bool canDecode(const QMimeData *);
0032 
0033 /**
0034   Decode drag&drop object to vCalendar component \a vcal.
0035 */
0036 [[nodiscard]] KCALUTILS_EXPORT bool fromMimeData(const QMimeData *e, const KCalendarCore::Calendar::Ptr &cal);
0037 }
0038 }