summaryrefslogtreecommitdiff
path: root/src/configuration/Appconfig.py
diff options
context:
space:
mode:
authorrahulp132020-07-24 01:08:02 +0530
committerrahulp132020-07-24 01:08:02 +0530
commitc13e7b0f873e4857f1ce7924c0a72609df3ddca2 (patch)
tree119f73a57ec709c494b2c9e34cf309e2619008c7 /src/configuration/Appconfig.py
parent175208c2553bde875968a9bc53176b6039ba9360 (diff)
downloadeSim-c13e7b0f873e4857f1ce7924c0a72609df3ddca2.tar.gz
eSim-c13e7b0f873e4857f1ce7924c0a72609df3ddca2.tar.bz2
eSim-c13e7b0f873e4857f1ce7924c0a72609df3ddca2.zip
platform independent library and image paths, flake8 compliant
Diffstat (limited to 'src/configuration/Appconfig.py')
-rw-r--r--src/configuration/Appconfig.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/configuration/Appconfig.py b/src/configuration/Appconfig.py
index 6a10f3d7..a079d472 100644
--- a/src/configuration/Appconfig.py
+++ b/src/configuration/Appconfig.py
@@ -13,7 +13,7 @@
# MODIFIED: Rahul Paknikar, rahulp@iitb.ac.in
# ORGANIZATION: eSim team at FOSSEE, IIT Bombay.
# CREATED: Tuesday 24 February 2015
-# REVISION: Friday 14 February 2020
+# REVISION: Friday 24 July 2020
# =========================================================================
from PyQt4 import QtGui
@@ -80,7 +80,12 @@ class Appconfig(QtGui.QWidget):
# Open file and read KiCad config path
try:
- file = open('library/supportFiles/kicad_config_path.txt', 'r')
+ init_path = '../../'
+ if os.name == 'nt':
+ init_path = ''
+
+ file = open(init_path +
+ 'library/supportFiles/kicad_config_path.txt', 'r')
kicad_path = file.read().rstrip()
file.close()
except BaseException as e: