summaryrefslogtreecommitdiffabout
path: root/kaddressbook
Unidiff
Diffstat (limited to 'kaddressbook') (more/less context) (ignore whitespace changes)
-rw-r--r--kaddressbook/details/detailsviewcontainer.cpp11
-rw-r--r--kaddressbook/details/detailsviewcontainer.h1
-rw-r--r--kaddressbook/imagewidget.cpp7
-rw-r--r--kaddressbook/kabcore.cpp9
-rw-r--r--kaddressbook/kabcore.h9
-rw-r--r--kaddressbook/viewmanager.cpp1
6 files changed, 9 insertions, 29 deletions
diff --git a/kaddressbook/details/detailsviewcontainer.cpp b/kaddressbook/details/detailsviewcontainer.cpp
index ceffc77..229cce0 100644
--- a/kaddressbook/details/detailsviewcontainer.cpp
+++ b/kaddressbook/details/detailsviewcontainer.cpp
@@ -129,22 +129,13 @@ void ViewContainer::slotStyleSelected( int index )
129 mCurrentLook->restoreSettings( config ); 129 mCurrentLook->restoreSettings( config );
130 mCurrentLook->setAddressee( addr ); 130 mCurrentLook->setAddressee( addr );
131} 131}
132void ViewContainer::refreshView()
133{
134 if ( mCurrentLook ) {
135 mCurrentLook->setAddressee( mCurrentAddressee );
136 }
137}
138 132
139void ViewContainer::setAddressee( const KABC::Addressee& addressee ) 133void ViewContainer::setAddressee( const KABC::Addressee& addressee )
140{ 134{
141 if ( mCurrentLook != 0 ) { 135 if ( mCurrentLook != 0 ) {
142 if ( addressee == mCurrentAddressee )
143 return;
144 else {
145 mCurrentAddressee = addressee; 136 mCurrentAddressee = addressee;
146 mCurrentLook->setAddressee( mCurrentAddressee ); 137 mCurrentLook->setAddressee( mCurrentAddressee );
147 } 138
148 } 139 }
149} 140}
150 141
diff --git a/kaddressbook/details/detailsviewcontainer.h b/kaddressbook/details/detailsviewcontainer.h
index b561d12..667f0cb 100644
--- a/kaddressbook/details/detailsviewcontainer.h
+++ b/kaddressbook/details/detailsviewcontainer.h
@@ -45,7 +45,6 @@ class ViewContainer : public QWidget
45 a new object) at any time. 45 a new object) at any time.
46 */ 46 */
47 KABBasicLook *currentLook(); 47 KABBasicLook *currentLook();
48 void refreshView();
49 /** 48 /**
50 Return the contact currently displayed. 49 Return the contact currently displayed.
51 */ 50 */
diff --git a/kaddressbook/imagewidget.cpp b/kaddressbook/imagewidget.cpp
index 49d456b..48370e3 100644
--- a/kaddressbook/imagewidget.cpp
+++ b/kaddressbook/imagewidget.cpp
@@ -131,10 +131,6 @@ ImageWidget::ImageWidget( QWidget *parent, const char *name )
131 KAcceleratorManager::manage( this ); 131 KAcceleratorManager::manage( this );
132#endif //KAB_EMBEDDED 132#endif //KAB_EMBEDDED
133 133
134#ifndef DESKTOP_VERSION
135 mUsePhotoUrl->setChecked( true );
136 mUseLogoUrl->setChecked( true );
137#endif
138} 134}
139 135
140ImageWidget::~ImageWidget() 136ImageWidget::~ImageWidget()
@@ -260,12 +256,11 @@ void ImageWidget::updateGUI()
260{ 256{
261 KURLRequester *ptr = (KURLRequester*)sender(); 257 KURLRequester *ptr = (KURLRequester*)sender();
262 258
263#ifdef DESKTOP_VERSION 259
264 if ( ptr == mPhotoUrl ) 260 if ( ptr == mPhotoUrl )
265 mUsePhotoUrl->setEnabled( true ); 261 mUsePhotoUrl->setEnabled( true );
266 else if ( ptr == mLogoUrl ) 262 else if ( ptr == mLogoUrl )
267 mUseLogoUrl->setEnabled( true ); 263 mUseLogoUrl->setEnabled( true );
268#endif
269} 264}
270 265
271QPixmap ImageWidget::loadPixmap( const KURL &url ) 266QPixmap ImageWidget::loadPixmap( const KURL &url )
diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp
index f6bdda4..e14e579 100644
--- a/kaddressbook/kabcore.cpp
+++ b/kaddressbook/kabcore.cpp
@@ -1126,9 +1126,7 @@ void KABCore::setModifiedWOrefresh()
1126 // qDebug("KABCore::setModifiedWOrefresh() "); 1126 // qDebug("KABCore::setModifiedWOrefresh() ");
1127 mModified = true; 1127 mModified = true;
1128 mActionSave->setEnabled( mModified ); 1128 mActionSave->setEnabled( mModified );
1129#ifdef DESKTOP_VERSION 1129
1130 mDetails->refreshView();
1131#endif
1132 1130
1133} 1131}
1134void KABCore::setModified( bool modified ) 1132void KABCore::setModified( bool modified )
@@ -1140,7 +1138,6 @@ void KABCore::setModified( bool modified )
1140 mJumpButtonBar->recreateButtons(); 1138 mJumpButtonBar->recreateButtons();
1141 1139
1142 mViewManager->refreshView(); 1140 mViewManager->refreshView();
1143 mDetails->refreshView();
1144 1141
1145} 1142}
1146 1143
@@ -1166,7 +1163,7 @@ void KABCore::contactModified( const KABC::Addressee &addr )
1166 1163
1167 UndoStack::instance()->push( command ); 1164 UndoStack::instance()->push( command );
1168 RedoStack::instance()->clear(); 1165 RedoStack::instance()->clear();
1169 1166 mDetails->setAddressee( addr );
1170 setModified( true ); 1167 setModified( true );
1171} 1168}
1172 1169
@@ -1633,7 +1630,6 @@ void KABCore::addressBookChanged()
1633 mEditorDialog->setAddressee( mAddressBook->findByUid( currentuid ) ); 1630 mEditorDialog->setAddressee( mAddressBook->findByUid( currentuid ) );
1634 } 1631 }
1635 mViewManager->refreshView(); 1632 mViewManager->refreshView();
1636// mDetails->refreshView();
1637 1633
1638 1634
1639} 1635}
@@ -2289,7 +2285,6 @@ void KABCore::manageCategories( )
2289 } 2285 }
2290 setModified( true ); 2286 setModified( true );
2291 mViewManager->refreshView(); 2287 mViewManager->refreshView();
2292 mDetails->refreshView();
2293 message( i18n("Removing categories done!")); 2288 message( i18n("Removing categories done!"));
2294 } 2289 }
2295 delete cp; 2290 delete cp;
diff --git a/kaddressbook/kabcore.h b/kaddressbook/kabcore.h
index c7c12ff..85ffbdb 100644
--- a/kaddressbook/kabcore.h
+++ b/kaddressbook/kabcore.h
@@ -95,10 +95,7 @@ class KABCore : public QWidget, public KSyncInterface
95 */ 95 */
96 void restoreSettings(); 96 void restoreSettings();
97 97
98 /** 98
99 Saves the global settings.
100 */
101 void saveSettings();
102 99
103 /** 100 /**
104 Returns a pointer to the StdAddressBook of the application. 101 Returns a pointer to the StdAddressBook of the application.
@@ -358,7 +355,9 @@ class KABCore : public QWidget, public KSyncInterface
358 void syncFileRequest(); 355 void syncFileRequest();
359 void setDetailsVisible( bool visible ); 356 void setDetailsVisible( bool visible );
360 void setDetailsToState(); 357 void setDetailsToState();
361 // void slotSyncMenu( int ); 358
359 void saveSettings();
360
362 private slots: 361 private slots:
363 void updateToolBar(); 362 void updateToolBar();
364 void updateMainWindow(); 363 void updateMainWindow();
diff --git a/kaddressbook/viewmanager.cpp b/kaddressbook/viewmanager.cpp
index 33bef5a..59bddd9 100644
--- a/kaddressbook/viewmanager.cpp
+++ b/kaddressbook/viewmanager.cpp
@@ -605,6 +605,7 @@ void ViewManager::configureFilters()
605 if (QApplication::desktop()->width() == 480 ) 605 if (QApplication::desktop()->width() == 480 )
606 cw = 0; 606 cw = 0;
607 mActionSelectFilter->setComboWidth( cw ); 607 mActionSelectFilter->setComboWidth( cw );
608 saveSettings();
608} 609}
609 610
610QStringList ViewManager::filterNames() const 611QStringList ViewManager::filterNames() const