LeechCraft
0.6.70-18450-gabe19ee3b0
Modular cross-platform feature rich live environment.
Toggle main menu visibility
Loading...
Searching...
No Matches
structures.h
Go to the documentation of this file.
1
/**********************************************************************
2
* LeechCraft - modular cross-platform feature rich internet client.
3
* Copyright (C) 2006-2014 Georg Rudoy
4
*
5
* Distributed under the Boost Software License, Version 1.0.
6
* (See accompanying file LICENSE or copy at https://www.boost.org/LICENSE_1_0.txt)
7
**********************************************************************/
8
9
#pragma once
10
11
#include <memory>
12
#include <QMetaType>
13
#include <QVariant>
14
#include <QString>
15
#include "
maxvalue.h
"
16
17
class
QMenu;
18
class
QIODevice;
19
20
namespace
LC
21
{
24
enum
TaskParameter
25
{
28
NoParameters
= 0,
29
32
NoAutostart
= 1,
33
36
DoNotSaveInHistory
= 2,
37
41
IsDownloaded
= 4,
42
45
FromUserInitiated
= 8,
46
49
DoNotNotifyUser
= 32,
50
54
Internal
= 64,
55
59
NotPersistent
= 128,
60
64
DoNotAnnounceEntity
= 256,
65
69
OnlyHandle
= 512,
70
74
OnlyDownload
= 1024,
75
79
AutoAccept
= 2048,
80
84
FromCommandLine
= 4096
85
};
86
87
Q_DECLARE_FLAGS
(TaskParameters,
TaskParameter
);
88
96
struct
Entity
97
{
113
QVariant
Entity_
;
114
123
QString
Location_
;
124
149
QString
Mime_
;
150
153
TaskParameters
Parameters_
=
NoParameters
;
154
165
QMap<QString, QVariant>
Additional_
;
166
};
167
174
enum class
CustomDataRoles
175
{
179
Tags
= Qt::UserRole + 100,
180
};
181
182
constexpr
int
operator+
(
CustomDataRoles
role)
noexcept
183
{
184
return
static_cast<
int
>
(role);
185
}
186
187
template
<>
188
inline
constexpr
int
MaxValue<CustomDataRoles>
= +
CustomDataRoles::Tags
;
189
190
enum class
Priority
191
{
192
Info
,
193
Warning
,
194
Critical
195
};
196
};
197
198
typedef
std::shared_ptr<QObject>
QObject_ptr
;
199
200
Q_DECLARE_METATYPE
(
LC::Entity
)
201
Q_DECLARE_METATYPE
(
QObject_ptr
)
202
Q_DECLARE_METATYPE
(LC::TaskParameters)
203
Q_DECLARE_METATYPE
(
LC::Priority
)
204
Q_DECLARE_OPERATORS_FOR_FLAGS (LC::TaskParameters)
QMap
Definition
anutil.h:15
maxvalue.h
LC
Definition
constants.h:15
LC::operator+
constexpr int operator+(JobHolderRole role) noexcept
Definition
ijobholder.h:91
LC::MaxValue
constexpr int MaxValue
Definition
maxvalue.h:14
LC::Q_DECLARE_FLAGS
Q_DECLARE_FLAGS(TabFeatures, LC::TabFeature)
LC::CustomDataRoles
CustomDataRoles
Definition
structures.h:175
LC::CustomDataRoles::Tags
@ Tags
Definition
structures.h:179
LC::Priority
Priority
Definition
structures.h:191
LC::Priority::Warning
@ Warning
Definition
structures.h:193
LC::Priority::Critical
@ Critical
Definition
structures.h:194
LC::Priority::Info
@ Info
Definition
structures.h:192
LC::TaskParameter
TaskParameter
Describes single task parameter.
Definition
structures.h:25
LC::DoNotSaveInHistory
@ DoNotSaveInHistory
Definition
structures.h:36
LC::FromUserInitiated
@ FromUserInitiated
Definition
structures.h:45
LC::Internal
@ Internal
Definition
structures.h:54
LC::AutoAccept
@ AutoAccept
Definition
structures.h:79
LC::OnlyHandle
@ OnlyHandle
Definition
structures.h:69
LC::FromCommandLine
@ FromCommandLine
Definition
structures.h:84
LC::DoNotNotifyUser
@ DoNotNotifyUser
Definition
structures.h:49
LC::IsDownloaded
@ IsDownloaded
Definition
structures.h:41
LC::NoParameters
@ NoParameters
Definition
structures.h:28
LC::NotPersistent
@ NotPersistent
Definition
structures.h:59
LC::DoNotAnnounceEntity
@ DoNotAnnounceEntity
Definition
structures.h:64
LC::OnlyDownload
@ OnlyDownload
Definition
structures.h:74
LC::NoAutostart
@ NoAutostart
Definition
structures.h:32
LC::Entity
A message used for inter-plugin communication.
Definition
structures.h:97
LC::Entity::Mime_
QString Mime_
MIME type of the entity.
Definition
structures.h:149
LC::Entity::Location_
QString Location_
Source or destination.
Definition
structures.h:123
LC::Entity::Entity_
QVariant Entity_
The entity that this object represents.
Definition
structures.h:113
LC::Entity::Parameters_
TaskParameters Parameters_
Parameters of this task.
Definition
structures.h:153
LC::Entity::Additional_
QMap< QString, QVariant > Additional_
Additional parameters.
Definition
structures.h:165
QObject_ptr
std::shared_ptr< QObject > QObject_ptr
Definition
structures.h:198
Q_DECLARE_METATYPE
Q_DECLARE_METATYPE(QVariantList *)
src
interfaces
structures.h
Generated by
1.17.0