summaryrefslogtreecommitdiff
path: root/libs/androidfw
diff options
context:
space:
mode:
authorRyan Mitchell <rtmitchell@google.com>2019-09-23 09:47:02 -0700
committerRyan Mitchell <rtmitchell@google.com>2019-10-17 11:37:24 -0700
commite753ffef5499bc0150827a06d44b50abe78b36dd (patch)
tree0e32193d04435f3fd7d3c8d1cbe53581524c28d6 /libs/androidfw
parent1ec87b3c86fcec770fbfce5d182219e3263236a8 (diff)
Idmap format changes for bidirectional lookup
This change modifies the idmap file format to allow for target resources to map to arbitrary type/value combinations and to allow overlay resources to be mapped back to target resource ids so references to overlay resources can appear as references to target resources at runtime. The mappings of target resources to overlay resources and vice-versa are both encoded as sparse arrays. Instead of looking up a resource by indexing into an array that maps to the overlay resource id, the runtime will binary search over the sparse array to find the type and value that overlays the target resource. Bug: 135943783 Test: idmap2_tests Change-Id: I5d5344cdb7fe35f4f2e8d6781016299dea5d1e20
Diffstat (limited to 'libs/androidfw')
-rw-r--r--libs/androidfw/include/androidfw/ResourceTypes.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/libs/androidfw/include/androidfw/ResourceTypes.h b/libs/androidfw/include/androidfw/ResourceTypes.h
index c8ace90e6515..2efa65a009e1 100644
--- a/libs/androidfw/include/androidfw/ResourceTypes.h
+++ b/libs/androidfw/include/androidfw/ResourceTypes.h
@@ -39,7 +39,7 @@
namespace android {
constexpr const static uint32_t kIdmapMagic = 0x504D4449u;
-constexpr const static uint32_t kIdmapCurrentVersion = 0x00000001u;
+constexpr const static uint32_t kIdmapCurrentVersion = 0x00000002u;
/**
* In C++11, char16_t is defined as *at least* 16 bits. We do a lot of