diff options
author | rahulp13 | 2020-03-04 14:47:28 +0530 |
---|---|---|
committer | rahulp13 | 2020-03-04 14:47:28 +0530 |
commit | 13f3bcfda9416624cebbf5705de398e8efcad344 (patch) | |
tree | 32202454d13dfabbf6556e98987f2a9632619ea9 /src | |
parent | 19b86a949ee192652be0047da8d1389f2bdb29f6 (diff) | |
download | eSim-13f3bcfda9416624cebbf5705de398e8efcad344.tar.gz eSim-13f3bcfda9416624cebbf5705de398e8efcad344.tar.bz2 eSim-13f3bcfda9416624cebbf5705de398e8efcad344.zip |
display manual - os specific
Diffstat (limited to 'src')
-rw-r--r-- | src/browser/UserManual.py | 15 |
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() |