00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
#include <qlayout.h>
00024
#include <config.h>
00025
#include <klocale.h>
00026
00027
#include "configuredialog.h"
00028
00029
using namespace KSync;
00030
00031
00032 ConfigureDialog::ConfigureDialog(
QWidget *parent,
const char *name,
bool modal )
00033 : KDialogBase( IconList, i18n(
"Configure KitchenSync" ), Ok | Cancel, Ok,
00034 parent, name, modal, true )
00035 {
00036 setIconListAllVisible(
false );
00037 resize( 500, 300 );
00038 }
00039
00040 ConfigureDialog::~ConfigureDialog()
00041 {
00042 }
00043
00044
void ConfigureDialog::show()
00045 {
00046
if ( !isVisible() )
00047 setup();
00048
00049 KDialogBase::show();
00050 }
00051
00052
void ConfigureDialog::slotOk()
00053 {
00054
apply(
true );
00055 accept();
00056 emit
ok();
00057 }
00058
00059
void ConfigureDialog::slotCancel()
00060 {
00061
apply(
false );
00062 reject();
00063 }
00064
00065 void ConfigureDialog::addWidget(
QWidget* widget,
const QString &name,
QPixmap* pixmap )
00066 {
00067
QFrame *frame = addPage( name, name, *pixmap );
00068
QHBoxLayout *lay =
new QHBoxLayout( frame );
00069 widget->reparent( frame,
QPoint( 0, 0 ) );
00070 lay->addWidget( widget );
00071 }
00072
00073
void ConfigureDialog::setup()
00074 {
00075 }
00076
00077
void ConfigureDialog::unload()
00078 {
00079 }
00080
00081 void ConfigureDialog::apply(
bool )
00082 {
00083 }
00084
00085
#include "configuredialog.moc"