cleanup: remove dead code

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2020-03-26 12:15:20 -07:00
parent 66fd93c9cc
commit 8177dd4dc3

View file

@ -94,25 +94,14 @@ static void appendTextToLogStandalone(const char *text)
// show the git progress in the passive notification area // show the git progress in the passive notification area
extern "C" int gitProgressCB(const char *text) extern "C" int gitProgressCB(const char *text)
{ {
static QElapsedTimer timer;
static qint64 lastTime = 0;
static QMLManager *self; static QMLManager *self;
if (!self) if (!self)
self = QMLManager::instance(); self = QMLManager::instance();
if (!timer.isValid()) {
timer.restart();
lastTime = 0;
}
if (self) { if (self) {
qint64 elapsed = timer.elapsed();
self->appendTextToLog(text); self->appendTextToLog(text);
self->setNotificationText(text); self->setNotificationText(text);
//if (elapsed - lastTime > 50) { // 20 Hz refresh
// qApp->processEvents(QEventLoop::ExcludeUserInputEvents);
//}
lastTime = elapsed;
} }
// return 0 so that we don't end the download // return 0 so that we don't end the download
return 0; return 0;