diff src/cagou/core/menu.py @ 98:4d8c122b86a6

menu (upload): send transfer (i.e. P2P transfer) is now working
author Goffi <goffi@goffi.org>
date Thu, 29 Dec 2016 23:47:10 +0100
parents 5d2289127bb7
children
line wrap: on
line diff
--- a/src/cagou/core/menu.py	Thu Dec 29 23:47:07 2016 +0100
+++ b/src/cagou/core/menu.py	Thu Dec 29 23:47:10 2016 +0100
@@ -230,7 +230,10 @@
             def onTransferCb(file_path, cleaning_cb=None):
                 if not external:
                     self._closeUI(wid)
-                self.callback(file_path, cleaning_cb)
+                self.callback(
+                    file_path,
+                    cleaning_cb,
+                    transfer_type = C.TRANSFER_UPLOAD if self.ids['upload_btn'].state == "down" else C.TRANSFER_SEND)
             wid = plug_info['factory'](plug_info, onTransferCb, self.cancel_cb, self.profiles)
             if not external:
                 G.host.showExtraUI(wid)