Fri, 20 Jun 2014 16:05:45 +0200
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
3644
a2c88b9b1d16
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
1 | # Copyright 2013 Hardcoded Software (http://www.hardcoded.net) |
a2c88b9b1d16
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
2 | |
a2c88b9b1d16
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
3 | # This software is licensed under the "BSD" License as described in the "LICENSE" file, |
a2c88b9b1d16
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
4 | # which should be included with this package. The terms are also available at |
a2c88b9b1d16
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
5 | # http://www.hardcoded.net/licenses/bsd_license |
a2c88b9b1d16
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
6 | |
a2c88b9b1d16
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
7 | import sys |
a2c88b9b1d16
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
8 | if sys.version < '3': |
a2c88b9b1d16
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
9 | text_type = unicode |
a2c88b9b1d16
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
10 | binary_type = str |
a2c88b9b1d16
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
11 | else: |
a2c88b9b1d16
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
12 | text_type = str |
a2c88b9b1d16
Added code to Project to move deleted files/directories to the recycle bin falling back to removing them (os.remove), if send2trash cannot be imported due to missing dependencies.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
13 | binary_type = bytes |