avatar reset bug fixed
This commit is contained in:
parent
89c4b2cdf6
commit
ac1800703f
@ -16,7 +16,7 @@ TOX_FILE_TRANSFER_STATE = {
|
|||||||
|
|
||||||
|
|
||||||
class StateSignal(QtCore.QObject):
|
class StateSignal(QtCore.QObject):
|
||||||
signal = QtCore.Signal(int, float)
|
signal = QtCore.Signal(int, float) # state and progress
|
||||||
|
|
||||||
|
|
||||||
class FileTransfer(QtCore.QObject):
|
class FileTransfer(QtCore.QObject):
|
||||||
@ -98,6 +98,7 @@ class SendTransfer(FileTransfer):
|
|||||||
self._done += size
|
self._done += size
|
||||||
self._state_changed.signal.emit(self.state, self._done / self._size)
|
self._state_changed.signal.emit(self.state, self._done / self._size)
|
||||||
else:
|
else:
|
||||||
|
if hasattr(self, '_file'):
|
||||||
self._file.close()
|
self._file.close()
|
||||||
self.state = TOX_FILE_TRANSFER_STATE['FINISHED']
|
self.state = TOX_FILE_TRANSFER_STATE['FINISHED']
|
||||||
self._state_changed.signal.emit(self.state, 1)
|
self._state_changed.signal.emit(self.state, 1)
|
||||||
|
Loading…
Reference in New Issue
Block a user