The bug (thread) has been fixed.
Files:Maella.DownloadListCtrl.eMule0.26d.zip (Great thanks to Dr.Slump for the hosting)
Maella
This post has been edited by Maella: 19 February 2003 - 03:17 PM
Posted 19 February 2003 - 02:32 PM
This post has been edited by Maella: 19 February 2003 - 03:17 PM
Posted 19 February 2003 - 03:21 PM
Posted 19 February 2003 - 04:53 PM
Posted 19 February 2003 - 08:26 PM
If you have a file with a lot of sources expanded.. Then try to expand another file with a lot of sources right above it, it doesn't expand correctly sometimes..
Posted 19 February 2003 - 10:41 PM
Posted 20 February 2003 - 12:16 AM
Posted 20 February 2003 - 02:34 AM
Posted 20 February 2003 - 10:12 AM
// The same source could be added a few time but only time per file // #ifdef _DEBUG { // Check if this source has been already added for this file std::pair<ListItems::const_iterator, ListItems::const_iterator> rangeIt = m_ListItems.equal_range(source); for(ListItems::const_iterator it = rangeIt.first; it != rangeIt.second; it++){ CtrlItem_Struct* cur_item = it->second; // ASSERT(cur_item->owner != owner); if(cur_item->owner == owner){ cur_item->type = newitem->type; // to check cur_item->dwUpdated = newitem->dwUpdated; // to check delete newitem; return; } } } // #endif m_ListItems.insert(ListItemsPair(source, newitem));
Posted 20 February 2003 - 11:07 AM
theApp.downloadqueue->CheckAndAddKnownSource(SwapTo,this); return true;
theApp.downloadqueue->CheckAndAddKnownSource(SwapTo,this); // It may failed... return (reqfile != NULL);
// The same source could be added a few time but only one time per file { // Update the other instances of this source bool bFound = false; std::pair<ListItems::const_iterator, ListItems::const_iterator> rangeIt = m_ListItems.equal_range(source); for(ListItems::const_iterator it = rangeIt.first; it != rangeIt.second; it++){ CtrlItem_Struct* cur_item = it->second; // Check if this source has been already added to this file => to be sure if(cur_item->owner == owner){ // Update this instance with its new setting cur_item->type = newitem->type; cur_item->dwUpdated = 0; bFound = true; } else if(notavailable == false){ // The state 'Available' is exclusive cur_item->type = UNAVAILABLE_SOURCE; cur_item->dwUpdated = 0; } } if(bFound == true){ delete newitem; return; } } m_ListItems.insert(ListItemsPair(source, newitem));
Posted 20 February 2003 - 03:45 PM
Quote
Posted 20 February 2003 - 06:24 PM
Posted 20 February 2003 - 09:29 PM
Posted 21 February 2003 - 10:10 PM
Posted 21 February 2003 - 10:48 PM
This post has been edited by Maella: 21 February 2003 - 10:51 PM
Posted 22 February 2003 - 12:40 AM
Maella, on Feb 21 2003, 04:48 PM, said:
Posted 22 February 2003 - 01:00 AM
Maella, on Feb 22 2003, 12:48 AM, said:
Posted 22 February 2003 - 04:19 PM
Quote
void CDownloadListCtrl::RemoveFile(CPartFile* toremove){ // Retrieve all entries matching the File or linked to the file // Remark: The 'asked another files' clients must be removed from here ASSERT(toremove != NULL); for(ListItems::iterator it = m_ListItems.begin(); it != m_ListItems.end(); ){ CtrlItem_Struct* delItem = it->second; if(delItem->owner == toremove || delItem->value == toremove){ // Remove it from the m_ListItems it = m_ListItems.erase(it); // Remove it from the CListCtrl LVFINDINFO find; find.flags = LVFI_PARAM; find.lParam = (LPARAM)delItem; sint16 result = FindItem(&find); if(result != (-1)){ DeleteItem(result); } // finally it could be delete delete delItem; } else { it++; } } ShowFilesCount(); }
This post has been edited by Maella: 22 February 2003 - 04:20 PM
Posted 24 February 2003 - 04:59 AM
This post has been edited by khaos: 24 February 2003 - 05:00 AM
Posted 24 February 2003 - 05:44 AM
khaos, on Feb 24 2003, 04:59 AM, said: