add more spacing
[personal-kdebase.git] / runtime / kwalletd / kbetterthankdialog.cpp
blob10993e8d69a21145fcb1568ce073d7fc2de057c6
1 /* This file is part of the KDE libraries
2 Copyright (C) 2004 George Staikos <staikos@kde.org>
4 This program is free software; you can redistribute it and/or modify
5 it under the terms of the GNU General Public License as published by
6 the Free Software Foundation; either version 2 of the License, or
7 (at your option) any later version.
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU General Public License for more details.
14 You should have received a copy of the GNU General Public License
15 along with this program; if not, write to the Free Software
16 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19 #include "kbetterthankdialog.h"
21 KBetterThanKDialog::KBetterThanKDialog( QWidget *parent )
22 : QDialog( parent )
24 setupUi( this );
25 connect(_allowOnce, SIGNAL(clicked()), this, SLOT(allowOnceClicked()));
26 connect(_allowAlways, SIGNAL(clicked()), this, SLOT(allowAlwaysClicked()));
27 connect(_deny, SIGNAL(clicked()), this, SLOT(denyClicked()));
28 connect(_denyForever, SIGNAL(clicked()), this, SLOT(denyForeverClicked()));
31 void KBetterThanKDialog::init()
33 _allowOnce->setFocus();
36 void KBetterThanKDialog::setLabel( const QString & label )
38 _label->setText(label);
41 void KBetterThanKDialog::accept()
43 setResult(0);
46 void KBetterThanKDialog::reject()
48 QDialog::reject();
49 setResult(2);
52 void KBetterThanKDialog::allowOnceClicked()
54 done(0);
57 void KBetterThanKDialog::allowAlwaysClicked()
59 done(1);
62 void KBetterThanKDialog::denyClicked()
64 done(2);
67 void KBetterThanKDialog::denyForeverClicked()
69 done(3);
72 #include "kbetterthankdialog.moc"