summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorrahulp132020-03-04 14:47:28 +0530
committerrahulp132020-03-04 14:47:28 +0530
commit13f3bcfda9416624cebbf5705de398e8efcad344 (patch)
tree32202454d13dfabbf6556e98987f2a9632619ea9 /src
parent19b86a949ee192652be0047da8d1389f2bdb29f6 (diff)
downloadeSim-13f3bcfda9416624cebbf5705de398e8efcad344.tar.gz
eSim-13f3bcfda9416624cebbf5705de398e8efcad344.tar.bz2
eSim-13f3bcfda9416624cebbf5705de398e8efcad344.zip
display manual - os specific
Diffstat (limited to 'src')
-rw-r--r--src/browser/UserManual.py15
1 files changed, 11 insertions, 4 deletions
diff --git a/src/browser/UserManual.py b/src/browser/UserManual.py
index 2ab15ef6..f31af29d 100644
--- a/src/browser/UserManual.py
+++ b/src/browser/UserManual.py
@@ -1,5 +1,7 @@
from PyQt4 import QtGui
-import webbrowser
+import subprocess
+import platform
+import os
class UserManual(QtGui.QWidget):
@@ -13,9 +15,14 @@ class UserManual(QtGui.QWidget):
self.vlayout = QtGui.QVBoxLayout()
- self.url = "library/browser/User-Manual/eSim_Manual_2019_Dec_31.pdf"
- self.test = webbrowser.open(
- "library/browser/User-Manual/eSim_Manual_2019_Dec_31.pdf", new=2)
+ file = os.path.realpath(
+ 'library/browser/User-Manual/eSim_Manual_2019_Dec_31.pdf'
+ )
+
+ if 'Win' in platform.system():
+ os.startfile(file)
+ else:
+ subprocess.Popen(['xpdf.real', file], shell=False)
self.setLayout(self.vlayout)
self.show()