Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/10se1ucgo/DisableWinTracking.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/dwt.py
diff options
context:
space:
mode:
authorNuno André Novo <nandre@ecomt.net>2019-03-10 03:26:09 +0300
committerRuined1 <ruined1@gmail.com>2019-04-26 17:36:18 +0300
commit9f1d2aa58cec76306c3dc6887e7c9c92769936fe (patch)
tree74030b84ef34363d35d394e71ee6ca9fddfa0dd1 /dwt.py
parent690da22586fe8eda2dc8e045e6e83a329a4be17c (diff)
Adds Python 3 compatibility
Diffstat (limited to 'dwt.py')
-rw-r--r--dwt.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/dwt.py b/dwt.py
index 113f212..fb195fd 100644
--- a/dwt.py
+++ b/dwt.py
@@ -21,6 +21,7 @@ import platform
import traceback
import webbrowser
from ctypes import windll
+from six import u
import wx
from wx.lib.itemspicker import ItemsPicker, IP_SORT_SELECTED, IP_SORT_CHOICES, IP_REMOVE_FROM_CHOICES
@@ -470,10 +471,10 @@ def exception_hook(error, value, trace):
def check_elevated(silent=False):
if not bool(windll.advpack.IsNTAdmin(0, None)):
if silent:
- windll.shell32.ShellExecuteW(None, u"runas", unicode(sys.executable), u"{0} -silent".format(unicode(__file__)), None, 1)
+ windll.shell32.ShellExecuteW(None, u"runas", u(sys.executable), u"{0} -silent".format(u(__file__)), None, 1)
sys.exit(1)
else:
- windll.shell32.ShellExecuteW(None, u"runas", unicode(sys.executable), unicode(__file__), None, 1)
+ windll.shell32.ShellExecuteW(None, u"runas", u(sys.executable), u(__file__), None, 1)
sys.exit(1)
def silent():