summaryrefslogtreecommitdiffabout
path: root/kaddressbook
Unidiff
Diffstat (limited to 'kaddressbook') (more/less context) (ignore whitespace changes)
-rw-r--r--kaddressbook/kabcore.cpp1
-rw-r--r--kaddressbook/kcmconfigs/addresseewidget.cpp14
-rw-r--r--kaddressbook/kcmconfigs/kabconfigwidget.cpp14
-rw-r--r--kaddressbook/kcmconfigs/kcmkabconfig.cpp6
4 files changed, 26 insertions, 9 deletions
diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp
index 7bf1a2f..a6d722d 100644
--- a/kaddressbook/kabcore.cpp
+++ b/kaddressbook/kabcore.cpp
@@ -987,48 +987,49 @@ QString KABCore::getNameByPhone( const QString &phone )
987 ownerName = (*iter).formattedName(); 987 ownerName = (*iter).formattedName();
988 found = true; 988 found = true;
989 } 989 }
990 } 990 }
991 } 991 }
992 992
993 return ownerName; 993 return ownerName;
994#else //KAB_EMBEDDED 994#else //KAB_EMBEDDED
995 qDebug("KABCore::getNameByPhone finsih method"); 995 qDebug("KABCore::getNameByPhone finsih method");
996 return ""; 996 return "";
997#endif //KAB_EMBEDDED 997#endif //KAB_EMBEDDED
998 998
999} 999}
1000 1000
1001void KABCore::openConfigDialog() 1001void KABCore::openConfigDialog()
1002{ 1002{
1003 KCMultiDialog* ConfigureDialog = new KCMultiDialog( "PIM", this ,"kabconfigdialog", true ); 1003 KCMultiDialog* ConfigureDialog = new KCMultiDialog( "PIM", this ,"kabconfigdialog", true );
1004 KCMKabConfig* kabcfg = new KCMKabConfig( ConfigureDialog->getNewVBoxPage(i18n( "Addressbook")) , "KCMKabConfig" ); 1004 KCMKabConfig* kabcfg = new KCMKabConfig( ConfigureDialog->getNewVBoxPage(i18n( "Addressbook")) , "KCMKabConfig" );
1005 ConfigureDialog->addModule(kabcfg ); 1005 ConfigureDialog->addModule(kabcfg );
1006 connect( ConfigureDialog, SIGNAL( applyClicked() ), 1006 connect( ConfigureDialog, SIGNAL( applyClicked() ),
1007 this, SLOT( configurationChanged() ) ); 1007 this, SLOT( configurationChanged() ) );
1008 connect( ConfigureDialog, SIGNAL( okClicked() ), 1008 connect( ConfigureDialog, SIGNAL( okClicked() ),
1009 this, SLOT( configurationChanged() ) ); 1009 this, SLOT( configurationChanged() ) );
1010 saveSettings(); 1010 saveSettings();
1011 ConfigureDialog->showMaximized();
1011 ConfigureDialog->exec(); 1012 ConfigureDialog->exec();
1012 delete ConfigureDialog; 1013 delete ConfigureDialog;
1013} 1014}
1014 1015
1015void KABCore::openLDAPDialog() 1016void KABCore::openLDAPDialog()
1016{ 1017{
1017#ifndef KAB_EMBEDDED 1018#ifndef KAB_EMBEDDED
1018 if ( !mLdapSearchDialog ) { 1019 if ( !mLdapSearchDialog ) {
1019 mLdapSearchDialog = new LDAPSearchDialog( mAddressBook, this ); 1020 mLdapSearchDialog = new LDAPSearchDialog( mAddressBook, this );
1020 connect( mLdapSearchDialog, SIGNAL( addresseesAdded() ), mViewManager, 1021 connect( mLdapSearchDialog, SIGNAL( addresseesAdded() ), mViewManager,
1021 SLOT( refreshView() ) ); 1022 SLOT( refreshView() ) );
1022 connect( mLdapSearchDialog, SIGNAL( addresseesAdded() ), this, 1023 connect( mLdapSearchDialog, SIGNAL( addresseesAdded() ), this,
1023 SLOT( setModified() ) ); 1024 SLOT( setModified() ) );
1024 } else 1025 } else
1025 mLdapSearchDialog->restoreSettings(); 1026 mLdapSearchDialog->restoreSettings();
1026 1027
1027 if ( mLdapSearchDialog->isOK() ) 1028 if ( mLdapSearchDialog->isOK() )
1028 mLdapSearchDialog->exec(); 1029 mLdapSearchDialog->exec();
1029#else //KAB_EMBEDDED 1030#else //KAB_EMBEDDED
1030 qDebug("KABCore::openLDAPDialog() finsih method"); 1031 qDebug("KABCore::openLDAPDialog() finsih method");
1031#endif //KAB_EMBEDDED 1032#endif //KAB_EMBEDDED
1032} 1033}
1033 1034
1034void KABCore::print() 1035void KABCore::print()
diff --git a/kaddressbook/kcmconfigs/addresseewidget.cpp b/kaddressbook/kcmconfigs/addresseewidget.cpp
index 0f3c353..f84b2ba 100644
--- a/kaddressbook/kcmconfigs/addresseewidget.cpp
+++ b/kaddressbook/kcmconfigs/addresseewidget.cpp
@@ -37,49 +37,49 @@
37#include <kstandarddirs.h> 37#include <kstandarddirs.h>
38 38
39#include "addresseewidget.h" 39#include "addresseewidget.h"
40 40
41NamePartWidget::NamePartWidget( const QString &title, QWidget *parent, 41NamePartWidget::NamePartWidget( const QString &title, QWidget *parent,
42 const char *name ) 42 const char *name )
43 : QWidget( parent, name ) 43 : QWidget( parent, name )
44{ 44{
45 if (KGlobal::getOrientation() == KGlobal::Portrait) 45 if (KGlobal::getOrientation() == KGlobal::Portrait)
46 { 46 {
47 QGridLayout* layout = new QGridLayout( this, 1, 1, KDialog::marginHintSmall(), 47 QGridLayout* layout = new QGridLayout( this, 1, 1, KDialog::marginHintSmall(),
48 KDialog::spacingHintSmall() ); 48 KDialog::spacingHintSmall() );
49 49
50 QLabel *label = new QLabel( i18n( title ), this ); 50 QLabel *label = new QLabel( i18n( title ), this );
51 layout->addWidget( label, 0, 1 ); 51 layout->addWidget( label, 0, 1 );
52 52
53 mBox = new QListBox( this ); 53 mBox = new QListBox( this );
54 mBox->setMaximumSize(70, 70); 54 mBox->setMaximumSize(70, 70);
55 layout->addMultiCellWidget( mBox, 0, 1, 0, 0 ); 55 layout->addMultiCellWidget( mBox, 0, 1, 0, 0 );
56 56
57 KButtonBox *bbox = new KButtonBox( this, Qt::Vertical ); 57 KButtonBox *bbox = new KButtonBox( this, Qt::Vertical );
58 mAddButton = bbox->addButton( i18n( "Add" ), this, SLOT( add() ) ); 58 mAddButton = bbox->addButton( i18n( "Add" ), this, SLOT( add() ) );
59 mRemoveButton = bbox->addButton( i18n( "Rem" ), this, SLOT( remove() ) ); 59 mRemoveButton = bbox->addButton( i18n( "Rem" ), this, SLOT( remove() ) );
60 bbox->layout(); 60 bbox->layout();
61 layout->addMultiCellWidget( bbox, 0, 2, 2,2); 61 layout->addMultiCellWidget( bbox, 0, 1, 2,2);
62 62
63 mEdit = new KLineEdit( this ); 63 mEdit = new KLineEdit( this );
64 layout->addWidget( mEdit, 1, 1 ); 64 layout->addWidget( mEdit, 1, 1 );
65 //mEdit->setMinimumWidth(50); 65 //mEdit->setMinimumWidth(50);
66 66
67// layout->addWidget( group ); 67// layout->addWidget( group );
68 68
69 } 69 }
70 else 70 else
71 { 71 {
72 QHBoxLayout *layout = new QHBoxLayout( this ); 72 QHBoxLayout *layout = new QHBoxLayout( this );
73 73
74 QGroupBox *group = new QGroupBox( 0, Qt::Vertical, title, this ); 74 QGroupBox *group = new QGroupBox( 0, Qt::Vertical, title, this );
75 QGridLayout *groupLayout = new QGridLayout( group->layout(), 2, 2, 75 QGridLayout *groupLayout = new QGridLayout( group->layout(), 2, 2,
76 KDialog::spacingHint() ); 76 KDialog::spacingHint() );
77 77
78 mBox = new QListBox( group ); 78 mBox = new QListBox( group );
79 79
80 groupLayout->addWidget( mBox, 0, 0 ); 80 groupLayout->addWidget( mBox, 0, 0 );
81 81
82 KButtonBox *bbox = new KButtonBox( group, Qt::Vertical ); 82 KButtonBox *bbox = new KButtonBox( group, Qt::Vertical );
83 mAddButton = bbox->addButton( i18n( "Add" ), this, SLOT( add() ) ); 83 mAddButton = bbox->addButton( i18n( "Add" ), this, SLOT( add() ) );
84 mRemoveButton = bbox->addButton( i18n( "Remove" ), this, SLOT( remove() ) ); 84 mRemoveButton = bbox->addButton( i18n( "Remove" ), this, SLOT( remove() ) );
85 bbox->layout(); 85 bbox->layout();
@@ -140,60 +140,66 @@ void NamePartWidget::remove()
140 selectionChanged( 0 ); 140 selectionChanged( 0 );
141 141
142 emit modified(); 142 emit modified();
143} 143}
144 144
145void NamePartWidget::selectionChanged( QListBoxItem *item ) 145void NamePartWidget::selectionChanged( QListBoxItem *item )
146{ 146{
147 mRemoveButton->setEnabled( item != 0 ); 147 mRemoveButton->setEnabled( item != 0 );
148} 148}
149 149
150void NamePartWidget::textChanged( const QString& text ) 150void NamePartWidget::textChanged( const QString& text )
151{ 151{
152 mAddButton->setEnabled( !text.isEmpty() ); 152 mAddButton->setEnabled( !text.isEmpty() );
153} 153}
154 154
155 155
156AddresseeWidget::AddresseeWidget( QWidget *parent, const char *name ) 156AddresseeWidget::AddresseeWidget( QWidget *parent, const char *name )
157 : QWidget( parent, name ) 157 : QWidget( parent, name )
158{ 158{
159 QGridLayout *layout; 159 QGridLayout *layout;
160 160
161 mPrefix = new NamePartWidget( i18n( "Prefixes" ), this ); 161 mPrefix = new NamePartWidget( i18n( "Prefixes" ), this );
162 mInclusion = new NamePartWidget( i18n( "Inclusions" ), this ); 162 mInclusion = new NamePartWidget( i18n( "Inclusions" ), this );
163 mSuffix = new NamePartWidget( i18n( "Suffixes" ), this ); 163 mSuffix = new NamePartWidget( i18n( "Suffixes" ), this );
164 QLabel *label = new QLabel( i18n( "Default formatted name:" ), this ); 164 QString dfn;
165 if (QApplication::desktop()->width() > 320 )
166 dfn = i18n( "Default formatted name:" );
167 else
168 dfn = i18n( "Def. formatted name:" );
169
170 QLabel *label = new QLabel( dfn, this );
165 171
166 mFormattedNameCombo = new KComboBox( this ); 172 mFormattedNameCombo = new KComboBox( this );
167 mFormattedNameCombo->insertItem( i18n( "Empty" ) ); 173 mFormattedNameCombo->insertItem( i18n( "Empty" ) );
168 mFormattedNameCombo->insertItem( i18n( "Simple Name" ) ); 174 mFormattedNameCombo->insertItem( i18n( "Simple Name" ) );
169 mFormattedNameCombo->insertItem( i18n( "Full Name" ) ); 175 mFormattedNameCombo->insertItem( i18n( "Full Name" ) );
170 mFormattedNameCombo->insertItem( i18n( "Reverse Name" ) ); 176 mFormattedNameCombo->insertItem( i18n( "Reverse Name" ) );
171 177
172 if (KGlobal::getOrientation() == KGlobal::Portrait) 178 if (KGlobal::getOrientation() == KGlobal::Portrait)
173 { 179 {
174 layout = new QGridLayout( this, 4, 2, KDialog::marginHint(), 180 layout = new QGridLayout( this, 4, 2, KDialog::marginHintSmall(),
175 KDialog::spacingHint() ); 181 KDialog::spacingHintSmall() );
176 182
177 layout->addMultiCellWidget( mPrefix, 0, 0, 0, 1 ); 183 layout->addMultiCellWidget( mPrefix, 0, 0, 0, 1 );
178 layout->addMultiCellWidget( mInclusion, 1, 1, 0, 1 ); 184 layout->addMultiCellWidget( mInclusion, 1, 1, 0, 1 );
179 layout->addMultiCellWidget( mSuffix, 2, 2, 0, 1 ); 185 layout->addMultiCellWidget( mSuffix, 2, 2, 0, 1 );
180 layout->addWidget( label, 3, 0 ); 186 layout->addWidget( label, 3, 0 );
181 layout->addWidget( mFormattedNameCombo, 3, 1 ); 187 layout->addWidget( mFormattedNameCombo, 3, 1 );
182 188
183 } 189 }
184 else 190 else
185 { 191 {
186 layout = new QGridLayout( this, 2, 3, KDialog::marginHint(), 192 layout = new QGridLayout( this, 2, 3, KDialog::marginHint(),
187 KDialog::spacingHint() ); 193 KDialog::spacingHint() );
188 194
189 layout->addWidget( mPrefix, 0, 0 ); 195 layout->addWidget( mPrefix, 0, 0 );
190 layout->addWidget( mInclusion, 0, 1 ); 196 layout->addWidget( mInclusion, 0, 1 );
191 layout->addWidget( mSuffix, 0, 2 ); 197 layout->addWidget( mSuffix, 0, 2 );
192 layout->addWidget( label, 1, 0 ); 198 layout->addWidget( label, 1, 0 );
193 layout->addMultiCellWidget( mFormattedNameCombo, 1, 1, 1, 2 ); 199 layout->addMultiCellWidget( mFormattedNameCombo, 1, 1, 1, 2 );
194 } 200 }
195 201
196 connect( mPrefix, SIGNAL( modified() ), SIGNAL( modified() ) ); 202 connect( mPrefix, SIGNAL( modified() ), SIGNAL( modified() ) );
197 connect( mInclusion, SIGNAL( modified() ), SIGNAL( modified() ) ); 203 connect( mInclusion, SIGNAL( modified() ), SIGNAL( modified() ) );
198 connect( mSuffix, SIGNAL( modified() ), SIGNAL( modified() ) ); 204 connect( mSuffix, SIGNAL( modified() ), SIGNAL( modified() ) );
199 connect( mFormattedNameCombo, SIGNAL( activated( int ) ), SIGNAL( modified() ) ); 205 connect( mFormattedNameCombo, SIGNAL( activated( int ) ), SIGNAL( modified() ) );
diff --git a/kaddressbook/kcmconfigs/kabconfigwidget.cpp b/kaddressbook/kcmconfigs/kabconfigwidget.cpp
index 7b3e5c6..38c7946 100644
--- a/kaddressbook/kcmconfigs/kabconfigwidget.cpp
+++ b/kaddressbook/kcmconfigs/kabconfigwidget.cpp
@@ -70,67 +70,73 @@ class ExtensionItem : public QCheckListItem
70 70
71 private: 71 private:
72#ifndef KAB_EMBEDDED 72#ifndef KAB_EMBEDDED
73 KService::Ptr mPtr; 73 KService::Ptr mPtr;
74#else //KAB_EMBEDDED 74#else //KAB_EMBEDDED
75 ExtensionFactory* mFactory; 75 ExtensionFactory* mFactory;
76 QString mName; 76 QString mName;
77 QString mComment; 77 QString mComment;
78 78
79#endif //KAB_EMBEDDED 79#endif //KAB_EMBEDDED
80 80
81}; 81};
82 82
83KABConfigWidget::KABConfigWidget( QWidget *parent, const char *name ) 83KABConfigWidget::KABConfigWidget( QWidget *parent, const char *name )
84 : QWidget( parent, name ) 84 : QWidget( parent, name )
85{ 85{
86 QVBoxLayout *topLayout = new QVBoxLayout( this, 0, 86 QVBoxLayout *topLayout = new QVBoxLayout( this, 0,
87 KDialog::spacingHint() ); 87 KDialog::spacingHint() );
88 88
89 QTabWidget *tabWidget = new QTabWidget( this ); 89 QTabWidget *tabWidget = new QTabWidget( this );
90 topLayout->addWidget( tabWidget ); 90 topLayout->addWidget( tabWidget );
91 91
92 // General page 92 // General page
93 QWidget *generalPage = new QWidget( this ); 93 QWidget *generalPage = new QWidget( this );
94 QVBoxLayout *layout = new QVBoxLayout( generalPage, KDialog::marginHint(), 94 QVBoxLayout *layout = new QVBoxLayout( generalPage, KDialog::marginHintSmall(),
95 KDialog::spacingHint() ); 95 KDialog::spacingHintSmall() );
96 96
97 QGroupBox *groupBox = new QGroupBox( 0, Qt::Vertical, i18n( "General" ), generalPage ); 97 QGroupBox *groupBox = new QGroupBox( 0, Qt::Vertical, i18n( "General" ), generalPage );
98 QVBoxLayout *boxLayout = new QVBoxLayout( groupBox->layout() ); 98 QVBoxLayout *boxLayout = new QVBoxLayout( groupBox->layout() );
99 boxLayout->setAlignment( Qt::AlignTop ); 99 boxLayout->setAlignment( Qt::AlignTop );
100 100 boxLayout->setMargin(KDialog::marginHintSmall() );
101 groupBox->layout()->setMargin(KDialog::marginHintSmall()) ;
102 groupBox->layout()->setSpacing(KDialog::spacingHintSmall());
103 boxLayout->setSpacing( KDialog::spacingHintSmall() );
101 mViewsSingleClickBox = new QCheckBox( i18n( "Honor KDE single click" ), groupBox, "msingle" ); 104 mViewsSingleClickBox = new QCheckBox( i18n( "Honor KDE single click" ), groupBox, "msingle" );
102 boxLayout->addWidget( mViewsSingleClickBox ); 105 boxLayout->addWidget( mViewsSingleClickBox );
103 106
104 mNameParsing = new QCheckBox( i18n( "Automatic name parsing for new addressees" ), groupBox, "mparse" ); 107 mNameParsing = new QCheckBox( i18n( "Automatic name parsing for new addressees" ), groupBox, "mparse" );
105 boxLayout->addWidget( mNameParsing ); 108 boxLayout->addWidget( mNameParsing );
106 109
107 layout->addWidget( groupBox ); 110 layout->addWidget( groupBox );
108 111
109 groupBox = new QGroupBox( 0, Qt::Vertical, i18n( "Extensions" ), generalPage ); 112 groupBox = new QGroupBox( 0, Qt::Vertical, i18n( "Extensions" ), generalPage );
110 boxLayout = new QVBoxLayout( groupBox->layout() ); 113 boxLayout = new QVBoxLayout( groupBox->layout() );
111 boxLayout->setAlignment( Qt::AlignTop ); 114 boxLayout->setAlignment( Qt::AlignTop );
112 115 boxLayout->setMargin(KDialog::marginHintSmall());
116 boxLayout->setSpacing(KDialog::spacingHintSmall());
117 groupBox->layout()->setMargin(1) ;
118 groupBox->layout()->setSpacing(0);
113 mExtensionView = new KListView( groupBox ); 119 mExtensionView = new KListView( groupBox );
114 mExtensionView->setAllColumnsShowFocus( true ); 120 mExtensionView->setAllColumnsShowFocus( true );
115 mExtensionView->addColumn( i18n( "Name" ) ); 121 mExtensionView->addColumn( i18n( "Name" ) );
116 mExtensionView->addColumn( i18n( "Description" ) ); 122 mExtensionView->addColumn( i18n( "Description" ) );
117 mExtensionView->setMaximumHeight(80); 123 mExtensionView->setMaximumHeight(80);
118 124
119 boxLayout->addWidget( mExtensionView ); 125 boxLayout->addWidget( mExtensionView );
120 126
121 mConfigureButton = new QPushButton( i18n( "Configure..." ), groupBox ); 127 mConfigureButton = new QPushButton( i18n( "Configure..." ), groupBox );
122 mConfigureButton->setEnabled( false ); 128 mConfigureButton->setEnabled( false );
123 boxLayout->addWidget( mConfigureButton ); 129 boxLayout->addWidget( mConfigureButton );
124 130
125 layout->addWidget( groupBox ); 131 layout->addWidget( groupBox );
126 132
127 connect( mNameParsing, SIGNAL( toggled( bool ) ), this, SLOT( modified() ) ); 133 connect( mNameParsing, SIGNAL( toggled( bool ) ), this, SLOT( modified() ) );
128 connect( mViewsSingleClickBox, SIGNAL( toggled( bool ) ), this, SLOT( modified() ) ); 134 connect( mViewsSingleClickBox, SIGNAL( toggled( bool ) ), this, SLOT( modified() ) );
129 connect( mExtensionView, SIGNAL( selectionChanged( QListViewItem* ) ), 135 connect( mExtensionView, SIGNAL( selectionChanged( QListViewItem* ) ),
130 SLOT( selectionChanged( QListViewItem* ) ) ); 136 SLOT( selectionChanged( QListViewItem* ) ) );
131 connect( mExtensionView, SIGNAL( clicked( QListViewItem* ) ), 137 connect( mExtensionView, SIGNAL( clicked( QListViewItem* ) ),
132 SLOT( itemClicked( QListViewItem* ) ) ); 138 SLOT( itemClicked( QListViewItem* ) ) );
133 connect( mConfigureButton, SIGNAL( clicked() ), 139 connect( mConfigureButton, SIGNAL( clicked() ),
134 SLOT( configureExtension() ) ); 140 SLOT( configureExtension() ) );
135 141
136 tabWidget->addTab( generalPage, i18n( "General" ) ); 142 tabWidget->addTab( generalPage, i18n( "General" ) );
diff --git a/kaddressbook/kcmconfigs/kcmkabconfig.cpp b/kaddressbook/kcmconfigs/kcmkabconfig.cpp
index 791a940..a278042 100644
--- a/kaddressbook/kcmconfigs/kcmkabconfig.cpp
+++ b/kaddressbook/kcmconfigs/kcmkabconfig.cpp
@@ -7,67 +7,71 @@
7 the Free Software Foundation; either version 2 of the License, or 7 the Free Software Foundation; either version 2 of the License, or
8 (at your option) any later version. 8 (at your option) any later version.
9 9
10 This program is distributed in the hope that it will be useful, 10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of 11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details. 13 GNU General Public License for more details.
14 14
15 You should have received a copy of the GNU General Public License 15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software 16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 17 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
18 18
19 As a special exception, permission is given to link this program 19 As a special exception, permission is given to link this program
20 with any edition of Qt, and distribute the resulting executable, 20 with any edition of Qt, and distribute the resulting executable,
21 without including the source code for Qt in the source distribution. 21 without including the source code for Qt in the source distribution.
22*/ 22*/
23 23
24#include <qlayout.h> 24#include <qlayout.h>
25 25
26#ifndef KAB_EMBEDDED 26#ifndef KAB_EMBEDDED
27#include <kaboutdata.h> 27#include <kaboutdata.h>
28#endif //KAB_EMBEDDED 28#endif //KAB_EMBEDDED
29#include <kdebug.h> 29#include <kdebug.h>
30#include <klocale.h> 30#include <klocale.h>
31#include <stdlib.h>
31 32
32#include "kabconfigwidget.h" 33#include "kabconfigwidget.h"
33 34
34#include "kcmkabconfig.h" 35#include "kcmkabconfig.h"
35 36
36extern "C" 37extern "C"
37{ 38{
38 KCModule *create_kabconfig( QWidget *parent, const char * ) { 39 KCModule *create_kabconfig( QWidget *parent, const char * ) {
39 return new KCMKabConfig( parent, "kcmkabconfig" ); 40 return new KCMKabConfig( parent, "kcmkabconfig" );
40 } 41 }
41} 42}
42 43
43KCMKabConfig::KCMKabConfig( QWidget *parent, const char *name ) 44KCMKabConfig::KCMKabConfig( QWidget *parent, const char *name )
44 : KCModule( parent, name ) 45 : KCModule( parent, name )
45{ 46{
47 //abort();
46 QVBoxLayout *layout = new QVBoxLayout( this ); 48 QVBoxLayout *layout = new QVBoxLayout( this );
47 mConfigWidget = new KABConfigWidget( this, "mConfigWidget" ); 49 mConfigWidget = new KABConfigWidget( this, "mConfigWidget" );
48 layout->addWidget( mConfigWidget ); 50 layout->addWidget( mConfigWidget );
49 51 layout->setSpacing( 0 );
52 layout->setMargin( 0 );
53
50 connect( mConfigWidget, SIGNAL( changed( bool ) ), SIGNAL( changed( bool ) ) ); 54 connect( mConfigWidget, SIGNAL( changed( bool ) ), SIGNAL( changed( bool ) ) );
51 load(); 55 load();
52} 56}
53 57
54void KCMKabConfig::load() 58void KCMKabConfig::load()
55{ 59{
56 mConfigWidget->restoreSettings(); 60 mConfigWidget->restoreSettings();
57} 61}
58 62
59void KCMKabConfig::save() 63void KCMKabConfig::save()
60{ 64{
61 mConfigWidget->saveSettings(); 65 mConfigWidget->saveSettings();
62} 66}
63 67
64void KCMKabConfig::defaults() 68void KCMKabConfig::defaults()
65{ 69{
66 mConfigWidget->defaults(); 70 mConfigWidget->defaults();
67} 71}
68 72
69#ifndef KAB_EMBEDDED 73#ifndef KAB_EMBEDDED
70const KAboutData* KCMKabConfig::aboutData() const 74const KAboutData* KCMKabConfig::aboutData() const
71{ 75{
72 KAboutData *about = new KAboutData( I18N_NOOP( "kcmkabconfig" ), 76 KAboutData *about = new KAboutData( I18N_NOOP( "kcmkabconfig" ),
73 I18N_NOOP( "KAddressBook Configure Dialog" ), 77 I18N_NOOP( "KAddressBook Configure Dialog" ),