Commit 7fb9298d authored by Maxime Perrotin's avatar Maxime Perrotin
Browse files

Fix random TCs

parent 74362e90
......@@ -677,7 +677,7 @@ class asn1Editor(QTreeView):
self.backend.sendTC(self.asn1Instance)
def loadTC(self):
''' Load/Decode a TC and populate the values in the model '''
''' Load/Decode a TC and populate the values in the model XXX fix this with ctypes'''
filename = QFileDialog.getOpenFileName(self, "Open TC", ".", "ASN.1 Variable (*.tc)")[0]
if len(filename) == 0:
return
......
......@@ -703,12 +703,18 @@ class sdlHandler(QObject):
# tc with a param, use the Send button
for vals in self.param_tc_editors:
if vals['name'] == name:
argpy = vn.fromValueNotationToPySide(name, arg)
vals['editor'].updateVariable(argpy)
# Can't call click from this here, must send a signal
asn1Instance = vals['editor'].asn1Instance
ASN1_AST=self.proc.dataview
sort=ASN1_AST[vals['editor'].item['nodeTypename']].type
vn.valueNotationToCTypes(gser=arg,
dest=asn1Instance,
sort=sort,
ASN1Mod=ASN1,
ASN1_AST=ASN1_AST)
vals['editor'].updateVariable()
# Send a signal to click on the button
self.clicker.connect(vals['send_btn'].click)
self.clicker.emit()
#vals['send_btn'].click()
def random_step(self):
''' One step of random simulation '''
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment