diff options
author | MÃ¥rten Kongstad <marten.kongstad@sonymobile.com> | 2014-11-07 10:52:17 +0100 |
---|---|---|
committer | Zoran Jovanovic <zoran.jovanovic@sonymobile.com> | 2014-11-07 16:07:42 +0100 |
commit | 30113131fb958850ef92c6a8f7f2aa2ed92a8ffe (patch) | |
tree | d6d1d9b3c5bbc4e67caaf67e7c967ebd0a4cbe0f /core/java/android/content | |
parent | 840796a3c29183a6f9bcf3d50ecae45405b63d88 (diff) | |
download | frameworks_base-30113131fb958850ef92c6a8f7f2aa2ed92a8ffe.zip frameworks_base-30113131fb958850ef92c6a8f7f2aa2ed92a8ffe.tar.gz frameworks_base-30113131fb958850ef92c6a8f7f2aa2ed92a8ffe.tar.bz2 |
RRO: reintroduce lost ResTable insert of assets
With the recent introduction of AssetManager::appendPathToResTable,
overlay packages were not properly added to the AssetManager, and once
added, were not properly inserted into the ResTable.
Bug: 17765434
Change-Id: Ie21f227c654c98730f74a687d0e16ee2b80e747e
Diffstat (limited to 'core/java/android/content')
-rw-r--r-- | core/java/android/content/res/AssetManager.java | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/core/java/android/content/res/AssetManager.java b/core/java/android/content/res/AssetManager.java index e578822..72f24d3 100644 --- a/core/java/android/content/res/AssetManager.java +++ b/core/java/android/content/res/AssetManager.java @@ -627,7 +627,21 @@ public final class AssetManager implements AutoCloseable { * * {@hide} */ - public native final int addOverlayPath(String idmapPath); + + public final int addOverlayPath(String idmapPath) { + synchronized (this) { + int res = addOverlayPathNative(idmapPath); + makeStringBlocks(mStringBlocks); + return res; + } + } + + /** + * See addOverlayPath. + * + * {@hide} + */ + public native final int addOverlayPathNative(String idmapPath); /** * Add multiple sets of assets to the asset manager at once. See |