@@ -98,10 +98,8 @@ GNEPythonToolDialog::GNEPythonToolDialog(GNEApplicationWindow* applicationWindow
98
98
const int maximumHeight = myArgumentFrameLeft->numChildren () * GUIDesignHeight + 120 ;
99
99
// resize
100
100
resize (1024 , maximumHeight <= 768 ? maximumHeight : 768 );
101
- // show dialog
102
- GNEDialog::show (PLACEMENT_SCREEN);
103
- // refresh APP
104
- getApp ()->refresh ();
101
+ // open dialog
102
+ openModalDialog ();
105
103
}
106
104
107
105
@@ -266,29 +264,29 @@ GNEPythonToolDialog::buildArguments(bool sortByName, bool groupedByCategories) {
266
264
argumentFrame = (numInsertedArguments < halfNumArguments) ? myArgumentFrameLeft : myArgumentFrameRight;
267
265
// continue depending of type
268
266
if (option.second ->isInteger ()) {
269
- myArguments.push_back (new GNEPythonToolDialogElements::IntArgument (this , argumentFrame, option.first , option.second ));
267
+ myArguments.push_back (new GNEPythonToolDialogElements::IntArgument (this , myPythonTool, getApplicationWindow (), argumentFrame, option.first , option.second ));
270
268
} else if (option.second ->isFloat ()) {
271
- myArguments.push_back (new GNEPythonToolDialogElements::FloatArgument (this , argumentFrame, option.first , option.second ));
269
+ myArguments.push_back (new GNEPythonToolDialogElements::FloatArgument (this , myPythonTool, getApplicationWindow (), argumentFrame, option.first , option.second ));
272
270
} else if (option.second ->isBool ()) {
273
- myArguments.push_back (new GNEPythonToolDialogElements::BoolArgument (this , argumentFrame, option.first , option.second ));
271
+ myArguments.push_back (new GNEPythonToolDialogElements::BoolArgument (this , myPythonTool, getApplicationWindow (), argumentFrame, option.first , option.second ));
274
272
} else if (option.second ->isFileName ()) {
275
- myArguments.push_back (new GNEPythonToolDialogElements::FileNameArgument (this , argumentFrame, option.first , option.second ));
273
+ myArguments.push_back (new GNEPythonToolDialogElements::FileNameArgument (this , myPythonTool, getApplicationWindow (), argumentFrame, option.first , option.second ));
276
274
} else if (option.second ->isNetwork ()) {
277
- myArguments.push_back (new GNEPythonToolDialogElements::NetworkArgument (this , argumentFrame, option.first , option.second ));
275
+ myArguments.push_back (new GNEPythonToolDialogElements::NetworkArgument (this , myPythonTool, getApplicationWindow (), argumentFrame, option.first , option.second ));
278
276
} else if (option.second ->isAdditional ()) {
279
- myArguments.push_back (new GNEPythonToolDialogElements::AdditionalArgument (this , argumentFrame, option.first , option.second ));
277
+ myArguments.push_back (new GNEPythonToolDialogElements::AdditionalArgument (this , myPythonTool, getApplicationWindow (), argumentFrame, option.first , option.second ));
280
278
} else if (option.second ->isRoute ()) {
281
- myArguments.push_back (new GNEPythonToolDialogElements::RouteArgument (this , argumentFrame, option.first , option.second ));
279
+ myArguments.push_back (new GNEPythonToolDialogElements::RouteArgument (this , myPythonTool, getApplicationWindow (), argumentFrame, option.first , option.second ));
282
280
} else if (option.second ->isData ()) {
283
- myArguments.push_back (new GNEPythonToolDialogElements::DataArgument (this , argumentFrame, option.first , option.second ));
281
+ myArguments.push_back (new GNEPythonToolDialogElements::DataArgument (this , myPythonTool, getApplicationWindow (), argumentFrame, option.first , option.second ));
284
282
} else if (option.second ->isSumoConfig ()) {
285
- myArguments.push_back (new GNEPythonToolDialogElements::SumoConfigArgument (this , argumentFrame, option.first , option.second ));
283
+ myArguments.push_back (new GNEPythonToolDialogElements::SumoConfigArgument (this , myPythonTool, getApplicationWindow (), argumentFrame, option.first , option.second ));
286
284
} else if (option.second ->isEdge ()) {
287
- myArguments.push_back (new GNEPythonToolDialogElements::EdgeArgument (this , argumentFrame, option.first , option.second ));
285
+ myArguments.push_back (new GNEPythonToolDialogElements::EdgeArgument (this , myPythonTool, getApplicationWindow (), argumentFrame, option.first , option.second ));
288
286
} else if (option.second ->isEdgeVector ()) {
289
- myArguments.push_back (new GNEPythonToolDialogElements::EdgeVectorArgument (this , argumentFrame, option.first , option.second ));
287
+ myArguments.push_back (new GNEPythonToolDialogElements::EdgeVectorArgument (this , myPythonTool, getApplicationWindow (), argumentFrame, option.first , option.second ));
290
288
} else {
291
- myArguments.push_back (new GNEPythonToolDialogElements::StringArgument (this , argumentFrame, option.first , option.second ));
289
+ myArguments.push_back (new GNEPythonToolDialogElements::StringArgument (this , myPythonTool, getApplicationWindow (), argumentFrame, option.first , option.second ));
292
290
}
293
291
numInsertedArguments++;
294
292
}
0 commit comments