unsigned HashProgress::getHashStatus() { ShareManager *SM = ShareManager::getInstance(); HashManager *HM = HashManager::getInstance(); if( SM->isRefreshing() ) return LISTUPDATE; if( HM->isHashingPaused() ) { return (Util::getUpTime() < SETTING(HASHING_START_DELAY)) ? DELAYED : PAUSED; } string path; int64_t bytes = 0; size_t files = 0; HM->getStats(path, bytes, files); if( bytes != 0 || files != 0 ) return RUNNING; return IDLE; }