Changeset View
Changeset View
Standalone View
Standalone View
src/renderer/scripting/KReportScriptHandler.cpp
Show All 37 Lines | |||||
38 | { | 38 | { | ||
39 | public: | 39 | public: | ||
40 | Private(); | 40 | Private(); | ||
41 | ~Private(); | 41 | ~Private(); | ||
42 | KReportScriptConstants *constants; | 42 | KReportScriptConstants *constants; | ||
43 | KReportScriptDebug *debug; | 43 | KReportScriptDebug *debug; | ||
44 | KReportScriptDraw *draw; | 44 | KReportScriptDraw *draw; | ||
45 | Scripting::Report *report; | 45 | Scripting::Report *report; | ||
46 | const KReportData *reportData; | 46 | const KReportDataSource *reportData; | ||
staniek: -> reportDataSource | |||||
47 | QString source; | 47 | QString source; | ||
48 | KReportDocument *reportDocument; | 48 | KReportDocument *reportDocument; | ||
49 | QJSEngine engine; | 49 | QJSEngine engine; | ||
50 | QJSValue scriptValue; | 50 | QJSValue scriptValue; | ||
51 | QMap<QString, QVariant> groups; | 51 | QMap<QString, QVariant> groups; | ||
52 | QMap<KReportSectionData*, Scripting::Section*> sectionMap; | 52 | QMap<KReportSectionData*, Scripting::Section*> sectionMap; | ||
53 | }; | 53 | }; | ||
54 | 54 | | |||
55 | KReportScriptHandler::Private::Private() : constants(new KReportScriptConstants), debug(new KReportScriptDebug), draw(new KReportScriptDraw) | 55 | KReportScriptHandler::Private::Private() : constants(new KReportScriptConstants), debug(new KReportScriptDebug), draw(new KReportScriptDraw) | ||
56 | { | 56 | { | ||
57 | } | 57 | } | ||
58 | 58 | | |||
59 | KReportScriptHandler::Private::~Private() | 59 | KReportScriptHandler::Private::~Private() | ||
60 | { | 60 | { | ||
61 | } | 61 | } | ||
62 | 62 | | |||
63 | KReportScriptHandler::KReportScriptHandler(const KReportData* kodata, KReportDocument* doc) : d(new Private()) | 63 | KReportScriptHandler::KReportScriptHandler(const KReportDataSource* kodata, KReportDocument* doc) : d(new Private()) | ||
staniek: kodata -> dataSource | |||||
64 | { | 64 | { | ||
65 | d->reportDocument = doc; | 65 | d->reportDocument = doc; | ||
66 | d->reportData = kodata; | 66 | d->reportData = kodata; | ||
67 | 67 | | |||
68 | //Add a general report object | 68 | //Add a general report object | ||
69 | d->report = new Scripting::Report(d->reportDocument); | 69 | d->report = new Scripting::Report(d->reportDocument); | ||
70 | 70 | | |||
71 | registerScriptObject(d->constants, QLatin1String("constants")); | 71 | registerScriptObject(d->constants, QLatin1String("constants")); | ||
▲ Show 20 Lines • Show All 131 Lines • Show Last 20 Lines |
-> reportDataSource