Commit ad15664d by Peter Eastman

Additional minor improvements to UI

parent b69bc988
......@@ -58,7 +58,6 @@ select {
}
table {
border-collapse: collapse;
border: 1pt solid black;
margin: 7pt
}
th {
......
......@@ -20,10 +20,15 @@ def loadHtmlFile(name):
file = os.path.join(htmlPath, name)
return open(file).read()
cachedImages = {}
def loadImageFile(name):
imagePath = os.path.join(os.path.dirname(__file__), 'images')
file = os.path.join(imagePath, name)
return open(file).read()
global cachedImages
if name not in cachedImages:
imagePath = os.path.join(os.path.dirname(__file__), 'images')
file = os.path.join(imagePath, name)
cachedImages[name] = open(file).read()
return cachedImages[name]
def controlsCallback(parameters, handler):
if 'newfile' in parameters:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment