mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-12 19:12:28 -04:00
fixed small bug breaking display of flat mode in files
This commit is contained in:
parent
752275f813
commit
443dbdfbef
2 changed files with 7 additions and 4 deletions
|
@ -996,7 +996,7 @@ void p3FileDatabase::getExtraFilesDirDetails(void *ref,DirectoryStorage::EntryIn
|
||||||
d.count = mExtraFilesCache.size();
|
d.count = mExtraFilesCache.size();
|
||||||
d.max_mtime = time(NULL);
|
d.max_mtime = time(NULL);
|
||||||
d.mtime = time(NULL);
|
d.mtime = time(NULL);
|
||||||
d.name = "Extra List";
|
d.name = "[Extra List]";
|
||||||
d.path = "/";
|
d.path = "/";
|
||||||
d.ref = ref ;
|
d.ref = ref ;
|
||||||
|
|
||||||
|
@ -1005,7 +1005,7 @@ void p3FileDatabase::getExtraFilesDirDetails(void *ref,DirectoryStorage::EntryIn
|
||||||
DirStub stub;
|
DirStub stub;
|
||||||
stub.type = DIR_TYPE_FILE;
|
stub.type = DIR_TYPE_FILE;
|
||||||
stub.name = mExtraFilesCache[i].fname;
|
stub.name = mExtraFilesCache[i].fname;
|
||||||
convertEntryIndexToPointer<sizeof(void*)>(i,1,stub.ref); // local shared files from extra list
|
convertEntryIndexToPointer<sizeof(void*)>(i+1,1,stub.ref); // local shared files from extra list
|
||||||
|
|
||||||
d.children.push_back(stub);
|
d.children.push_back(stub);
|
||||||
}
|
}
|
||||||
|
@ -1084,7 +1084,7 @@ int p3FileDatabase::RequestDirDetails(void *ref, DirDetails& d, FileSearchFlags
|
||||||
convertEntryIndexToPointer<sizeof(void*)>(0,1,p); // local shared files from extra list
|
convertEntryIndexToPointer<sizeof(void*)>(0,1,p); // local shared files from extra list
|
||||||
DirStub stub;
|
DirStub stub;
|
||||||
stub.type = DIR_TYPE_PERSON; // not totally exact, but used as a trick.
|
stub.type = DIR_TYPE_PERSON; // not totally exact, but used as a trick.
|
||||||
stub.name = "Extra List";
|
stub.name = "[Extra List]";
|
||||||
stub.ref = p;
|
stub.ref = p;
|
||||||
|
|
||||||
d.children.push_back(stub);
|
d.children.push_back(stub);
|
||||||
|
|
|
@ -1663,7 +1663,7 @@ void FlatStyle_RDM::updateRefs()
|
||||||
|
|
||||||
if (requestDirDetails(ref, RemoteMode,details))
|
if (requestDirDetails(ref, RemoteMode,details))
|
||||||
{
|
{
|
||||||
if(details.type == DIR_TYPE_FILE) // only push files, not directories nor persons.
|
if(details.type == DIR_TYPE_FILE || details.type == DIR_TYPE_EXTRA_FILE) // only push files, not directories nor persons.
|
||||||
_ref_entries.push_back(ref) ;
|
_ref_entries.push_back(ref) ;
|
||||||
#ifdef RDM_DEBUG
|
#ifdef RDM_DEBUG
|
||||||
std::cerr << "FlatStyle_RDM::postMods(): adding ref " << ref << std::endl;
|
std::cerr << "FlatStyle_RDM::postMods(): adding ref " << ref << std::endl;
|
||||||
|
@ -1689,6 +1689,9 @@ void FlatStyle_RDM::updateRefs()
|
||||||
std::cerr << "reference tab contains " << std::dec << _ref_entries.size() << " files" << std::endl;
|
std::cerr << "reference tab contains " << std::dec << _ref_entries.size() << " files" << std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(_ref_stack.empty())
|
||||||
|
_needs_update = false ;
|
||||||
|
|
||||||
RetroshareDirModel::postMods() ;
|
RetroshareDirModel::postMods() ;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue