2009-08-31 12:04:43 +00:00
|
|
|
# -*- coding: utf-8 -*-
|
2009-06-01 09:55:11 +00:00
|
|
|
# Created By: Virgil Dupras
|
2009-08-31 12:04:43 +00:00
|
|
|
# Created On: 2009-08-31
|
2009-06-01 09:55:11 +00:00
|
|
|
# $Id$
|
2010-01-01 20:11:34 +00:00
|
|
|
# Copyright 2010 Hardcoded Software (http://www.hardcoded.net)
|
2009-08-05 08:59:46 +00:00
|
|
|
#
|
|
|
|
# This software is licensed under the "HS" License as described in the "LICENSE" file,
|
|
|
|
# which should be included with this package. The terms are also available at
|
|
|
|
# http://www.hardcoded.net/licenses/hs_license
|
2009-06-01 09:55:11 +00:00
|
|
|
|
2009-10-01 11:13:58 +00:00
|
|
|
from __future__ import unicode_literals
|
|
|
|
|
|
|
|
import logging
|
|
|
|
|
2009-06-01 09:55:11 +00:00
|
|
|
import winshell
|
|
|
|
|
2009-10-14 13:29:46 +00:00
|
|
|
INITIAL_FOLDER_IN_DIALOGS = 'C:\\'
|
|
|
|
|
2009-08-31 12:04:43 +00:00
|
|
|
def recycle_file(path):
|
2009-10-01 11:13:58 +00:00
|
|
|
try:
|
|
|
|
winshell.delete_file(unicode(path), no_confirm=True, silent=True)
|
|
|
|
except winshell.x_winshell as e:
|
|
|
|
logging.warning("winshell error: %s", e)
|