mirror of
https://github.com/yusufipk/dikte.git
synced 2026-09-11 10:56:10 +00:00
Count a model bigger than two gigabytes upwards
Qt's int is C++'s 32-bit one, so the progress of a 2.3 GB download arrived at the other end of the signal as -1805209440, which is the real figure less 2^32. The file was landing correctly; only the line under it was wrong, reading "1.0 MB of -1805209440 B (-1%)".
This commit is contained in:
+3
-1
@@ -119,7 +119,9 @@ class LocalModelBox(QGroupBox):
|
||||
|
||||
_listed = pyqtSignal(list, str)
|
||||
_quants = pyqtSignal(list, str)
|
||||
_progress = pyqtSignal(int, int)
|
||||
# qint64 rather than int, which is C++'s 32-bit one: a 2.3 GB model is more
|
||||
# than fits in it, and the count comes out the far side negative.
|
||||
_progress = pyqtSignal("qint64", "qint64")
|
||||
_finished = pyqtSignal(str, str)
|
||||
_installed = pyqtSignal(str, str)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user