-rw-r--r-- | libkdepim/kprefsdialog.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libkdepim/kprefsdialog.cpp b/libkdepim/kprefsdialog.cpp index dd9a602..b6ae775 100644 --- a/libkdepim/kprefsdialog.cpp +++ b/libkdepim/kprefsdialog.cpp @@ -219,129 +219,129 @@ KPrefsDialogWidRadios::~KPrefsDialogWidRadios() void KPrefsDialogWidRadios::addRadio(const QString &text) { new QRadioButton(text,mBox); } QButtonGroup *KPrefsDialogWidRadios::groupBox() { return mBox; } void KPrefsDialogWidRadios::readConfig() { mBox->setButton(*mReference); } void KPrefsDialogWidRadios::writeConfig() { *mReference = mBox->id(mBox->selected()); } KPrefsDialogWidString::KPrefsDialogWidString(const QString &text,QString *reference, QWidget *parent, QLineEdit::EchoMode echomode) { mReference = reference; mLabel = new QLabel(text,parent); mEdit = new QLineEdit(parent); mEdit->setEchoMode( echomode ); } KPrefsDialogWidString::~KPrefsDialogWidString() { } void KPrefsDialogWidString::readConfig() { mEdit->setText(*mReference); } void KPrefsDialogWidString::writeConfig() { *mReference = mEdit->text(); } QLabel *KPrefsDialogWidString::label() { return mLabel; } QLineEdit *KPrefsDialogWidString::lineEdit() { return mEdit; } KPrefsDialog::KPrefsDialog(KPrefs *prefs,QWidget *parent,char *name,bool modal) : KDialogBase(IconList,i18n("Preferences"),Ok|Cancel|Default,Ok,parent, name,modal,true) { mPrefs = prefs; // This seems to cause a crash on exit. Investigate later. -// mPrefsWids.setAutoDelete(true); + mPrefsWids.setAutoDelete(true); connect(this,SIGNAL(defaultClicked()),SLOT(slotDefault())); //connect(this,SIGNAL(cancelClicked()),SLOT(slotDefault())); //connect(this,SIGNAL(cancelClicked()),SLOT(reject())); } KPrefsDialog::~KPrefsDialog() { } void KPrefsDialog::addWid(KPrefsDialogWid *wid) { mPrefsWids.append(wid); } KPrefsDialogWidBool *KPrefsDialog::addWidBool(const QString &text,bool *reference,QWidget *parent) { KPrefsDialogWidBool *w = new KPrefsDialogWidBool(text,reference,parent); addWid(w); return w; } KPrefsDialogWidTime *KPrefsDialog::addWidTime(const QString &text,int *reference,QWidget *parent) { KPrefsDialogWidTime *w = new KPrefsDialogWidTime(text,reference,parent); addWid(w); return w; } KPrefsDialogWidColor *KPrefsDialog::addWidColor(const QString &text,QColor *reference,QWidget *parent) { KPrefsDialogWidColor *w = new KPrefsDialogWidColor(text,reference,parent); addWid(w); return w; } KPrefsDialogWidRadios *KPrefsDialog::addWidRadios(const QString &text,int *reference,QWidget *parent) { KPrefsDialogWidRadios *w = new KPrefsDialogWidRadios(text,reference,parent); addWid(w); return w; } KPrefsDialogWidString *KPrefsDialog::addWidString(const QString &text,QString *reference,QWidget *parent) { KPrefsDialogWidString *w = new KPrefsDialogWidString(text,reference,parent); addWid(w); return w; } KPrefsDialogWidString *KPrefsDialog::addWidPassword(const QString &text,QString *reference,QWidget *parent) { KPrefsDialogWidString *w = new KPrefsDialogWidString(text,reference,parent,QLineEdit::Password); addWid(w); return w; } KPrefsDialogWidFont *KPrefsDialog::addWidFont(const QString &sampleText,const QString &buttonText, QFont *reference,QWidget *parent) { KPrefsDialogWidFont *w = new KPrefsDialogWidFont(sampleText,buttonText,reference,parent); addWid(w); return w; } |