# HG changeset patch # User Edouard Tisserant # Date 1533716239 -7200 # Node ID 602fdd08dfab544091ed3751b17bcb12560b12d0 # Parent d9353e440887dcb7bc2cbca68fd1db043b4c217b More pylint+pep8 conformance diff -r d9353e440887 -r 602fdd08dfab Beremiz_service.py --- a/Beremiz_service.py Wed Aug 08 10:15:51 2018 +0200 +++ b/Beremiz_service.py Wed Aug 08 10:17:19 2018 +0200 @@ -30,7 +30,7 @@ import sys import getopt import threading -from threading import Thread, currentThread, Semaphore, Lock +from threading import Thread, Semaphore, Lock import traceback import __builtin__ import Pyro @@ -499,6 +499,7 @@ if havewx: wx_eval_lock = Semaphore(0) + # FIXME : beware wx mainloop is _not_ running in main thread # main_thread = currentThread() def statuschangeTskBar(status): @@ -512,6 +513,7 @@ wx_eval_lock.release() def evaluator(tocall, *args, **kwargs): + # FIXME : should implement anti-deadlock # if main_thread == currentThread(): # # avoid dead lock if called from the wx mainloop # return default_evaluator(tocall, *args, **kwargs) diff -r d9353e440887 -r 602fdd08dfab editors/CodeFileEditor.py --- a/editors/CodeFileEditor.py Wed Aug 08 10:15:51 2018 +0200 +++ b/editors/CodeFileEditor.py Wed Aug 08 10:17:19 2018 +0200 @@ -602,6 +602,7 @@ def __init__(self, table, row, col): wx.grid.GridCellTextEditor.__init__(self) + class ClassGridCellEditor(wx.grid.GridCellChoiceEditor): def __init__(self, table, row, col): wx.grid.GridCellChoiceEditor.__init__(self) @@ -610,9 +611,9 @@ class VariablesTable(CustomTable): __defaultColumnType = dict( - [(name, AllGridCellEditor) for name in - ["Name", "Initial", "Description", "OnChange", "Options"]] + - [('Class', ClassGridCellEditor), ('Type', None)]) + [(name, AllGridCellEditor) for name in + ["Name", "Initial", "Description", "OnChange", "Options"]] + + [('Class', ClassGridCellEditor), ('Type', None)]) def __init__(self, *args, **kwargs): my_columns = kwargs.pop("additional_columns")