FAQ | This is a LIVE service | Changelog

Skip to content
Snippets Groups Projects
Commit ba2d9588 authored by Silas S. Brown's avatar Silas S. Brown
Browse files

Gradint update

git-svn-id: http://svn.code.sf.net/p/e-guidedog/code/ssb22/gradint@817 29193198-4895-4776-b068-10539e920549
parent d69bb419
No related branches found
No related tags found
No related merge requests found
# Gradint wrapper script for PocketPC
# shortcut
try:
if "Storage Card" in os.getcwd():
os.rename(os.getcwd()+"\\gradint-card.lnk","\\Windows\\Start Menu\\Programs\\Gradint.lnk")
os.remove(os.getcwd()+"\\gradint-internal.lnk")
else:
os.rename(os.getcwd()+"\\gradint-internal.lnk","\\Windows\\Start Menu\\Programs\\Gradint.lnk")
os.remove(os.getcwd()+"\\gradint-card.lnk")
except: pass
if not os.path.exists("\\Windows\\Start Menu\\Programs\\Gradint.lnk"):
raw_input("Failed to write to \\Windows")
raw_input("is Application Lock on? Remove and try again.")
raise SystemExit
# http://www.mobilejaw.com/articles/2009/09/removing-application-lock-on-windows-mobile-standard-devices/
# -> http://www.mobilejaw.com/content/2009/09/MobileJaw-ClearSecurity-MobiControl.cab
# Pre-compile - helps when the device is short of RAM,
# since compiling and running at the same time
# can take more RAM than doing it separately.
......@@ -17,16 +33,6 @@ if a:
try: os.remove(f) # leave the .pyc only
except: pass
# shortcut
try:
if "Storage Card" in os.getcwd():
os.rename(os.getcwd()+"\\gradint-card.lnk","\\Windows\\Start Menu\\Programs\\Gradint.lnk")
os.remove(os.getcwd()+"\\gradint-internal.lnk")
else:
os.rename(os.getcwd()+"\\gradint-internal.lnk","\\Windows\\Start Menu\\Programs\\Gradint.lnk")
os.remove(os.getcwd()+"\\gradint-card.lnk")
except: pass
def moveFiles(srcDir,destDir):
try: os.mkdir(destDir)
except: pass
......@@ -58,10 +64,14 @@ if l:
print "Installing TkInter..."
try: moveFiles("\\Storage Card\\Windows","\\Windows")
except: pass
if "Storage Card" in os.getcwd(): moveFiles(os.getcwd()+"\\Program Files","\\Storage Card\\Program Files")
else: moveFiles(os.getcwd()+"\\Program Files","\\Program Files")
# need to restart Python
raw_input("Setup successful - now run Gradint")
try:
if "Storage Card" in os.getcwd(): moveFiles(os.getcwd()+"\\Program Files","\\Storage Card\\Program Files")
else: moveFiles(os.getcwd()+"\\Program Files","\\Program Files")
# need to restart Python
raw_input("Setup successful - now run Gradint")
except:
raw_input("Failed to move Program Files")
raw_input("Please do it manually in Explorer")
raise SystemExit
# can now run
......
......@@ -684,6 +684,8 @@ GUI_translations={
"(Up)":{"zh":u"(上面)"},
"Record from %s":{"zh":u"从%s做录音","zh2":u"從%s做錄音"},
"Record from file":{"zh":u"从文件做录音","zh2":u"從文件做錄音"},
"It has been %d days since your last Gradint lesson. Please try to have one every day.":{"zh":u"你没做Gradint的课%d天了。请试试天天做。","zh2":u"你沒做Gradint的課%d天了。請試試天天做。"},
"It has been %d days since you installed Gradint and you haven't had a lesson yet. Please try to have one every day.":{"zh":u"%d天前安装了Gradint但还没做课。请试试天天做。","zh2":u"%d天前安裝了Gradint但還沒做課。請試試天天做。"},
}
# scriptVariants optionally maps language abbreviation to default script
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment