-rw-r--r-- | kaddressbook/views/cardview.cpp | 6 | ||||
-rw-r--r-- | kaddressbook/views/kaddressbookcardview.cpp | 5 |
2 files changed, 8 insertions, 3 deletions
diff --git a/kaddressbook/views/cardview.cpp b/kaddressbook/views/cardview.cpp index 6351c11..da552c3 100644 --- a/kaddressbook/views/cardview.cpp +++ b/kaddressbook/views/cardview.cpp | |||
@@ -34,6 +34,7 @@ | |||
34 | #include <qcursor.h> | 34 | #include <qcursor.h> |
35 | #include <qtooltip.h> | 35 | #include <qtooltip.h> |
36 | 36 | ||
37 | #include "kabprefs.h" | ||
37 | #include <kdebug.h> | 38 | #include <kdebug.h> |
38 | #include <kglobalsettings.h> | 39 | #include <kglobalsettings.h> |
39 | //END includes | 40 | //END includes |
@@ -656,7 +657,6 @@ CardView::CardView(QWidget *parent, const char *name) | |||
656 | viewport()->setBackgroundMode(PaletteBase); | 657 | viewport()->setBackgroundMode(PaletteBase); |
657 | 658 | ||
658 | connect( d->mTimer, SIGNAL(timeout()), this, SLOT(tryShowFullText()) ); | 659 | connect( d->mTimer, SIGNAL(timeout()), this, SLOT(tryShowFullText()) ); |
659 | connect( this, SIGNAL(executed(CardViewItem *)), this, SIGNAL( doubleClicked(CardViewItem *)) ); | ||
660 | 660 | ||
661 | //US setBackgroundMode(PaletteBackground, PaletteBase); | 661 | //US setBackgroundMode(PaletteBackground, PaletteBase); |
662 | setBackgroundMode(PaletteBackground); | 662 | setBackgroundMode(PaletteBackground); |
@@ -1247,7 +1247,7 @@ void CardView::contentsMouseReleaseEvent(QMouseEvent *e) | |||
1247 | // Get the item at this position | 1247 | // Get the item at this position |
1248 | CardViewItem *item = itemAt(e->pos()); | 1248 | CardViewItem *item = itemAt(e->pos()); |
1249 | 1249 | ||
1250 | if (item && KGlobalSettings::singleClick()) | 1250 | if (item && KABPrefs::instance()->mHonorSingleClick) |
1251 | { | 1251 | { |
1252 | emit executed(item); | 1252 | emit executed(item); |
1253 | } | 1253 | } |
@@ -1264,7 +1264,7 @@ void CardView::contentsMouseDoubleClickEvent(QMouseEvent *e) | |||
1264 | d->mCurrentItem = item; | 1264 | d->mCurrentItem = item; |
1265 | } | 1265 | } |
1266 | 1266 | ||
1267 | if (item && !KGlobalSettings::singleClick()) | 1267 | if (item && !KABPrefs::instance()->mHonorSingleClick) |
1268 | { | 1268 | { |
1269 | emit executed(item); | 1269 | emit executed(item); |
1270 | } else | 1270 | } else |
diff --git a/kaddressbook/views/kaddressbookcardview.cpp b/kaddressbook/views/kaddressbookcardview.cpp index 7f33bb4..15f154e 100644 --- a/kaddressbook/views/kaddressbookcardview.cpp +++ b/kaddressbook/views/kaddressbookcardview.cpp | |||
@@ -242,6 +242,8 @@ void KAddressBookCardView::readConfig(KConfig *config) | |||
242 | mCardView->setItemSpacing( config->readNumEntry( "ItemSpacing", 10 ) ); | 242 | mCardView->setItemSpacing( config->readNumEntry( "ItemSpacing", 10 ) ); |
243 | mCardView->setSeparatorWidth( config->readNumEntry( "SeparatorWidth", 2 ) ); | 243 | mCardView->setSeparatorWidth( config->readNumEntry( "SeparatorWidth", 2 ) ); |
244 | 244 | ||
245 | #if 0 | ||
246 | // LR KABPrefs::instance()->mHonorSingleClick is handled and fixed in cardviews contentsMouseDoubleClickEven | ||
245 | disconnect(mCardView, SIGNAL(executed(CardViewItem *)), | 247 | disconnect(mCardView, SIGNAL(executed(CardViewItem *)), |
246 | this, SLOT(addresseeExecuted(CardViewItem *))); | 248 | this, SLOT(addresseeExecuted(CardViewItem *))); |
247 | 249 | ||
@@ -251,7 +253,10 @@ void KAddressBookCardView::readConfig(KConfig *config) | |||
251 | else | 253 | else |
252 | connect(mCardView, SIGNAL(doubleClicked(CardViewItem *)), | 254 | connect(mCardView, SIGNAL(doubleClicked(CardViewItem *)), |
253 | this, SLOT(addresseeExecuted(CardViewItem *))); | 255 | this, SLOT(addresseeExecuted(CardViewItem *))); |
256 | #endif | ||
254 | 257 | ||
258 | connect(mCardView, SIGNAL(doubleClicked(CardViewItem *)), | ||
259 | this, SLOT(addresseeExecuted(CardViewItem *))); | ||
255 | } | 260 | } |
256 | 261 | ||
257 | void KAddressBookCardView::writeConfig( KConfig *config ) | 262 | void KAddressBookCardView::writeConfig( KConfig *config ) |