Changeset View
Changeset View
Standalone View
Standalone View
src/print.h
Show All 15 Lines | |||||
16 | * | 16 | * | ||
17 | * Authors: | 17 | * Authors: | ||
18 | * Jan Grulich <jgrulich@redhat.com> | 18 | * Jan Grulich <jgrulich@redhat.com> | ||
19 | */ | 19 | */ | ||
20 | 20 | | |||
21 | #ifndef XDG_DESKTOP_PORTAL_KDE_PRINT_H | 21 | #ifndef XDG_DESKTOP_PORTAL_KDE_PRINT_H | ||
22 | #define XDG_DESKTOP_PORTAL_KDE_PRINT_H | 22 | #define XDG_DESKTOP_PORTAL_KDE_PRINT_H | ||
23 | 23 | | |||
24 | #include <QObject> | 24 | #include <QDBusAbstractAdaptor> | ||
25 | #include <QDBusObjectPath> | 25 | #include <QDBusObjectPath> | ||
26 | #include <QDBusUnixFileDescriptor> | 26 | #include <QDBusUnixFileDescriptor> | ||
27 | #include <QPrinter> | 27 | #include <QPrinter> | ||
28 | #include <QPageSize> | 28 | #include <QPageSize> | ||
29 | 29 | | |||
30 | class Print : public QObject | 30 | class PrintPortal : public QDBusAbstractAdaptor | ||
31 | { | 31 | { | ||
32 | Q_OBJECT | 32 | Q_OBJECT | ||
33 | Q_CLASSINFO("D-Bus Interface", "org.freedesktop.impl.portal.Print") | 33 | Q_CLASSINFO("D-Bus Interface", "org.freedesktop.impl.portal.Print") | ||
34 | public: | 34 | public: | ||
35 | Print(QObject *parent = nullptr); | 35 | PrintPortal(QObject *parent); | ||
36 | ~Print(); | 36 | ~PrintPortal(); | ||
37 | 37 | | |||
38 | public Q_SLOTS: | 38 | public Q_SLOTS: | ||
39 | uint print(const QDBusObjectPath &handle, | 39 | uint Print(const QDBusObjectPath &handle, | ||
40 | const QString &app_id, | 40 | const QString &app_id, | ||
41 | const QString &parent_window, | 41 | const QString &parent_window, | ||
42 | const QString &title, | 42 | const QString &title, | ||
43 | const QDBusUnixFileDescriptor &fd, | 43 | const QDBusUnixFileDescriptor &fd, | ||
44 | const QVariantMap &options, | 44 | const QVariantMap &options, | ||
45 | QVariantMap &results); | 45 | QVariantMap &results); | ||
46 | 46 | | |||
47 | uint preparePrint(const QDBusObjectPath &handle, | 47 | uint PreparePrint(const QDBusObjectPath &handle, | ||
48 | const QString &app_id, | 48 | const QString &app_id, | ||
49 | const QString &parent_window, | 49 | const QString &parent_window, | ||
50 | const QString &title, | 50 | const QString &title, | ||
51 | const QVariantMap &settings, | 51 | const QVariantMap &settings, | ||
52 | const QVariantMap &page_setup, | 52 | const QVariantMap &page_setup, | ||
53 | const QVariantMap &options, | 53 | const QVariantMap &options, | ||
54 | QVariantMap &results); | 54 | QVariantMap &results); | ||
55 | private: | 55 | private: | ||
Show All 22 Lines |