diff options
author | Aleksander Morgado <aleksander@aleksander.es> | 2017-09-13 19:33:34 +0200 |
---|---|---|
committer | Aleksander Morgado <aleksander@aleksander.es> | 2017-09-13 19:56:26 +0200 |
commit | 90a3a4085a164ac163be4919afe98f977d0c79fe (patch) | |
tree | 22318a160e85245855059ca5d9e4f9dd87747a4d | |
parent | ca39b63c68346f019e8aa5ecf2505e645e921532 (diff) |
qmi-codegen: avoid generating duplicated section titles
Section titles are used to generate unique ids in the documentation,
so avoid generating the same title if both a request/response and an
indication have the same message name.
Warning: multiple "IDs" for constraint linkend: libqmi-glib-PDC-Activate-Config.
Warning: multiple "IDs" for constraint linkend: libqmi-glib-PDC-Activate-Config.
Warning: multiple "IDs" for constraint linkend: libqmi-glib-PDC-Deactivate-Config.
Warning: multiple "IDs" for constraint linkend: libqmi-glib-PDC-Deactivate-Config.
Warning: multiple "IDs" for constraint linkend: libqmi-glib-PDC-Get-Config-Info.
Warning: multiple "IDs" for constraint linkend: libqmi-glib-PDC-Get-Config-Info.
Warning: multiple "IDs" for constraint linkend: libqmi-glib-PDC-Get-Selected-Config.
Warning: multiple "IDs" for constraint linkend: libqmi-glib-PDC-Get-Selected-Config.
....
-rw-r--r-- | build-aux/qmi-codegen/Client.py | 2 | ||||
-rw-r--r-- | build-aux/qmi-codegen/Message.py | 5 |
2 files changed, 5 insertions, 2 deletions
diff --git a/build-aux/qmi-codegen/Client.py b/build-aux/qmi-codegen/Client.py index 8595733..445c862 100644 --- a/build-aux/qmi-codegen/Client.py +++ b/build-aux/qmi-codegen/Client.py @@ -223,7 +223,7 @@ class Client: ' * @object: A #${camelcase}.\n' ' * @output: A #${output_camelcase}.\n' ' *\n' - ' * The ::${signal_name} signal gets emitted when a \'<link linkend=\"libqmi-glib-${service}-${message_name_dashed}.top_of_page\">${message_name}</link>\' indication is received.\n' + ' * The ::${signal_name} signal gets emitted when a \'<link linkend=\"libqmi-glib-${service}-${message_name_dashed}-indication.top_of_page\">${message_name}</link>\' indication is received.\n' ' *\n' ' * Since: ${since}\n' ' */\n' diff --git a/build-aux/qmi-codegen/Message.py b/build-aux/qmi-codegen/Message.py index 6de8fe8..e60b01a 100644 --- a/build-aux/qmi-codegen/Message.py +++ b/build-aux/qmi-codegen/Message.py @@ -446,6 +446,9 @@ class Message: 'qmi_client_${service}_${name_underscore}\n' 'qmi_client_${service}_${name_underscore}_finish\n') sections['public-methods'] += string.Template(template).substitute(translations) + translations['message_type'] = 'request/response' + elif self.type == 'Indication': + translations['message_type'] = 'indication' translations['public_types'] = sections['public-types'] translations['public_methods'] = sections['public-methods'] @@ -455,7 +458,7 @@ class Message: template = ( '<SECTION>\n' '<FILE>${hyphened}</FILE>\n' - '<TITLE>${fullname}</TITLE>\n' + '<TITLE>${fullname} ${message_type}</TITLE>\n' '${public_types}' '${public_methods}' '<SUBSECTION Private>\n' |