diff --git a/kdecore/config/kcoreconfigskeleton.cpp b/kdecore/config/kcoreconfigskeleton.cpp
index ebdbfb3c..f63759c6 100644
--- a/kdecore/config/kcoreconfigskeleton.cpp
+++ b/kdecore/config/kcoreconfigskeleton.cpp
@@ -25,7 +25,6 @@
#include "kstandarddirs.h"
#include "kglobal.h"
#include "kdebug.h"
-#include "kstringhandler.h"
KConfigSkeletonItem::KConfigSkeletonItem(const QString & _group,
const QString & _key)
@@ -139,8 +138,6 @@ void KCoreConfigSkeleton::ItemString::writeConfig( KConfig *config )
cg.revertToDefault( mKey );
else if ( mType == Path )
cg.writePathEntry( mKey, mReference );
- else if ( mType == Password )
- cg.writeEntry( mKey, KStringHandler::obscure( mReference ) );
else
cg.writeEntry( mKey, mReference );
}
@@ -155,11 +152,6 @@ void KCoreConfigSkeleton::ItemString::readConfig( KConfig *config )
{
mReference = cg.readPathEntry( mKey, mDefault );
}
- else if ( mType == Password )
- {
- QString val = cg.readEntry( mKey, KStringHandler::obscure( mDefault ) );
- mReference = KStringHandler::obscure( val );
- }
else
{
mReference = cg.readEntry( mKey, mDefault );
@@ -185,13 +177,6 @@ QVariant KCoreConfigSkeleton::ItemString::property() const
return QVariant(mReference);
}
-KCoreConfigSkeleton::ItemPassword::ItemPassword( const QString &_group, const QString &_key,
- QString &reference,
- const QString &defaultValue)
- : ItemString( _group, _key, reference, defaultValue, Password )
-{
-}
-
KCoreConfigSkeleton::ItemPath::ItemPath( const QString &_group, const QString &_key,
QString &reference,
const QString &defaultValue)
@@ -1104,16 +1089,6 @@ KCoreConfigSkeleton::ItemString *KCoreConfigSkeleton::addItemString( const QStri
return item;
}
-KCoreConfigSkeleton::ItemPassword *KCoreConfigSkeleton::addItemPassword( const QString &name, QString &reference,
- const QString &defaultValue, const QString &key )
-{
- KCoreConfigSkeleton::ItemPassword *item;
- item = new KCoreConfigSkeleton::ItemPassword( d->mCurrentGroup, key.isNull() ? name : key,
- reference, defaultValue );
- addItem( item, name );
- return item;
-}
-
KCoreConfigSkeleton::ItemPath *KCoreConfigSkeleton::addItemPath( const QString &name, QString &reference,
const QString &defaultValue, const QString &key )
{
diff --git a/kdecore/config/kcoreconfigskeleton.h b/kdecore/config/kcoreconfigskeleton.h
index aa6cc4cf..e0ed4a0e 100644
--- a/kdecore/config/kcoreconfigskeleton.h
+++ b/kdecore/config/kcoreconfigskeleton.h
@@ -368,7 +368,7 @@ public:
class KDECORE_EXPORT ItemString:public KConfigSkeletonGenericItem < QString >
{
public:
- enum Type { Normal, Password, Path };
+ enum Type { Normal, Path };
/** @enum Type
The type of string that is held in this item
@@ -376,9 +376,6 @@ public:
@var ItemString::Type ItemString::Normal
A normal string
- @var ItemString::Type ItemString::Password
- A password string
-
@var ItemString::Type ItemString::Path
A path to a file or directory
*/
@@ -411,18 +408,6 @@ public:
Type mType;
};
- /**
- * Class for handling a password preferences item.
- */
- class KDECORE_EXPORT ItemPassword:public ItemString
- {
- public:
- /** @copydoc KConfigSkeletonGenericItem::KConfigSkeletonGenericItem */
- ItemPassword(const QString & _group, const QString & _key,
- QString & reference,
- const QString & defaultValue = QLatin1String("")); // NOT QString() !!
- };
-
/**
* Class for handling a path preferences item.
*/
@@ -1035,23 +1020,6 @@ public:
const QString & defaultValue = QLatin1String(""), // NOT QString() !!
const QString & key = QString());
- /**
- * Register a password item of type QString. The string value is written
- * encrypted to the config file. Note that the current encryption scheme
- * is very weak.
- *
- * @param name Name used to identify this setting. Names must be unique.
- * @param reference Pointer to the variable, which is set by readConfig()
- * calls and read by writeConfig() calls.
- * @param defaultValue Default value, which is used when the config file
- * does not yet contain the key of this item.
- * @param key Key used in config file. If key is null, name is used as key.
- * @return The created item
- */
- ItemPassword *addItemPassword(const QString & name, QString & reference,
- const QString & defaultValue = QLatin1String(""),
- const QString & key = QString());
-
/**
* Register a path item of type QString. The string value is interpreted
* as a path. This means, dollar expension is activated for this value, so
diff --git a/kdecore/kconfig_compiler/kcfg.xsd b/kdecore/kconfig_compiler/kcfg.xsd
index f50520e6..dfce6810 100644
--- a/kdecore/kconfig_compiler/kcfg.xsd
+++ b/kdecore/kconfig_compiler/kcfg.xsd
@@ -178,7 +178,6 @@
-
diff --git a/kdecore/kconfig_compiler/kconfig_compiler.cpp b/kdecore/kconfig_compiler/kconfig_compiler.cpp
index 4814e952..47498dfb 100644
--- a/kdecore/kconfig_compiler/kconfig_compiler.cpp
+++ b/kdecore/kconfig_compiler/kconfig_compiler.cpp
@@ -899,12 +899,12 @@ QString param( const QString &t )
else if ( type == "enum" ) return "int";
else if ( type == "path" ) return "const QString &";
else if ( type == "pathlist" ) return "const QStringList &";
- else if ( type == "password" ) return "const QString &";
else if ( type == "url" ) return "const KUrl &";
else if ( type == "urllist" ) return "const KUrl::List &";
else {
cerr <<"kconfig_compiler does not support type \""<< type <<"\""<
a string
-
+
diff --git a/kdeui/tests/kconfig_compiler/test3a.cpp.ref b/kdeui/tests/kconfig_compiler/test3a.cpp.ref
index 34321e9e..7e19637c 100644
--- a/kdeui/tests/kconfig_compiler/test3a.cpp.ref
+++ b/kdeui/tests/kconfig_compiler/test3a.cpp.ref
@@ -19,8 +19,8 @@ Test3a::Test3a( )
addItem( mBlubbItem, QLatin1String( "Blubb" ) );
mBlahBlahItem = new KConfigSkeleton::ItemString( currentGroup(), QLatin1String( "BlahBlah" ), mBlahBlah, QLatin1String( "a string" ) );
addItem( mBlahBlahItem, QLatin1String( "BlahBlah" ) );
- mMyPasswordItem = new KConfigSkeleton::ItemPassword( currentGroup(), QLatin1String( "MyPassword" ), mMyPassword );
- addItem( mMyPasswordItem, QLatin1String( "MyPassword" ) );
+ mMyPathItem = new KConfigSkeleton::ItemPath( currentGroup(), QLatin1String( "MyPath" ), mMyPath );
+ addItem( mMyPathItem, QLatin1String( "MyPath" ) );
}
Test3a::~Test3a()
diff --git a/kdeui/tests/kconfig_compiler/test3a.h.ref b/kdeui/tests/kconfig_compiler/test3a.h.ref
index b3049d11..d2779204 100644
--- a/kdeui/tests/kconfig_compiler/test3a.h.ref
+++ b/kdeui/tests/kconfig_compiler/test3a.h.ref
@@ -93,28 +93,28 @@ class Test3a : public KConfigSkeleton
}
/**
- Set MyPassword
+ Set MyPath
*/
- void setMyPassword( const QString & v )
+ void setMyPath( const QString & v )
{
- if (!isImmutable( QString::fromLatin1( "MyPassword" ) ))
- mMyPassword = v;
+ if (!isImmutable( QString::fromLatin1( "MyPath" ) ))
+ mMyPath = v;
}
/**
- Get MyPassword
+ Get MyPath
*/
- QString myPassword() const
+ QString myPath() const
{
- return mMyPassword;
+ return mMyPath;
}
/**
- Get Item object corresponding to MyPassword()
+ Get Item object corresponding to MyPath()
*/
- ItemPassword *myPasswordItem()
+ ItemPath *myPathItem()
{
- return mMyPasswordItem;
+ return mMyPathItem;
}
protected:
@@ -125,13 +125,13 @@ class Test3a : public KConfigSkeleton
// Blah
int mBlubb;
QString mBlahBlah;
- QString mMyPassword;
+ QString mMyPath;
private:
ItemBool *mAutoSaveItem;
ItemInt *mBlubbItem;
ItemString *mBlahBlahItem;
- ItemPassword *mMyPasswordItem;
+ ItemPath *mMyPathItem;
};
}
diff --git a/kdeui/tests/kconfig_compiler/test3a.kcfg b/kdeui/tests/kconfig_compiler/test3a.kcfg
index d49b4d65..bc78b29d 100644
--- a/kdeui/tests/kconfig_compiler/test3a.kcfg
+++ b/kdeui/tests/kconfig_compiler/test3a.kcfg
@@ -20,7 +20,7 @@
a string
-
+
diff --git a/plasma/configloader.cpp b/plasma/configloader.cpp
index a491bf0d..13b0b1ce 100644
--- a/plasma/configloader.cpp
+++ b/plasma/configloader.cpp
@@ -235,8 +235,6 @@ void ConfigLoaderHandler::addItem()
}
item = intItem;
- } else if (m_type == "password") {
- item = m_config->addItemPassword(m_name, *d->newString(), m_default, m_key);
} else if (m_type == "path") {
item = m_config->addItemPath(m_name, *d->newString(), m_default, m_key);
} else if (m_type == "string") {
diff --git a/plasma/tests/configloadertest.cpp b/plasma/tests/configloadertest.cpp
index bd5224a6..c0cde654 100644
--- a/plasma/tests/configloadertest.cpp
+++ b/plasma/tests/configloadertest.cpp
@@ -101,13 +101,6 @@ void ConfigLoaderTest::intDefaultValue()
QVERIFY(typeItem->isEqual(27));
}
-void ConfigLoaderTest::passwordDefaultValue()
-{
- GET_CONFIG_ITEM_VALUE(KConfigSkeleton::ItemPassword*, "DefaultPasswordItem");
-
- QVERIFY(typeItem->isEqual(QString::fromLatin1("h4x.")));
-}
-
void ConfigLoaderTest::pathDefaultValue()
{
GET_CONFIG_ITEM_VALUE(KConfigSkeleton::ItemPath*, "DefaultPathItem");
diff --git a/plasma/tests/configloadertest.h b/plasma/tests/configloadertest.h
index 20a67f04..a96fa0ee 100644
--- a/plasma/tests/configloadertest.h
+++ b/plasma/tests/configloadertest.h
@@ -45,7 +45,6 @@ private Q_SLOTS:
void enumDefaultValue();
void fontDefaultValue();
void intDefaultValue();
- void passwordDefaultValue();
void pathDefaultValue();
void stringDefaultValue();
void stringListDefaultValue();
diff --git a/plasma/tests/configloadertest.xml b/plasma/tests/configloadertest.xml
index cfe14ac9..cf7bd10d 100644
--- a/plasma/tests/configloadertest.xml
+++ b/plasma/tests/configloadertest.xml
@@ -31,9 +31,6 @@
27
-
- h4x.
-
/dev/null