Allow string type when fabricating FRROs
This includes all of the work of passing the string all the way down to
the native code but then does nothing with it. Storing and retrieving of
it will be in follow up changes.
Test: Manual
Bug: 232940948
Change-Id: Ie00cc23680a0132588744991bf829afad6ba336f
diff --git a/cmds/idmap2/idmap2d/Idmap2Service.cpp b/cmds/idmap2/idmap2d/Idmap2Service.cpp
index 1b2d905..073d987 100644
--- a/cmds/idmap2/idmap2d/Idmap2Service.cpp
+++ b/cmds/idmap2/idmap2d/Idmap2Service.cpp
@@ -234,7 +234,11 @@
}
for (const auto& res : overlay.entries) {
- builder.SetResourceValue(res.resourceName, res.dataType, res.data);
+ if (res.dataType == Res_value::TYPE_STRING) {
+ builder.SetResourceValue(res.resourceName, res.dataType, res.stringData.value());
+ } else {
+ builder.SetResourceValue(res.resourceName, res.dataType, res.data);
+ }
}
// Generate the file path of the fabricated overlay and ensure it does not collide with an