summaryrefslogtreecommitdiffstats
path: root/tdmlib
diff options
context:
space:
mode:
Diffstat (limited to 'tdmlib')
-rw-r--r--tdmlib/dmctl.cpp4
-rw-r--r--tdmlib/dmctl.h6
-rw-r--r--tdmlib/kgreet_classic.cpp20
-rw-r--r--tdmlib/kgreet_classic.h6
-rw-r--r--tdmlib/kgreet_pam.cpp46
-rw-r--r--tdmlib/kgreet_pam.h8
-rw-r--r--tdmlib/kgreet_winbind.cpp46
-rw-r--r--tdmlib/kgreet_winbind.h10
-rw-r--r--tdmlib/kgreeterplugin.h4
9 files changed, 77 insertions, 73 deletions
diff --git a/tdmlib/dmctl.cpp b/tdmlib/dmctl.cpp
index 00c3cb489..6cd6f7e93 100644
--- a/tdmlib/dmctl.cpp
+++ b/tdmlib/dmctl.cpp
@@ -19,7 +19,7 @@
#include "dmctl.h"
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include <tdelocale.h>
#include <dcopclient.h>
@@ -531,4 +531,4 @@ DM::type()
return DMType;
}
-#endif // Q_WS_X11
+#endif // TQ_WS_X11
diff --git a/tdmlib/dmctl.h b/tdmlib/dmctl.h
index e0cdc966c..40ea95f26 100644
--- a/tdmlib/dmctl.h
+++ b/tdmlib/dmctl.h
@@ -32,7 +32,7 @@ struct SessEnt {
typedef TQValueList<SessEnt> SessList;
class DM {
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
public:
@@ -77,7 +77,7 @@ private:
void GDMAuthenticate();
-#else // Q_WS_X11
+#else // TQ_WS_X11
public:
DM() {}
@@ -100,7 +100,7 @@ public:
int type() { return NoDM }
-#endif // Q_WS_X11
+#endif // TQ_WS_X11
}; // class DM
diff --git a/tdmlib/kgreet_classic.cpp b/tdmlib/kgreet_classic.cpp
index 996754181..ac310a135 100644
--- a/tdmlib/kgreet_classic.cpp
+++ b/tdmlib/kgreet_classic.cpp
@@ -83,7 +83,7 @@ KClassicGreeter::KClassicGreeter( KGreeterPluginHandler *_handler,
if (!themer)
grid = new TQGridLayout( 0, 0, 10 );
- layoutItem = TQT_TQLAYOUTITEM(grid);
+ layoutItem = grid;
loginLabel = passwdLabel = passwd1Label = passwd2Label = 0;
loginEdit = 0;
@@ -94,10 +94,10 @@ KClassicGreeter::KClassicGreeter( KGreeterPluginHandler *_handler,
if (fixedUser.isEmpty()) {
loginEdit = new KLineEdit( parent );
loginEdit->setContextMenuEnabled( false );
- connect( loginEdit, TQT_SIGNAL(lostFocus()), TQT_SLOT(slotLoginLostFocus()) );
- connect( loginEdit, TQT_SIGNAL(lostFocus()), TQT_SLOT(slotActivity()) );
- connect( loginEdit, TQT_SIGNAL(textChanged( const TQString & )), TQT_SLOT(slotActivity()) );
- connect( loginEdit, TQT_SIGNAL(selectionChanged()), TQT_SLOT(slotActivity()) );
+ connect( loginEdit, TQ_SIGNAL(lostFocus()), TQ_SLOT(slotLoginLostFocus()) );
+ connect( loginEdit, TQ_SIGNAL(lostFocus()), TQ_SLOT(slotActivity()) );
+ connect( loginEdit, TQ_SIGNAL(textChanged( const TQString & )), TQ_SLOT(slotActivity()) );
+ connect( loginEdit, TQ_SIGNAL(selectionChanged()), TQ_SLOT(slotActivity()) );
if (pred) {
parent->setTabOrder( pred, loginEdit );
pred = loginEdit;
@@ -120,9 +120,9 @@ KClassicGreeter::KClassicGreeter( KGreeterPluginHandler *_handler,
else
passwdEdit = new TDMPasswordEdit( (KPasswordEdit::EchoModes)echoMode,
parent );
- connect( passwdEdit, TQT_SIGNAL(textChanged( const TQString & )),
- TQT_SLOT(slotActivity()) );
- connect( passwdEdit, TQT_SIGNAL(lostFocus()), TQT_SLOT(slotActivity()) );
+ connect( passwdEdit, TQ_SIGNAL(textChanged( const TQString & )),
+ TQ_SLOT(slotActivity()) );
+ connect( passwdEdit, TQ_SIGNAL(lostFocus()), TQ_SLOT(slotActivity()) );
if (pred) {
parent->setTabOrder( pred, passwdEdit );
pred = passwdEdit;
@@ -174,7 +174,7 @@ KClassicGreeter::~KClassicGreeter()
delete passwdEdit;
return;
}
- TQLayoutIterator it = TQT_TQLAYOUT(layoutItem)->iterator();
+ TQLayoutIterator it = static_cast<TQLayout*>(layoutItem)->iterator();
for (TQLayoutItem *itm = it.current(); itm; itm = ++it)
delete itm->widget();
delete layoutItem;
@@ -611,7 +611,7 @@ create( KGreeterPluginHandler *handler, KdmThemer *themer,
return new KClassicGreeter( handler, themer, parent, predecessor, fixedEntity, func, ctx );
}
-KDE_EXPORT kgreeterplugin_info kgreeterplugin_info = {
+TDE_EXPORT kgreeterplugin_info kgreeterplugin_info = {
I18N_NOOP("Username + password (classic)"), "classic",
kgreeterplugin_info::Local | kgreeterplugin_info::Presettable,
init, done, create
diff --git a/tdmlib/kgreet_classic.h b/tdmlib/kgreet_classic.h
index 3f36d5000..2da7e633c 100644
--- a/tdmlib/kgreet_classic.h
+++ b/tdmlib/kgreet_classic.h
@@ -32,12 +32,12 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
class KLineEdit;
class KPasswordEdit;
-class KSimpleConfig;
+class TDESimpleConfig;
class TQGridLayout;
class TQLabel;
class KClassicGreeter : public TQObject, public KGreeterPlugin {
- Q_OBJECT
+ TQ_OBJECT
public:
KClassicGreeter( KGreeterPluginHandler *handler,
@@ -81,7 +81,7 @@ class KClassicGreeter : public TQObject, public KGreeterPlugin {
TQLabel *loginLabel, *passwdLabel, *passwd1Label, *passwd2Label;
KLineEdit *loginEdit;
KPasswordEdit *passwdEdit, *passwd1Edit, *passwd2Edit;
- KSimpleConfig *stsFile;
+ TDESimpleConfig *stsFile;
TQString fixedUser, curUser;
Function func;
Context ctx;
diff --git a/tdmlib/kgreet_pam.cpp b/tdmlib/kgreet_pam.cpp
index e7a5f0747..f0581a601 100644
--- a/tdmlib/kgreet_pam.cpp
+++ b/tdmlib/kgreet_pam.cpp
@@ -55,7 +55,7 @@ protected:
virtual void contextMenuEvent( TQContextMenuEvent * ) {}
};
-static FILE* log;
+static FILE *logFile;
static void kg_debug(const char* fmt, ...)
{
va_list lst;
@@ -63,8 +63,8 @@ static void kg_debug(const char* fmt, ...)
#ifdef PAM_GREETER_DEBUG
#if 0
- vfprintf(log, fmt, lst);
- fflush(log);
+ vfprintf(logFile, fmt, lst);
+ fflush(logFile);
#else
char buf[6000];
sprintf(buf, "*** %s\n", fmt);
@@ -111,7 +111,7 @@ KPamGreeter::KPamGreeter( KGreeterPluginHandler *_handler,
m_themer = themer;
if (!themer)
- layoutItem = TQT_TQLAYOUTITEM(new TQGridLayout( 0, 0, 10 ));
+ layoutItem = new TQGridLayout( 0, 0, 10 );
loginLabel = 0;
authLabel.clear();
@@ -127,10 +127,10 @@ KPamGreeter::KPamGreeter( KGreeterPluginHandler *_handler,
if (fixedUser.isEmpty()) {
loginEdit = new KLineEdit( parent );
loginEdit->setContextMenuEnabled( false );
- connect( loginEdit, TQT_SIGNAL(lostFocus()), TQT_SLOT(slotLoginLostFocus()) );
- connect( loginEdit, TQT_SIGNAL(lostFocus()), TQT_SLOT(slotActivity()) );
- connect( loginEdit, TQT_SIGNAL(textChanged( const TQString & )), TQT_SLOT(slotActivity()) );
- connect( loginEdit, TQT_SIGNAL(selectionChanged()), TQT_SLOT(slotActivity()) );
+ connect( loginEdit, TQ_SIGNAL(lostFocus()), TQ_SLOT(slotLoginLostFocus()) );
+ connect( loginEdit, TQ_SIGNAL(lostFocus()), TQ_SLOT(slotActivity()) );
+ connect( loginEdit, TQ_SIGNAL(textChanged( const TQString & )), TQ_SLOT(slotActivity()) );
+ connect( loginEdit, TQ_SIGNAL(selectionChanged()), TQ_SLOT(slotActivity()) );
if (pred) {
parent->setTabOrder( pred, loginEdit );
pred = loginEdit;
@@ -154,9 +154,9 @@ KPamGreeter::KPamGreeter( KGreeterPluginHandler *_handler,
else
passwdEdit = new TDMPasswordEdit( echoMode,
parent );
- connect( passwdEdit, TQT_SIGNAL(textChanged( const TQString & )),
- TQT_SLOT(slotActivity()) );
- connect( passwdEdit, TQT_SIGNAL(lostFocus()), TQT_SLOT(slotActivity()) );
+ connect( passwdEdit, TQ_SIGNAL(textChanged( const TQString & )),
+ TQ_SLOT(slotActivity()) );
+ connect( passwdEdit, TQ_SIGNAL(lostFocus()), TQ_SLOT(slotActivity()) );
if (pred) {
parent->setTabOrder( pred, passwdEdit );
pred = passwdEdit;
@@ -211,7 +211,7 @@ KPamGreeter::~KPamGreeter()
delete loginEdit;
return;
}
- TQLayoutIterator it = TQT_TQLAYOUT(layoutItem)->iterator();
+ TQLayoutIterator it = static_cast<TQLayout*>(layoutItem)->iterator();
for (TQLayoutItem *itm = it.current(); itm; itm = ++it)
delete itm->widget();
delete layoutItem;
@@ -377,7 +377,7 @@ KPamGreeter::textPrompt( const char *prompt, bool echo, bool nonBlocking )
if (tdmlabel) {
//userLabel->setText(TQString::fromUtf8(prompt));
tdmlabel->label.text = TQString::fromUtf8(prompt);
- TQTimer::singleShot(0, tdmlabel, TQT_SLOT(update()));
+ TQTimer::singleShot(0, tdmlabel, TQ_SLOT(update()));
}
}
}
@@ -395,7 +395,7 @@ KPamGreeter::textPrompt( const char *prompt, bool echo, bool nonBlocking )
//userLabel->setText(TQString::fromUtf8(prompt));
TQString str = TQString::fromUtf8(prompt);
tdmlabel->label.text = str;
- TQTimer::singleShot(0, tdmlabel, TQT_SLOT(update()));
+ TQTimer::singleShot(0, tdmlabel, TQ_SLOT(update()));
}
}
@@ -405,9 +405,9 @@ KPamGreeter::textPrompt( const char *prompt, bool echo, bool nonBlocking )
passwdEdit = new TDMPasswordEdit( m_parentWidget );
else
passwdEdit = new TDMPasswordEdit( echoMode, m_parentWidget);
- connect( passwdEdit, TQT_SIGNAL(textChanged( const TQString & )),
- TQT_SLOT(slotActivity()) );
- connect( passwdEdit, TQT_SIGNAL(lostFocus()), TQT_SLOT(slotActivity()) );
+ connect( passwdEdit, TQ_SIGNAL(textChanged( const TQString & )),
+ TQ_SLOT(slotActivity()) );
+ connect( passwdEdit, TQ_SIGNAL(lostFocus()), TQ_SLOT(slotActivity()) );
authEdit << passwdEdit;
#if 1
@@ -435,7 +435,7 @@ KPamGreeter::textPrompt( const char *prompt, bool echo, bool nonBlocking )
if (0) {
//userLabel->setText(TQString::fromUtf8(prompt));
//tdmlabel->label.text = TQString::fromUtf8(prompt);
- //TQTimer::singleShot(0, tdmlabel, TQT_SLOT(update()));
+ //TQTimer::singleShot(0, tdmlabel, TQ_SLOT(update()));
}
}
else
@@ -691,9 +691,11 @@ static bool init( const TQString &,
static void done( void )
{
TDEGlobal::locale()->removeCatalogue( "kgreet_pam" );
- if (log && log != stderr)
- fclose(log);
- log = 0;
+ if (logFile && (logFile != stderr))
+ {
+ fclose(logFile);
+ }
+ logFile = 0;
}
static KGreeterPlugin *
@@ -706,7 +708,7 @@ create( KGreeterPluginHandler *handler, KdmThemer *themer,
return new KPamGreeter( handler, themer, parent, predecessor, fixedEntity, func, ctx );
}
-KDE_EXPORT kgreeterplugin_info kgreeterplugin_info = {
+TDE_EXPORT kgreeterplugin_info kgreeterplugin_info = {
I18N_NOOP("Pam conversation plugin"), "pam",
kgreeterplugin_info::Local | kgreeterplugin_info::Presettable,
init, done, create
diff --git a/tdmlib/kgreet_pam.h b/tdmlib/kgreet_pam.h
index f579f9522..9ce055113 100644
--- a/tdmlib/kgreet_pam.h
+++ b/tdmlib/kgreet_pam.h
@@ -32,12 +32,12 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
class KLineEdit;
class KPasswordEdit;
-class KSimpleConfig;
+class TDESimpleConfig;
class TQGridLayout;
class TQLabel;
class KPamGreeter : public TQObject, public KGreeterPlugin {
- Q_OBJECT
+ TQ_OBJECT
public:
KPamGreeter( KGreeterPluginHandler *handler,
@@ -68,7 +68,7 @@ class KPamGreeter : public TQObject, public KGreeterPlugin {
virtual void revive();
virtual void clear();
- TQGridLayout *getLayoutItem() const { return static_cast<TQGridLayout*>(TQT_TQLAYOUT(layoutItem)); }
+ TQGridLayout *getLayoutItem() const { return static_cast<TQGridLayout*>(layoutItem); }
public slots:
void slotLoginLostFocus();
@@ -84,7 +84,7 @@ class KPamGreeter : public TQObject, public KGreeterPlugin {
KLineEdit *loginEdit;
TQWidget* m_parentWidget;
TQValueList<KPasswordEdit*> authEdit;
- KSimpleConfig *stsFile;
+ TDESimpleConfig *stsFile;
KdmThemer *m_themer;
TQString fixedUser, curUser;
Function func;
diff --git a/tdmlib/kgreet_winbind.cpp b/tdmlib/kgreet_winbind.cpp
index 471095d7e..2c6080f40 100644
--- a/tdmlib/kgreet_winbind.cpp
+++ b/tdmlib/kgreet_winbind.cpp
@@ -32,7 +32,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#include <klineedit.h>
#include <kpassdlg.h>
#include <kuser.h>
-#include <kprocio.h>
+#include <tdeprocio.h>
#include <tqregexp.h>
#include <tqlayout.h>
@@ -91,8 +91,10 @@ KWinbindGreeter::KWinbindGreeter( KGreeterPluginHandler *_handler,
themer = 0;
if (!themer)
+ {
grid = new TQGridLayout( 0, 0, 10 );
- layoutItem = TQT_TQLAYOUTITEM(grid);
+ layoutItem = grid;
+ }
domainLabel = loginLabel = passwdLabel = passwd1Label = passwd2Label = 0;
domainCombo = 0;
@@ -106,12 +108,12 @@ KWinbindGreeter::KWinbindGreeter( KGreeterPluginHandler *_handler,
if (func != ChAuthTok) {
if (fixedUser.isEmpty()) {
domainCombo = new KComboBox( parent );
- connect( domainCombo, TQT_SIGNAL(activated( const TQString & )),
- TQT_SLOT(slotChangedDomain( const TQString & )) );
- connect( domainCombo, TQT_SIGNAL(activated( const TQString & )),
- TQT_SLOT(slotLoginLostFocus()) );
- connect( domainCombo, TQT_SIGNAL(activated( const TQString & )),
- TQT_SLOT(slotActivity()) );
+ connect( domainCombo, TQ_SIGNAL(activated( const TQString & )),
+ TQ_SLOT(slotChangedDomain( const TQString & )) );
+ connect( domainCombo, TQ_SIGNAL(activated( const TQString & )),
+ TQ_SLOT(slotLoginLostFocus()) );
+ connect( domainCombo, TQ_SIGNAL(activated( const TQString & )),
+ TQ_SLOT(slotActivity()) );
// should handle loss of focus
loginEdit = new KLineEdit( parent );
loginEdit->setContextMenuEnabled( false );
@@ -134,13 +136,13 @@ KWinbindGreeter::KWinbindGreeter( KGreeterPluginHandler *_handler,
grid->addWidget( loginLabel, line, 0 );
grid->addWidget( loginEdit, line++, 1 );
}
- connect( loginEdit, TQT_SIGNAL(lostFocus()), TQT_SLOT(slotLoginLostFocus()) );
- connect( loginEdit, TQT_SIGNAL(lostFocus()), TQT_SLOT(slotActivity()) );
- connect( loginEdit, TQT_SIGNAL(textChanged( const TQString & )), TQT_SLOT(slotActivity()) );
- connect( loginEdit, TQT_SIGNAL(selectionChanged()), TQT_SLOT(slotActivity()) );
- connect(&mDomainListTimer, TQT_SIGNAL(timeout()), TQT_SLOT(slotStartDomainList()));
+ connect( loginEdit, TQ_SIGNAL(lostFocus()), TQ_SLOT(slotLoginLostFocus()) );
+ connect( loginEdit, TQ_SIGNAL(lostFocus()), TQ_SLOT(slotActivity()) );
+ connect( loginEdit, TQ_SIGNAL(textChanged( const TQString & )), TQ_SLOT(slotActivity()) );
+ connect( loginEdit, TQ_SIGNAL(selectionChanged()), TQ_SLOT(slotActivity()) );
+ connect(&mDomainListTimer, TQ_SIGNAL(timeout()), TQ_SLOT(slotStartDomainList()));
domainCombo->insertStringList( staticDomains );
- TQTimer::singleShot(0, this, TQT_SLOT(slotStartDomainList()));
+ TQTimer::singleShot(0, this, TQ_SLOT(slotStartDomainList()));
} else if (ctx != Login && ctx != Shutdown && grid) {
domainLabel = new TQLabel( i18n("Domain:"), parent );
grid->addWidget( domainLabel, line, 0 );
@@ -154,9 +156,9 @@ KWinbindGreeter::KWinbindGreeter( KGreeterPluginHandler *_handler,
else
passwdEdit = new TDMPasswordEdit( (KPasswordEdit::EchoModes)echoMode,
parent );
- connect( passwdEdit, TQT_SIGNAL(textChanged( const TQString & )),
- TQT_SLOT(slotActivity()) );
- connect( passwdEdit, TQT_SIGNAL(lostFocus()), TQT_SLOT(slotActivity()) );
+ connect( passwdEdit, TQ_SIGNAL(textChanged( const TQString & )),
+ TQ_SLOT(slotActivity()) );
+ connect( passwdEdit, TQ_SIGNAL(lostFocus()), TQ_SLOT(slotActivity()) );
if (!grid) {
passwdEdit->adjustSize();
@@ -215,7 +217,7 @@ KWinbindGreeter::~KWinbindGreeter()
delete domainCombo;
return;
}
- TQLayoutIterator it = TQT_TQLAYOUT(layoutItem)->iterator();
+ TQLayoutIterator it = static_cast<TQLayout*>(layoutItem)->iterator();
for (TQLayoutItem *itm = it.current(); itm; itm = ++it)
delete itm->widget();
delete layoutItem;
@@ -610,9 +612,9 @@ KWinbindGreeter::slotStartDomainList()
mDomainListTimer.stop();
mDomainListing.clear();
- m_domainLister = new KProcIO;
- connect(m_domainLister, TQT_SIGNAL(readReady(KProcIO*)), TQT_SLOT(slotReadDomainList()));
- connect(m_domainLister, TQT_SIGNAL(processExited(TDEProcess*)), TQT_SLOT(slotEndDomainList()));
+ m_domainLister = new TDEProcIO;
+ connect(m_domainLister, TQ_SIGNAL(readReady(TDEProcIO*)), TQ_SLOT(slotReadDomainList()));
+ connect(m_domainLister, TQ_SIGNAL(processExited(TDEProcess*)), TQ_SLOT(slotEndDomainList()));
(*m_domainLister) << "wbinfo" << "--own-domain" << "--trusted-domains";
m_domainLister->setComm (TDEProcess::Stdout);
@@ -710,7 +712,7 @@ create( KGreeterPluginHandler *handler, KdmThemer *themer,
return new KWinbindGreeter( handler, themer, parent, predecessor, fixedEntity, func, ctx );
}
-KDE_EXPORT kgreeterplugin_info kgreeterplugin_info = {
+TDE_EXPORT kgreeterplugin_info kgreeterplugin_info = {
I18N_NOOP("Winbind / Samba"), "classic",
kgreeterplugin_info::Local | kgreeterplugin_info::Fielded | kgreeterplugin_info::Presettable,
init, done, create
diff --git a/tdmlib/kgreet_winbind.h b/tdmlib/kgreet_winbind.h
index 85565628e..8ec404edd 100644
--- a/tdmlib/kgreet_winbind.h
+++ b/tdmlib/kgreet_winbind.h
@@ -34,14 +34,14 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
class KComboBox;
class KLineEdit;
class KPasswordEdit;
-class KSimpleConfig;
+class TDESimpleConfig;
class TQGridLayout;
class TQLabel;
class KdmThemer;
-class KProcIO;
+class TDEProcIO;
class KWinbindGreeter : public TQObject, public KGreeterPlugin {
- Q_OBJECT
+ TQ_OBJECT
public:
KWinbindGreeter( KGreeterPluginHandler *handler,
@@ -89,10 +89,10 @@ class KWinbindGreeter : public TQObject, public KGreeterPlugin {
KComboBox *domainCombo;
KLineEdit *loginEdit;
KPasswordEdit *passwdEdit, *passwd1Edit, *passwd2Edit;
- KSimpleConfig *stsFile;
+ TDESimpleConfig *stsFile;
TQString fixedDomain, fixedUser, curUser;
TQStringList allUsers, mDomainListing;
- KProcIO* m_domainLister;
+ TDEProcIO* m_domainLister;
TQTimer mDomainListTimer;
Function func;
diff --git a/tdmlib/kgreeterplugin.h b/tdmlib/kgreeterplugin.h
index 1dcd0233b..946f48ed7 100644
--- a/tdmlib/kgreeterplugin.h
+++ b/tdmlib/kgreeterplugin.h
@@ -26,7 +26,7 @@
#include <tqvariant.h>
#include <tqmessagebox.h>
-#include <kdemacros.h>
+#include <tdemacros.h>
class KdmThemer;
@@ -312,7 +312,7 @@ protected:
TQLayoutItem *layoutItem;
};
-struct KDE_EXPORT kgreeterplugin_info {
+struct TDE_EXPORT kgreeterplugin_info {
/**
* Human readable name of this plugin (should be a little more
* informative than just the libary name). Must be I18N_NOOP()ed.