2021-12-28 15:56:41 +08:00
|
|
|
#ifndef COMMONDEFINES_H
|
|
|
|
#define COMMONDEFINES_H
|
2022-06-13 13:38:47 +08:00
|
|
|
#include <QFlags>
|
2021-12-28 15:56:41 +08:00
|
|
|
namespace UkuiSearch {
|
2022-06-13 13:38:47 +08:00
|
|
|
/**
|
|
|
|
* @brief The SearchType enum
|
|
|
|
*
|
|
|
|
*/
|
2021-12-28 15:56:41 +08:00
|
|
|
enum class SearchType
|
|
|
|
{
|
2022-06-13 13:38:47 +08:00
|
|
|
File = 1u << 0,
|
|
|
|
FileContent = 1u << 1,
|
|
|
|
Application = 1u << 2,
|
|
|
|
Setting = 1u << 3,
|
|
|
|
Note = 1u << 4,
|
|
|
|
Mail = 1u << 5,
|
|
|
|
Custom = 1u << 6
|
2021-12-28 15:56:41 +08:00
|
|
|
};
|
2022-06-13 13:38:47 +08:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief The ResultDataType enum
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
enum ResultDataType
|
|
|
|
{
|
|
|
|
FilePath = 1u << 0,
|
|
|
|
FileIconName = 1u << 1,
|
|
|
|
FileName = 1u << 2,
|
|
|
|
ModifiedTime = 1u << 3,
|
|
|
|
ApplicationDesktopPath = 1u << 4,
|
|
|
|
ApplicationLocalName = 1u << 5,
|
|
|
|
ApplicationIconName = 1u << 6,
|
|
|
|
ApplicationDescription = 1u << 7,
|
|
|
|
IsOnlineApplication = 1u << 8
|
|
|
|
//add more...
|
|
|
|
|
|
|
|
};
|
|
|
|
Q_DECLARE_FLAGS(ResultDataTypes, ResultDataType)
|
|
|
|
|
2021-12-28 15:56:41 +08:00
|
|
|
}
|
2022-06-13 13:38:47 +08:00
|
|
|
|
|
|
|
Q_DECLARE_OPERATORS_FOR_FLAGS(UkuiSearch::ResultDataTypes)
|
|
|
|
|
2021-12-28 15:56:41 +08:00
|
|
|
#endif // COMMONDEFINES_H
|