summaryrefslogtreecommitdiffstats
path: root/libkonq/konq_propsview.cc
diff options
context:
space:
mode:
Diffstat (limited to 'libkonq/konq_propsview.cc')
-rw-r--r--libkonq/konq_propsview.cc20
1 files changed, 20 insertions, 0 deletions
diff --git a/libkonq/konq_propsview.cc b/libkonq/konq_propsview.cc
index bc8aa4e9d..edaff588b 100644
--- a/libkonq/konq_propsview.cc
+++ b/libkonq/konq_propsview.cc
@@ -94,6 +94,7 @@ KonqPropsView::KonqPropsView( TDEInstance * instance, KonqPropsView * defaultPro
d->descending = config->readBoolEntry( "SortDescending", false );
m_bShowDot = config->readBoolEntry( "ShowDotFiles", false );
m_bShowDirectoryOverlays = config->readBoolEntry( "ShowDirectoryOverlays", false );
+ m_bShowFreeSpaceOverlays = config->readBoolEntry( "ShowFreeSpaceOverlays", false );
m_dontPreview = config->readListEntry( "DontPreview" );
m_dontPreview.remove("audio/"); //Use the separate setting.
@@ -222,6 +223,7 @@ bool KonqPropsView::enterDir( const KURL & dir )
m_bShowDot = config->readBoolEntry( "ShowDotFiles", m_bShowDot );
d->caseInsensitiveSort=config->readBoolEntry("CaseInsensitiveSort",d->caseInsensitiveSort);
m_bShowDirectoryOverlays = config->readBoolEntry( "ShowDirectoryOverlays", m_bShowDirectoryOverlays );
+ m_bShowFreeSpaceOverlays = config->readBoolEntry( "ShowFreeSpaceOverlays", m_bShowFreeSpaceOverlays );
if (config->hasKey( "DontPreview" ))
{
m_dontPreview = config->readListEntry( "DontPreview" );
@@ -393,6 +395,24 @@ void KonqPropsView::setShowingDirectoryOverlays( bool show )
}
}
+void KonqPropsView::setShowingFreeSpaceOverlays( bool show )
+{
+ kdDebug(1203) << "KonqPropsView::setShowingFreeSpaceOverlays " << show << endl;
+ m_bShowFreeSpaceOverlays = show;
+ if ( m_defaultProps && !m_bSaveViewPropertiesLocally )
+ {
+ kdDebug(1203) << "Saving in default properties" << endl;
+ m_defaultProps->setShowingFreeSpaceOverlays( show );
+ }
+ else if (currentConfig())
+ {
+ kdDebug(1203) << "Saving in current config" << endl;
+ TDEConfigGroupSaver cgs(currentConfig(), currentGroup());
+ currentConfig()->writeEntry( "ShowFreeSpaceOverlays", m_bShowFreeSpaceOverlays );
+ currentConfig()->sync();
+ }
+}
+
void KonqPropsView::setShowingPreview( const TQString &preview, bool show )
{
if ( m_dontPreview.contains( preview ) != show )