1
0
mirror of https://github.com/d47081/qBittorrent.git synced 2025-01-10 14:57:52 +00:00

- Added ASSERT for make sure our progress values are always possible

This commit is contained in:
Christophe Dumez 2009-11-29 14:37:33 +00:00
parent d8c27ac8c4
commit 63e5339690

View File

@ -136,6 +136,7 @@ public:
void setProgress(float progress) { void setProgress(float progress) {
if(progress == getProgress()) return; if(progress == getProgress()) return;
Q_ASSERT(progress >= 0. && progress <= 1.);
itemData.replace(2, progress); itemData.replace(2, progress);
if(parentItem) if(parentItem)
parentItem->updateProgress(); parentItem->updateProgress();