DtkWidget
DTK Widget module
载入中...
搜索中...
未找到
dtrashmanager.h
1// SPDX-FileCopyrightText: 2017 - 2022 UnionTech Software Technology Co., Ltd.
2//
3// SPDX-License-Identifier: LGPL-3.0-or-later
4
5#ifndef DTKWIDGET_DTRASHMANAGER_H
6#define DTKWIDGET_DTRASHMANAGER_H
7
8#include <DObject>
9
10#include <dtkwidget_global.h>
11
12#include <QObject>
13
14#if DTK_VERSION < DTK_VERSION_CHECK(6, 0, 0, 0)
15
16DWIDGET_BEGIN_NAMESPACE
17
18class DTrashManagerPrivate;
19class D_DECL_DEPRECATED_X("Use libdtkcore") DTrashManager : public QObject, public DTK_CORE_NAMESPACE::DObject
20{
21public:
22 static DTrashManager *instance();
23
24 bool trashIsEmpty() const;
25 bool cleanTrash();
26 bool moveToTrash(const QString &filePath, bool followSymlink = false);
27
28protected:
29 DTrashManager();
30
31private:
32 D_DECLARE_PRIVATE(DTrashManager)
33};
34
35DWIDGET_END_NAMESPACE
36
37#endif // DTKWIDGET_DTRASHMANAGER_H
38
39#endif