diff options
author | Cyrille Bagard <nocbos@gmail.com> | 2020-05-17 08:48:02 (GMT) |
---|---|---|
committer | Cyrille Bagard <nocbos@gmail.com> | 2020-05-17 08:48:02 (GMT) |
commit | f3e136eab9fd6adcb51988c9f70ca7f35552abc4 (patch) | |
tree | 69c074fec2b72637bd01142add44b130dd13a909 /plugins/pychrysalide/glibext/constants.c | |
parent | 85bd3c6c415d42c0722298cf8e4542c94a87d7f1 (diff) |
Introduced a new object of string constant sets.
Diffstat (limited to 'plugins/pychrysalide/glibext/constants.c')
-rw-r--r-- | plugins/pychrysalide/glibext/constants.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/plugins/pychrysalide/glibext/constants.c b/plugins/pychrysalide/glibext/constants.c index 680feaf..e24a6e0 100644 --- a/plugins/pychrysalide/glibext/constants.c +++ b/plugins/pychrysalide/glibext/constants.c @@ -49,8 +49,21 @@ bool define_binary_portion_constants(PyTypeObject *type) { bool result; /* Bilan à retourner */ + PyObject *strdict; /* Groupe de chaînes constantes*/ PyObject *values; /* Groupe de valeurs à établir */ + result = create_string_constants_group_to_type(type, "BinaryPortionCode", + "Selector names for the CSS rendering.", &strdict); + + if (result) result = extend_string_constants_group(strdict, "RAW", BPC_RAW); + if (result) result = extend_string_constants_group(strdict, "CODE", BPC_CODE); + if (result) result = extend_string_constants_group(strdict, "DATA", BPC_DATA); + if (result) result = extend_string_constants_group(strdict, "DATA_RO", BPC_DATA_RO); + if (result) result = extend_string_constants_group(strdict, "DISASS_ERROR", BPC_DISASS_ERROR); + + if (!result) + goto exit; + values = PyDict_New(); result = add_const_to_group(values, "NONE", PAC_NONE); |