Gui: clean-up Selection API
Replace the int of the 'resolve' argument of several functions with a proper enum class. * This avoids the inconsistencies in client code where often true/false is passed when an int is expected * This avoids the use of magic numbers like 0, 1, 2 or the undocumented 3
This commit is contained in:
@@ -892,10 +892,7 @@ App.Units.KinematicViscosity = App.Units.Unit(2,0,-1)
|
||||
App.Units.VacuumPermittivity = App.Units.Unit(-3,-1,4,2)
|
||||
|
||||
# Add an enum for the different unit schemes
|
||||
if sys.version_info.major < 3:
|
||||
IntEnum = object
|
||||
else:
|
||||
from enum import IntEnum
|
||||
from enum import IntEnum
|
||||
|
||||
# The values must match with that of the
|
||||
# C++ enum class UnitSystem
|
||||
|
||||
Reference in New Issue
Block a user