Georg Lehmann : winevulkan: Support aliased constants.

Alexandre Julliard julliard at winehq.org
Tue Oct 5 15:51:42 CDT 2021


Module: wine
Branch: master
Commit: 9a65f82232eaacb3f392cafaef9440d79a1f81d9
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=9a65f82232eaacb3f392cafaef9440d79a1f81d9

Author: Georg Lehmann <dadschoorse at gmail.com>
Date:   Tue Oct  5 15:40:36 2021 +0200

winevulkan: Support aliased constants.

Signed-off-by: Georg Lehmann <dadschoorse at gmail.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/winevulkan/make_vulkan | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/dlls/winevulkan/make_vulkan b/dlls/winevulkan/make_vulkan
index 3a6bc66d32b..9e55753ca38 100755
--- a/dlls/winevulkan/make_vulkan
+++ b/dlls/winevulkan/make_vulkan
@@ -3445,11 +3445,17 @@ class VkRegistry(object):
                 enum.create_alias(enum_elem.attrib["name"], enum_elem.attrib["alias"])
 
         elif "value" in enum_elem.keys():
-            # Constants are not aliased, no need to add them here, they'll get added later on.
+            # Constant with an explicit value
             if only_aliased:
                 return
 
             self.consts.append(VkConstant(enum_elem.attrib["name"], enum_elem.attrib["value"]))
+        elif "alias" in enum_elem.keys():
+            # Aliased constant
+            if not only_aliased:
+                return
+
+            self.consts.append(VkConstant(enum_elem.attrib["name"], enum_elem.attrib["alias"]))
 
     @staticmethod
     def _require_type(type_info):




More information about the wine-cvs mailing list