diff options
Diffstat (limited to 'core/polkitqt1-subject.cpp')
-rw-r--r-- | core/polkitqt1-subject.cpp | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/core/polkitqt1-subject.cpp b/core/polkitqt1-subject.cpp index dfc969711..dea13d9f2 100644 --- a/core/polkitqt1-subject.cpp +++ b/core/polkitqt1-subject.cpp @@ -20,21 +20,21 @@ #include "polkitqt1-subject.h" -#include <QtCore/QDebug> +#include <TQtCore/TQDebug> #include <polkit/polkit.h> -namespace PolkitQt1 +namespace PolkitTQt1 { -class Subject::Data : public QSharedData +class Subject::Data : public TQSharedData { public: Data() - : QSharedData() + : TQSharedData() , subject(0) {} Data(const Data& other) - : QSharedData(other) + : TQSharedData(other) , subject(other.subject) { g_object_ref(subject); @@ -60,13 +60,13 @@ Subject::Subject(PolkitSubject *subject) d->subject = subject; } -Subject::Subject(const PolkitQt1::Subject& other) +Subject::Subject(const PolkitTQt1::Subject& other) : d(other.d) { } -Subject& Subject::operator=(const PolkitQt1::Subject& other) +Subject& Subject::operator=(const PolkitTQt1::Subject& other) { d = other.d; return *this; @@ -91,13 +91,13 @@ void Subject::setSubject(PolkitSubject *subject) d->subject = subject; } -QString Subject::toString() const +TQString Subject::toString() const { Q_ASSERT(d->subject); - return QString::fromUtf8(polkit_subject_to_string(d->subject)); + return TQString::fromUtf8(polkit_subject_to_string(d->subject)); } -Subject Subject::fromString(const QString &string) +Subject Subject::fromString(const TQString &string) { // should be in polkit library!!! but for strange reason it's necessary to have it here g_type_init(); @@ -106,7 +106,7 @@ Subject Subject::fromString(const QString &string) GError *error = NULL; subject.d->subject = polkit_subject_from_string(string.toUtf8().data(), &error); if (error != NULL) { - qWarning() << QString("Cannot create Subject from string: %1").arg(error->message); + tqWarning() << TQString("Cannot create Subject from string: %1").arg(error->message); return NULL; } return subject; @@ -118,7 +118,7 @@ UnixProcessSubject::UnixProcessSubject(qint64 pid) setSubject(polkit_unix_process_new(pid)); } -UnixProcessSubject::UnixProcessSubject(qint64 pid, quint64 startTime) +UnixProcessSubject::UnixProcessSubject(qint64 pid, tquint64 startTime) : Subject() { setSubject(polkit_unix_process_new_full(pid, startTime)); @@ -146,7 +146,7 @@ void UnixProcessSubject::setPid(qint64 pid) } // ----- SystemBusName -SystemBusNameSubject::SystemBusNameSubject(const QString &name) +SystemBusNameSubject::SystemBusNameSubject(const TQString &name) : Subject() { setSubject(polkit_system_bus_name_new(name.toUtf8().data())); @@ -158,18 +158,18 @@ SystemBusNameSubject::SystemBusNameSubject(PolkitSystemBusName *pkSystemBusName) } -QString SystemBusNameSubject::name() const +TQString SystemBusNameSubject::name() const { - return QString::fromUtf8(polkit_system_bus_name_get_name((PolkitSystemBusName *) subject())); + return TQString::fromUtf8(polkit_system_bus_name_get_name((PolkitSystemBusName *) subject())); } -void SystemBusNameSubject::setName(const QString &name) +void SystemBusNameSubject::setName(const TQString &name) { polkit_system_bus_name_set_name((PolkitSystemBusName *) subject(), name.toUtf8().data()); } // ----- SystemSession -UnixSessionSubject::UnixSessionSubject(const QString &sessionId) +UnixSessionSubject::UnixSessionSubject(const TQString &sessionId) : Subject() { setSubject(polkit_unix_session_new(sessionId.toUtf8().data())); @@ -181,7 +181,7 @@ UnixSessionSubject::UnixSessionSubject(qint64 pid) GError *error = NULL; setSubject(polkit_unix_session_new_for_process_sync(pid, NULL, &error)); if (error != NULL) { - qWarning() << QString("Cannot create unix session: %1").arg(error->message); + tqWarning() << TQString("Cannot create unix session: %1").arg(error->message); setSubject(NULL); } } @@ -192,12 +192,12 @@ UnixSessionSubject::UnixSessionSubject(PolkitSystemBusName *pkUnixSession) } -QString UnixSessionSubject::sessionId() const +TQString UnixSessionSubject::sessionId() const { - return QString::fromUtf8(polkit_unix_session_get_session_id((PolkitUnixSession *) subject())); + return TQString::fromUtf8(polkit_unix_session_get_session_id((PolkitUnixSession *) subject())); } -void UnixSessionSubject::setSessionId(const QString &sessionId) +void UnixSessionSubject::setSessionId(const TQString &sessionId) { polkit_unix_session_set_session_id((PolkitUnixSession *) subject(), sessionId.toUtf8().data()); } |