summaryrefslogtreecommitdiff
path: root/core/pim/addressbook/abconfig.cpp
Side-by-side diff
Diffstat (limited to 'core/pim/addressbook/abconfig.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--core/pim/addressbook/abconfig.cpp22
1 files changed, 19 insertions, 3 deletions
diff --git a/core/pim/addressbook/abconfig.cpp b/core/pim/addressbook/abconfig.cpp
index a3fd222..2583327 100644
--- a/core/pim/addressbook/abconfig.cpp
+++ b/core/pim/addressbook/abconfig.cpp
@@ -20,5 +20,5 @@ AbConfig::AbConfig( ):
AbConfig::~AbConfig()
{
-}
+}
bool AbConfig::useRegExp() const
@@ -67,4 +67,9 @@ AbConfig::LPSearchMode AbConfig::letterPickerSearch() const
}
+const QString &AbConfig::category() const
+{
+ return m_category;
+}
+
void AbConfig::setUseRegExp( bool v )
{
@@ -122,4 +127,9 @@ void AbConfig::setLetterPickerSearch( const AbConfig::LPSearchMode mode )
}
+void AbConfig::setCategory( const QString &cat )
+{
+ m_category = cat;
+}
+
void AbConfig::load()
{
@@ -127,4 +137,7 @@ void AbConfig::load()
Config cfg("AddressBook");
+ cfg.setGroup( "View" );
+ m_category = cfg.readEntry( "Category", "All" );
+
cfg.setGroup("Font");
m_fontSize = cfg.readNumEntry( "fontSize", 1 );
@@ -167,4 +180,7 @@ void AbConfig::save()
if ( m_changed ){
Config cfg("AddressBook");
+ cfg.setGroup( "View" );
+ cfg.writeEntry( "Category", m_category );
+
cfg.setGroup("Font");
cfg.writeEntry("fontSize", m_fontSize);
@@ -194,7 +210,7 @@ void AbConfig::save()
cfg.writeEntry( "SubVersion", SUBVERSION );
cfg.writeEntry( "PatchVersion", PATCHVERSION );
-
+
}
-
+
}