summaryrefslogtreecommitdiffstats
path: root/redhat/tdebase/tdebase-3.5.13.2-kdm_utf8_password.patch
diff options
context:
space:
mode:
Diffstat (limited to 'redhat/tdebase/tdebase-3.5.13.2-kdm_utf8_password.patch')
-rw-r--r--redhat/tdebase/tdebase-3.5.13.2-kdm_utf8_password.patch297
1 files changed, 297 insertions, 0 deletions
diff --git a/redhat/tdebase/tdebase-3.5.13.2-kdm_utf8_password.patch b/redhat/tdebase/tdebase-3.5.13.2-kdm_utf8_password.patch
new file mode 100644
index 000000000..9ba4bdd05
--- /dev/null
+++ b/redhat/tdebase/tdebase-3.5.13.2-kdm_utf8_password.patch
@@ -0,0 +1,297 @@
+--- ./kdmlib/kgreet_classic.cpp.ORI 2013-05-09 17:43:03.148552793 +0200
++++ ./kdmlib/kgreet_classic.cpp 2013-05-09 17:51:09.129324589 +0200
+@@ -26,21 +26,30 @@
+ #include "themer/kdmthemer.h"
+ #include "themer/kdmitem.h"
+
++#include <kglobal.h>
+ #include <klocale.h>
+ #include <klineedit.h>
+-#include <kpassdlg.h>
+ #include <kuser.h>
+
+ #include <tqregexp.h>
+ #include <tqlayout.h>
+ #include <tqlabel.h>
+
+-class KDMPasswordEdit : public KPasswordEdit {
++class KDMPasswordEdit : public KLineEdit {
+ public:
+- KDMPasswordEdit( TQWidget *parent ) : KPasswordEdit( parent, 0 ) {}
+- KDMPasswordEdit( KPasswordEdit::EchoModes echoMode, TQWidget *parent ) : KPasswordEdit( echoMode, parent, 0 ) {}
++ KDMPasswordEdit( TQWidget *parent ) : KLineEdit( parent )
++ {
++ setEchoMode(TQLineEdit::Password);
++ }
++
++ KDMPasswordEdit( TQLineEdit::EchoMode echoMode, TQWidget *parent ) : KLineEdit( parent )
++ {
++ setEchoMode(echoMode);
++ }
++
++
+ protected:
+- virtual void contextMenuEvent( TQContextMenuEvent * ) {}
++ virtual void contextMenuEvent( TQContextMenuEvent * ) {}
+ };
+
+ static int echoMode;
+@@ -104,11 +113,11 @@
+ grid->addWidget( loginLabel, line, 0 );
+ grid->addWidget( new TQLabel( fixedUser, parent ), line++, 1 );
+ }
+- if (echoMode == -1)
++ if (echoMode == -1) {
+ passwdEdit = new KDMPasswordEdit( parent );
+- else
+- passwdEdit = new KDMPasswordEdit( (KPasswordEdit::EchoModes)echoMode,
+- parent );
++ } else {
++ passwdEdit = new KDMPasswordEdit( (TQLineEdit::EchoMode)echoMode, parent );
++ }
+ connect( passwdEdit, TQT_SIGNAL(textChanged( const TQString & )),
+ TQT_SLOT(slotActivity()) );
+ connect( passwdEdit, TQT_SIGNAL(lostFocus()), TQT_SLOT(slotActivity()) );
+@@ -135,8 +144,8 @@
+ }
+ if (func != Authenticate) {
+ if (echoMode == -1) {
+- passwd1Edit = new KDMPasswordEdit( (KPasswordEdit::EchoModes)echoMode, parent );
+- passwd2Edit = new KDMPasswordEdit( (KPasswordEdit::EchoModes)echoMode, parent );
++ passwd1Edit = new KDMPasswordEdit( (TQLineEdit::EchoMode)echoMode, parent );
++ passwd2Edit = new KDMPasswordEdit( (TQLineEdit::EchoMode)echoMode, parent );
+ } else {
+ passwd1Edit = new KDMPasswordEdit( parent );
+ passwd2Edit = new KDMPasswordEdit( parent );
+@@ -247,16 +256,16 @@
+ KGreeterPluginHandler::IsUser );
+ break;
+ case 1:
+- handler->gplugReturnText( passwdEdit->password(),
++ handler->gplugReturnText( passwdEdit->text().utf8(),
+ KGreeterPluginHandler::IsPassword |
+ KGreeterPluginHandler::IsSecret );
+ break;
+ case 2:
+- handler->gplugReturnText( passwd1Edit->password(),
++ handler->gplugReturnText( passwd1Edit->text().utf8(),
+ KGreeterPluginHandler::IsSecret );
+ break;
+ default: // case 3:
+- handler->gplugReturnText( passwd2Edit->password(),
++ handler->gplugReturnText( passwd2Edit->text().utf8(),
+ KGreeterPluginHandler::IsNewPassword |
+ KGreeterPluginHandler::IsSecret );
+ break;
+@@ -405,11 +414,11 @@
+ // assert( !running );
+ setActive2( true );
+ if (authTok) {
+- passwd1Edit->erase();
+- passwd2Edit->erase();
++ passwd1Edit->clear();
++ passwd2Edit->clear();
+ passwd1Edit->setFocus();
+ } else {
+- passwdEdit->erase();
++ passwdEdit->clear();
+ if (loginEdit && loginEdit->isEnabled())
+ passwdEdit->setEnabled( true );
+ else {
+@@ -426,7 +435,7 @@
+ KClassicGreeter::clear()
+ {
+ // assert( !running && !passwd1Edit );
+- passwdEdit->erase();
++ passwdEdit->clear();
+ if (loginEdit) {
+ loginEdit->clear();
+ loginEdit->setFocus();
+@@ -484,9 +493,24 @@
+ TQVariant (*getConf)( void *, const char *, const TQVariant & ),
+ void *ctx )
+ {
+- echoMode = getConf( ctx, "EchoMode", TQVariant( -1 ) ).toInt();
+- KGlobal::locale()->insertCatalogue( "kgreet_classic" );
+- return true;
++ echoMode = getConf( ctx, "EchoMode", TQVariant( -1 ) ).toInt();
++ switch (echoMode)
++ {
++ case (0):
++ case (1):
++ echoMode = TQLineEdit::Password;
++ break;
++
++ case (2):
++ echoMode = TQLineEdit::NoEcho;
++ break;
++
++ default:
++ echoMode = TQLineEdit::Password;
++ }
++
++ KGlobal::locale()->insertCatalogue( "kgreet_classic" );
++ return true;
+ }
+
+ static void done( void )
+--- ./kdmlib/kgreet_classic.h.ORI 2013-05-09 17:53:03.266961035 +0200
++++ ./kdmlib/kgreet_classic.h 2013-05-09 17:53:49.235008948 +0200
+@@ -31,7 +31,6 @@
+ #include <tqobject.h>
+
+ class KLineEdit;
+-class KPasswordEdit;
+ class KSimpleConfig;
+ class TQGridLayout;
+ class TQLabel;
+@@ -76,7 +75,7 @@
+
+ TQLabel *loginLabel, *passwdLabel, *passwd1Label, *passwd2Label;
+ KLineEdit *loginEdit;
+- KPasswordEdit *passwdEdit, *passwd1Edit, *passwd2Edit;
++ KLineEdit *passwdEdit, *passwd1Edit, *passwd2Edit;
+ KSimpleConfig *stsFile;
+ TQString fixedUser, curUser;
+ Function func;
+--- ./kdmlib/kgreet_winbind.cpp.ORI 2013-05-09 17:54:36.906021481 +0200
++++ ./kdmlib/kgreet_winbind.cpp 2013-05-09 18:00:23.089847329 +0200
+@@ -26,11 +26,11 @@
+ #include "themer/kdmthemer.h"
+ #include "themer/kdmitem.h"
+
++#include <kglobal.h>
+ #include <klocale.h>
+ #include <kdebug.h>
+ #include <kcombobox.h>
+ #include <klineedit.h>
+-#include <kpassdlg.h>
+ #include <kuser.h>
+ #include <kprocio.h>
+
+@@ -40,10 +40,17 @@
+
+ #include <stdlib.h>
+
+-class KDMPasswordEdit : public KPasswordEdit {
++class KDMPasswordEdit : public KLineEdit {
+ public:
+- KDMPasswordEdit( TQWidget *parent ) : KPasswordEdit( parent, 0 ) {}
+- KDMPasswordEdit( KPasswordEdit::EchoModes echoMode, TQWidget *parent ) : KPasswordEdit( echoMode, parent, 0 ) {}
++ KDMPasswordEdit( TQWidget *parent ) : KLineEdit( parent )
++ {
++ setEchoMode(TQLineEdit::Password);
++ }
++ KDMPasswordEdit( TQLineEdit::EchoMode echoMode, TQWidget *parent ) : KLineEdit( parent )
++ {
++ setEchoMode(echoMode);
++ }
++
+ protected:
+ virtual void contextMenuEvent( TQContextMenuEvent * ) {}
+ };
+@@ -150,7 +157,7 @@
+ if (echoMode == -1)
+ passwdEdit = new KDMPasswordEdit( parent );
+ else
+- passwdEdit = new KDMPasswordEdit( (KPasswordEdit::EchoModes)echoMode,
++ passwdEdit = new KDMPasswordEdit( (TQLineEdit::EchoMode)echoMode,
+ parent );
+ connect( passwdEdit, TQT_SIGNAL(textChanged( const TQString & )),
+ TQT_SLOT(slotActivity()) );
+@@ -180,8 +187,8 @@
+ }
+ if (func != Authenticate) {
+ if (echoMode == -1) {
+- passwd1Edit = new KDMPasswordEdit( (KPasswordEdit::EchoModes)echoMode, parent );
+- passwd2Edit = new KDMPasswordEdit( (KPasswordEdit::EchoModes)echoMode, parent );
++ passwd1Edit = new KDMPasswordEdit( (TQLineEdit::EchoMode)echoMode, parent );
++ passwd2Edit = new KDMPasswordEdit( (TQLineEdit::EchoMode)echoMode, parent );
+ } else {
+ passwd1Edit = new KDMPasswordEdit( parent );
+ passwd2Edit = new KDMPasswordEdit( parent );
+@@ -328,16 +335,16 @@
+ KGreeterPluginHandler::IsUser );
+ break;
+ case 1:
+- handler->gplugReturnText( passwdEdit->password(),
++ handler->gplugReturnText( passwdEdit->text().utf8(),
+ KGreeterPluginHandler::IsPassword |
+ KGreeterPluginHandler::IsSecret );
+ break;
+ case 2:
+- handler->gplugReturnText( passwd1Edit->password(),
++ handler->gplugReturnText( passwd1Edit->text().utf8(),
+ KGreeterPluginHandler::IsSecret );
+ break;
+ default: // case 3:
+- handler->gplugReturnText( passwd2Edit->password(),
++ handler->gplugReturnText( passwd2Edit->text().utf8(),
+ KGreeterPluginHandler::IsNewPassword |
+ KGreeterPluginHandler::IsSecret );
+ break;
+@@ -486,11 +493,11 @@
+ // assert( !running );
+ setActive2( true );
+ if (authTok) {
+- passwd1Edit->erase();
+- passwd2Edit->erase();
++ passwd1Edit->clear();
++ passwd2Edit->clear();
+ passwd1Edit->setFocus();
+ } else {
+- passwdEdit->erase();
++ passwdEdit->clear();
+ if (loginEdit && loginEdit->isEnabled())
+ passwdEdit->setEnabled( true );
+ else {
+@@ -507,7 +514,7 @@
+ KWinbindGreeter::clear()
+ {
+ // assert( !running && !passwd1Edit );
+- passwdEdit->erase();
++ passwdEdit->clear();
+ if (loginEdit) {
+ domainCombo->setCurrentItem( defaultDomain );
+ slotChangedDomain( defaultDomain );
+@@ -632,6 +639,21 @@
+ void *ctx )
+ {
+ echoMode = getConf( ctx, "EchoMode", TQVariant( -1 ) ).toInt();
++ switch (echoMode)
++ {
++ case (0):
++ case (1):
++ echoMode = TQLineEdit::Password;
++ break;
++
++ case (2):
++ echoMode = TQLineEdit::NoEcho;
++ break;
++
++ default:
++ echoMode = TQLineEdit::Password;
++ }
++
+ staticDomains = TQStringList::split( ':', getConf( ctx, "winbind.Domains", TQVariant( "" ) ).toString() );
+ if (!staticDomains.contains("<local>"))
+ staticDomains << "<local>";
+--- ./kdmlib/kgreet_winbind.h.ORI 2013-05-09 18:00:46.495362083 +0200
++++ ./kdmlib/kgreet_winbind.h 2013-05-09 18:01:22.960606033 +0200
+@@ -33,7 +33,6 @@
+
+ class KComboBox;
+ class KLineEdit;
+-class KPasswordEdit;
+ class KSimpleConfig;
+ class TQGridLayout;
+ class TQLabel;
+@@ -85,7 +84,7 @@
+ TQLabel *domainLabel, *loginLabel, *passwdLabel, *passwd1Label, *passwd2Label;
+ KComboBox *domainCombo;
+ KLineEdit *loginEdit;
+- KPasswordEdit *passwdEdit, *passwd1Edit, *passwd2Edit;
++ KLineEdit *passwdEdit, *passwd1Edit, *passwd2Edit;
+ KSimpleConfig *stsFile;
+ TQString fixedDomain, fixedUser, curUser;
+ TQStringList allUsers, mDomainListing;