Skip to content

Commit

Permalink
Merge branch 'fix-control_timeline' into v4
Browse files Browse the repository at this point in the history
  • Loading branch information
UmSenhorQualquer committed Mar 6, 2019
2 parents d1b0843 + 3fecc04 commit cdd0160
Show file tree
Hide file tree
Showing 28 changed files with 1,274 additions and 1,066 deletions.
Empty file added __init__.py
Empty file.
8 changes: 5 additions & 3 deletions pyforms_gui/basewidget.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,14 +76,16 @@ def init_form(self):
"""
if not self._formLoaded:

allparams = self.controls
for key, param in allparams.items():
param.parent = self
param.name = key

if self._formset is not None:
control = self.generate_panel(self._formset)
self.layout().addWidget(control)
else:
allparams = self.controls
for key, param in allparams.items():
param.parent = self
param.name = key
self.layout().addWidget(param.form)
self._formLoaded = True

Expand Down
7 changes: 1 addition & 6 deletions pyforms_gui/controls/control_dir.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,7 @@ def init_form(self):


def click(self):
value = QFileDialog.getExistingDirectory(self.parent, self._label)

"""if _api.USED_API == _api.QT_API_PYQT5:
value = value[0]
elif _api.USED_API == _api.QT_API_PYQT4:
value = str(value)"""
value = QFileDialog.getExistingDirectory(self.parent, self._label, options=conf.PYFORMS_DIALOGS_OPTIONS)

if value and len(value)>0:
self.value = value
Expand Down

0 comments on commit cdd0160

Please sign in to comment.