author | eilers <eilers> | 2005-03-24 16:23:51 (UTC) |
---|---|---|
committer | eilers <eilers> | 2005-03-24 16:23:51 (UTC) |
commit | b390bcd32e188fc3c9fd7067bfc41b60b5e84ad4 (patch) (side-by-side diff) | |
tree | 38bc784605eb06a6669e8708c86cc9cebaa32b2a /core/pim/addressbook/abview.cpp | |
parent | 29da9a4477210843435cbea3ede0d520775fe1a5 (diff) | |
download | opie-b390bcd32e188fc3c9fd7067bfc41b60b5e84ad4.zip opie-b390bcd32e188fc3c9fd7067bfc41b60b5e84ad4.tar.gz opie-b390bcd32e188fc3c9fd7067bfc41b60b5e84ad4.tar.bz2 |
In table view: Clicking on column 0 changes the sortorder.
Version of ths app was changed to 1.2.0
Requested by #1591
Diffstat (limited to 'core/pim/addressbook/abview.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | core/pim/addressbook/abview.cpp | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/core/pim/addressbook/abview.cpp b/core/pim/addressbook/abview.cpp index 8a2db96..9f7f71f 100644 --- a/core/pim/addressbook/abview.cpp +++ b/core/pim/addressbook/abview.cpp @@ -44,2 +44,3 @@ AbView::AbView ( QWidget* parent, const QValueList<int>& ordered ): m_inPersonal( false ), + m_sortOrder( true ), m_curr_category( 0 ), @@ -82,2 +83,4 @@ AbView::AbView ( QWidget* parent, const QValueList<int>& ordered ): this, SLOT( slotSwitch(void) ) ); + connect ( m_abTable, SIGNAL( signalSortOrderChanged( bool ) ), + this, SLOT( slotSetSortOrder( bool ) ) ); connect ( m_ablabel, SIGNAL( signalOkPressed(void) ), @@ -163,3 +166,3 @@ void AbView::load() // Show just unfiled contacts - m_list = m_contactdb->sorted( true, Opie::OPimContactAccess::SortFileAsName, + m_list = m_contactdb->sorted( m_sortOrder, Opie::OPimContactAccess::SortFileAsName, Opie::OPimContactAccess::DoNotShowWithCategory, 0 ); @@ -167,3 +170,3 @@ void AbView::load() // Just show all contacts - m_list = m_contactdb->sorted( true, Opie::OPimContactAccess::SortFileAsName, + m_list = m_contactdb->sorted( m_sortOrder, Opie::OPimContactAccess::SortFileAsName, Opie::OPimBase::FilterOff, 0 ); @@ -171,3 +174,3 @@ void AbView::load() // Show contacts with given categories - m_list = m_contactdb->sorted( true, Opie::OPimContactAccess::SortFileAsName, + m_list = m_contactdb->sorted( m_sortOrder, Opie::OPimContactAccess::SortFileAsName, Opie::OPimBase::FilterCategory, m_curr_category ); @@ -418,2 +421,7 @@ void AbView::slotSwitch(){ +void AbView::slotSetSortOrder( bool order ){ + m_sortOrder = order; + reload(); +} + // END: Slots |