Files
prodejna/core/define.h
T

44 lines
916 B
C
Raw Normal View History

#ifndef DEFINE_H
#define DEFINE_H
2026-10-12 16:29:43 +02:00
#include <QtGlobal>
#define ALL(arr) arr.begin(), arr.end()
2015-12-22 16:08:47 +01:00
// default rights
#define PERM_READ "READ"
#define PERM_ADD "ADD"
#define PERM_EDIT "EDIT"
#define PERM_DELETE "DELETE"
2016-02-19 15:34:52 +01:00
#define DEC_MULTIPLE 100
2017-10-13 12:53:15 +02:00
#define TO_DEC(num) (QDecDouble(num) / QDecDouble(DEC_MULTIPLE))
2026-10-12 16:29:43 +02:00
#define FROM_DEC(num) qRound((num * QDecDouble(DEC_MULTIPLE)).toDouble())
2016-02-19 15:34:52 +01:00
#ifndef PLUGIN_ROOT
#ifdef _WIN32
2023-05-29 16:27:10 +02:00
#ifdef QT_NO_DEBUG
#define PLUGIN_ROOT "/plugins"
#else
#define PLUGIN_ROOT "/../../plugins"
#endif
#else
#define PLUGIN_ROOT "/../plugins"
#endif
#endif
#ifndef REPORT_ROOT
#ifdef _WIN32
2023-05-29 16:27:10 +02:00
#ifdef QT_NO_DEBUG
#define REPORT_ROOT "/reports"
#else
#define REPORT_ROOT "/../../reports"
#endif
#else
#define REPORT_ROOT "/../reports"
#endif
#endif
#endif // DEFINE_H