Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/cedricp/ddt4all
Browse files Browse the repository at this point in the history
  • Loading branch information
Cedric PAILLE committed Aug 23, 2017
2 parents 13a80cd + 8d28976 commit 2f6d412
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
2 changes: 1 addition & 1 deletion ddtplugins
Submodule ddtplugins updated 1 files
+0 −97 megane3_ab_reset.py
16 changes: 12 additions & 4 deletions parameters.py
Original file line number Diff line number Diff line change
Expand Up @@ -1035,10 +1035,18 @@ def clearDTC(self):

if userreply == gui.QMessageBox.Abort:
return

self.startDiagnosticSession()
# Add a little delay
time.sleep(.5)
self.sendElm(request)
response = self.sendElm(request)

self.dtcdialog.close()

if 'WRONG' in response:
options.main_window.logview.append("Clear DTC failed")
else:
options.main_window.logview.append("Clear DTC successfully done")

def readDTC(self):
if not options.simulation_mode:
Expand Down Expand Up @@ -1103,11 +1111,11 @@ def readDTC(self):
maxcount -= 1

numberofdtc = int('0x' + can_response[1], 16)
dtcdialog = gui.QDialog(None)
self.dtcdialog = gui.QDialog(None)
dtc_view = gui.QTextEdit(None)
dtc_view.setReadOnly(True)
layout = gui.QVBoxLayout()
dtcdialog.setLayout(layout)
self.dtcdialog.setLayout(layout)
clearbutton = gui.QPushButton(_("Clear ALL DTC"))
layout.addWidget(clearbutton)
layout.addWidget(dtc_view)
Expand Down Expand Up @@ -1140,7 +1148,7 @@ def readDTC(self):
can_response = can_response[shiftbytecount:]

dtc_view.setHtml(html)
dtcdialog.exec_()
self.dtcdialog.exec_()

def requestNameChanged(self, oldname, newname):
for screen_k, screen_data in self.layoutdict['screens'].iteritems():
Expand Down

0 comments on commit 2f6d412

Please sign in to comment.