docs update

This commit is contained in:
ingvar1995 2016-03-30 21:05:21 +03:00
parent 9696615caf
commit 420c4b943a
5 changed files with 13 additions and 6 deletions

3
.gitignore vendored
View File

@ -12,3 +12,6 @@ src/libs
*.iml
*.so
*.log
src/build
src/dist
*.spec

Binary file not shown.

View File

@ -48,7 +48,6 @@ class FileTransfer(QtCore.QObject):
def cancel(self):
self.send_control(TOX_FILE_CONTROL['CANCEL'])
if hasattr(self, '_file'):
print 'closing'
self._file.close()
self._state_changed.signal.emit(self.state, self._done / self._size)
@ -65,10 +64,6 @@ class FileTransfer(QtCore.QObject):
def get_file_id(self):
return self._tox.file_get_file_id(self._friend_number, self._file_number)
def file_seek(self):
# TODO implement or not implement
pass
# -----------------------------------------------------------------------------------------------------------------
# Send file
# -----------------------------------------------------------------------------------------------------------------

View File

@ -28,6 +28,9 @@ class Message(object):
class TextMessage(Message):
"""
Plain text or action message
"""
def __init__(self, message, owner, time, message_type):
super(TextMessage, self).__init__(message_type, owner, time)
@ -38,6 +41,9 @@ class TextMessage(Message):
class TransferMessage(Message):
"""
Message with info about file transfer
"""
def __init__(self, owner, time, status, size, name, friend_number, file_number):
super(TransferMessage, self).__init__(MESSAGE_TYPE['FILE_TRANSFER'], owner, time)
@ -66,6 +72,9 @@ class TransferMessage(Message):
class InlineImage(Message):
"""
Inline image
"""
def __init__(self, owner, time, data):
super(InlineImage, self).__init__(MESSAGE_TYPE['INLINE'], owner, time)

View File

@ -7,7 +7,7 @@ program_version = '0.0.3'
def log(data):
with open('logs.log', 'a') as fl:
with open(curr_directory() + '/logs.log', 'a') as fl:
fl.write(str(data) + '\n')