summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTannin <devnull@localhost>2014-04-25 19:15:12 +0200
committerTannin <devnull@localhost>2014-04-25 19:15:12 +0200
commit84cfa95254d28223c0c7fc2f3939b3225694a048 (patch)
treebb9400efd33fdd2344976e2787db759a61540e1b
parent264da609298c3bb533d32e53f39659d9c7e09bbf (diff)
- bugfix: newly installed files could be added hidden
- bugfix: registered bsas in data aren't ordered correctly
-rw-r--r--src/downloadmanager.h2
-rw-r--r--src/mainwindow.cpp5
2 files changed, 4 insertions, 3 deletions
diff --git a/src/downloadmanager.h b/src/downloadmanager.h
index e0cc20bd..9ea95e6a 100644
--- a/src/downloadmanager.h
+++ b/src/downloadmanager.h
@@ -109,7 +109,7 @@ private:
private:
static unsigned int s_NextDownloadID;
private:
- DownloadInfo() : m_TotalSize(0), m_ReQueried(false) {}
+ DownloadInfo() : m_TotalSize(0), m_ReQueried(false), m_Hidden(false) {}
};
public:
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index 2ca5adc6..81696a4c 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -1938,7 +1938,6 @@ void MainWindow::refreshBSAList()
for (int i = 0; i < m_DefaultArchives.count(); ++i) {
m_DefaultArchives[i] = m_DefaultArchives[i].trimmed();
}
-
m_ActiveArchives.clear();
QFile archiveFile(m_CurrentProfile->getArchivesFileName());
@@ -1970,6 +1969,9 @@ void MainWindow::refreshBSAList()
continue;
}
int index = m_ActiveArchives.indexOf(filename);
+ if (index == -1) {
+ index = 0xFFFF;
+ }
QStringList strings(filename);
bool isArchive = false;
int origin = current->getOrigin(isArchive);
@@ -1978,7 +1980,6 @@ void MainWindow::refreshBSAList()
newItem->setData(0, Qt::UserRole, index);
newItem->setData(1, Qt::UserRole, origin);
newItem->setFlags(newItem->flags() & ~Qt::ItemIsDropEnabled | Qt::ItemIsUserCheckable);
-// newItem->setFlags(newItem->flags() | Qt::ItemIsUserCheckable);
newItem->setCheckState(0, (index != -1) ? Qt::Checked : Qt::Unchecked);
if (m_Settings.forceEnableCoreFiles() && m_DefaultArchives.contains(filename)) {
newItem->setCheckState(0, Qt::Checked);