summaryrefslogtreecommitdiffstats
path: root/tdeio/tdeio/tdefileitem.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tdeio/tdeio/tdefileitem.cpp')
-rw-r--r--tdeio/tdeio/tdefileitem.cpp18
1 files changed, 2 insertions, 16 deletions
diff --git a/tdeio/tdeio/tdefileitem.cpp b/tdeio/tdeio/tdefileitem.cpp
index 0124e4b0d..df9937c49 100644
--- a/tdeio/tdeio/tdefileitem.cpp
+++ b/tdeio/tdeio/tdefileitem.cpp
@@ -206,7 +206,6 @@ void KFileItem::init( bool _determineMimeTypeOnDemand )
}
// Initialize hidden file matching apparatus
- //-Debug: TSMTRACE "KFileItem::init(): Initialization for '" << m_url.fileName() << "' almost complete, initializing the hidden file matcher" << endl;
m_pHiddenFileMatcher = nullptr; // need to do or next will segfault
setHiddenFileMatcher( TDEGlobal::hiddenFileMatcher() );
}
@@ -837,52 +836,39 @@ bool KFileItem::isWritable() const
void KFileItem::setHiddenFileMatcher( TDEStringMatcher *hiddenFileMatcher )
{
- //-Debug: TSMTRACE << "KFileItem::setHiddenFileMatcher(...) called for " << m_url.fileName() << endl ;
-
if ( hiddenFileMatcher == m_pHiddenFileMatcher )
return;
- //-Debug: TSMTRACE << " Attempting to disconnect slots from hidden file matcher (" << m_pHiddenFileMatcher << ") signals ... " << endl;
if (m_pHiddenFileMatcher != nullptr)
disconnect( m_pHiddenFileMatcher, 0, this, 0 );
- ; //-Debug: TSMTRACE << " ... all slots successfully disconnected" << endl;
- //-Debug: TSMTRACE << " Changing hidden file matcher from " << m_pHiddenFileMatcher << " to " << hiddenFileMatcher << endl;
m_pHiddenFileMatcher = hiddenFileMatcher;
if ( hiddenFileMatcher != nullptr ) {
- //-Debug: TSMTRACE << " New pattern string: " << hiddenFileMatcher->getMatchSpecString() << endl ;
- //-Debug: TSMTRACE << " Attempting to reconnect slots to hidden file matcher signals ... " << endl;
- if ( connect( m_pHiddenFileMatcher, TQT_SIGNAL( destroyed() ), this, TQT_SLOT( setHiddenFileMatcher() ) ) )
- ; //-Debug: TSMTRACE << " Connected slot sethiddenFileMatcher() to signal destroyed()" << endl;
- if ( connect( m_pHiddenFileMatcher, TQT_SIGNAL( patternsChanged() ), this, TQT_SLOT( reEvaluateHidden() ) ) )
- ; //-Debug: TSMTRACE << " Connected slot reEvaluateHidden() to signal patternsChanged()" << endl;
+ connect( m_pHiddenFileMatcher, TQT_SIGNAL( destroyed() ), this, TQT_SLOT( setHiddenFileMatcher() ) ) ;
+ connect( m_pHiddenFileMatcher, TQT_SIGNAL( patternsChanged() ), this, TQT_SLOT( reEvaluateHidden() ) ) ;
}
else {
kdWarning() << "KFileItem::setHiddenFileMatcher: called with null pointer, nothing will be hidden any more" << endl;
}
- //-Debug: TSMTRACE << "KFileItem::setHiddenFileMatcher(...) finished, calling reEvaluateHidden()" << endl ;
reEvaluateHidden();
}
void KFileItem::reEvaluateHidden()
{
- //-Debug: TSMTRACE << "KFileItem::reEvaluateHidden() called for " << m_url.fileName() <<endl ;
if ( m_pHiddenFileMatcher == nullptr ) // abnormal
m_bHiddenByMatcher = false;
else if ( !m_url.isEmpty() )
m_bHiddenByMatcher = m_pHiddenFileMatcher->matchAny( m_url.fileName() );
else // should never happen
m_bHiddenByMatcher = m_pHiddenFileMatcher->matchAny( m_strName );
- //-Debug: TSMTRACE << "KFileItem::reEvaluateHidden() completed for " << m_url.fileName() << " [" << m_bHiddenByMatcher << "]" << endl ;
}
bool KFileItem::isHidden() const
{
if ( m_hidden != Auto )
return m_hidden == Hidden;
- // TSMTRACE << "KFileItem::isHidden() called for " << m_url.fileName() << " [" << m_bHiddenByMatcher << "]" <<endl ;
return m_bHiddenByMatcher;
}