summaryrefslogtreecommitdiffabout
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--bin/kdepim/WhatsNew.txt1
-rw-r--r--kaddressbook/viewmanager.cpp7
-rw-r--r--kaddressbook/views/configuretableviewdialog.cpp2
3 files changed, 9 insertions, 1 deletions
diff --git a/bin/kdepim/WhatsNew.txt b/bin/kdepim/WhatsNew.txt
index 2e5cf50..18e94a7 100644
--- a/bin/kdepim/WhatsNew.txt
+++ b/bin/kdepim/WhatsNew.txt
@@ -8,4 +8,5 @@ Fixed a problem displaying very long allday events in agenda view in single day
KA/Pi:
Added a config option to turn on asking before a contact is deleted.
+Fixed a problem with the default view and view selection at startup.
********** VERSION 2.2.0 ************
diff --git a/kaddressbook/viewmanager.cpp b/kaddressbook/viewmanager.cpp
index c738ad8..b5d9419 100644
--- a/kaddressbook/viewmanager.cpp
+++ b/kaddressbook/viewmanager.cpp
@@ -242,4 +242,7 @@ void ViewManager::setActiveView( const QString &name )
if ( view ) {
+ if ( !mViewNameList.contains( name ) ) {
+ mViewNameList.append( name );
+ }
view->setCaption( name );
mViewDict.insert( name, view );
@@ -291,4 +294,8 @@ void ViewManager::setActiveView( const QString &name )
//US performance optimization. setActiveFilter calls also mActiveView->refresh()
//US mActiveView->refresh();
+
+ mActionSelectView->setItems( mViewNameList );
+ mActionSelectView->setCurrentItem( mViewNameList.findIndex( mActiveView->caption() ) );
+
}
else
diff --git a/kaddressbook/views/configuretableviewdialog.cpp b/kaddressbook/views/configuretableviewdialog.cpp
index 0e36abd..c329cd9 100644
--- a/kaddressbook/views/configuretableviewdialog.cpp
+++ b/kaddressbook/views/configuretableviewdialog.cpp
@@ -108,5 +108,5 @@ void LookAndFeelPage::restoreSettings( KConfig *config )
cbEnableCustomColors->setChecked( config->readBoolEntry( "EnableCustomColors", false ) );
QColor c;
-qDebug("LookAndFeelPage::restoreSettings make base color configurable");
+ //qDebug("LookAndFeelPage::restoreSettings make base color configurable");
#ifndef KAB_EMBEDDED