From 1e8e05e81f50a7567cc67666ffb8bccab9a10199 Mon Sep 17 00:00:00 2001 From: Peter Penz Date: Tue, 21 Sep 2010 19:03:04 +0000 Subject: It was a bad idea to store the enabled additional-information as bit-values: With the current setup only up to 8 additional informations are possible. This restriction is bypassed now: - Backward compatibility for old .directorry files is provided - A version-information has been added for possible future changes - As "side-effect" it also allows to have a details-view with only one column (#238140) BUG: 238140 FIXED-IN: 4.6.0 svn path=/trunk/KDE/kdebase/apps/; revision=1177944 --- src/views/additionalinfoaccessor.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'src/views/additionalinfoaccessor.h') diff --git a/src/views/additionalinfoaccessor.h b/src/views/additionalinfoaccessor.h index 0a3d51459..a1778008c 100644 --- a/src/views/additionalinfoaccessor.h +++ b/src/views/additionalinfoaccessor.h @@ -71,10 +71,18 @@ public: QString translation(KFileItemDelegate::Information info) const; + /** + * @return String representation of the value that is stored in the .directory + * by ViewProperties. + */ + QString value(KFileItemDelegate::Information info) const; + DolphinView::Sorting sorting(KFileItemDelegate::Information info) const; /** * @return Bitvalue for \p info that is stored in a ViewProperties instance. + * Is required only for backward compatibility with the version 1 of + * the view-properties. */ int bitValue(KFileItemDelegate::Information info) const; @@ -88,8 +96,9 @@ private: const char* const actionCollectionName; const char* const context; const char* const translation; + const char* const value; const DolphinView::Sorting sorting; - const int bitValue; + const int bitValue; // for backward compatibility with version 1 of view-properties }; KFileItemDelegate::InformationList m_informations; -- cgit v1.3