Skip to content

Commit

Permalink
Do not use native file dialogs, fails on Ubuntu
Browse files Browse the repository at this point in the history
  • Loading branch information
timrudge committed Apr 4, 2020
1 parent 08a7c89 commit 6031dec
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions CellModeller/GUI/PyGLCMViewer.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,9 @@ def reset(self):

@pyqtSlot()
def loadPickle(self):
qs,_ = QFileDialog.getOpenFileName(self, 'Load pickle file', '', '*.pickle')
options = QFileDialog.Options()
options |= QFileDialog.DontUseNativeDialog
qs,_ = QFileDialog.getOpenFileName(self, 'Load pickle file', '', '*.pickle', options=options)
if qs and self.getOpenCLPlatDev():
filename = str(qs)
print(filename)
Expand Down Expand Up @@ -176,7 +178,9 @@ def loadPickle(self):

@pyqtSlot()
def load(self):
qs,_ = QFileDialog.getOpenFileName(self, 'Load Python module', '', '*.py')
options = QFileDialog.Options()
options |= QFileDialog.DontUseNativeDialog
qs,_ = QFileDialog.getOpenFileName(self, 'Load Python module', '', '*.py', options=options)
if qs:
modfile = str(qs)
print(modfile)
Expand Down

0 comments on commit 6031dec

Please sign in to comment.