Merge pull request #19944 from PatrickKaster/feature/android_modules_asset_dir
asset_dir method in Android modules' gradle config
This commit is contained in:
commit
4ac9932128
|
@ -81,6 +81,7 @@ env_base.android_gradle_plugins = []
|
||||||
env_base.android_gradle_classpath = []
|
env_base.android_gradle_classpath = []
|
||||||
env_base.android_java_dirs = []
|
env_base.android_java_dirs = []
|
||||||
env_base.android_res_dirs = []
|
env_base.android_res_dirs = []
|
||||||
|
env_base.android_asset_dirs = []
|
||||||
env_base.android_aidl_dirs = []
|
env_base.android_aidl_dirs = []
|
||||||
env_base.android_jni_dirs = []
|
env_base.android_jni_dirs = []
|
||||||
env_base.android_default_config = []
|
env_base.android_default_config = []
|
||||||
|
@ -106,6 +107,7 @@ env_base.__class__.android_add_flat_dir = methods.android_add_flat_dir
|
||||||
env_base.__class__.android_add_dependency = methods.android_add_dependency
|
env_base.__class__.android_add_dependency = methods.android_add_dependency
|
||||||
env_base.__class__.android_add_java_dir = methods.android_add_java_dir
|
env_base.__class__.android_add_java_dir = methods.android_add_java_dir
|
||||||
env_base.__class__.android_add_res_dir = methods.android_add_res_dir
|
env_base.__class__.android_add_res_dir = methods.android_add_res_dir
|
||||||
|
env_base.__class__.android_add_asset_dir = methods.android_add_asset_dir
|
||||||
env_base.__class__.android_add_aidl_dir = methods.android_add_aidl_dir
|
env_base.__class__.android_add_aidl_dir = methods.android_add_aidl_dir
|
||||||
env_base.__class__.android_add_jni_dir = methods.android_add_jni_dir
|
env_base.__class__.android_add_jni_dir = methods.android_add_jni_dir
|
||||||
env_base.__class__.android_add_default_config = methods.android_add_default_config
|
env_base.__class__.android_add_default_config = methods.android_add_default_config
|
||||||
|
|
|
@ -1382,6 +1382,11 @@ def android_add_res_dir(self, subpath):
|
||||||
if (base_path not in self.android_res_dirs):
|
if (base_path not in self.android_res_dirs):
|
||||||
self.android_res_dirs.append(base_path)
|
self.android_res_dirs.append(base_path)
|
||||||
|
|
||||||
|
def android_add_asset_dir(self, subpath):
|
||||||
|
base_path = self.Dir(".").abspath + "/modules/" + self.current_module + "/" + subpath
|
||||||
|
if (base_path not in self.android_asset_dirs):
|
||||||
|
self.android_asset_dirs.append(base_path)
|
||||||
|
|
||||||
def android_add_aidl_dir(self, subpath):
|
def android_add_aidl_dir(self, subpath):
|
||||||
base_path = self.Dir(".").abspath + "/modules/" + self.current_module + "/" + subpath
|
base_path = self.Dir(".").abspath + "/modules/" + self.current_module + "/" + subpath
|
||||||
if (base_path not in self.android_aidl_dirs):
|
if (base_path not in self.android_aidl_dirs):
|
||||||
|
|
|
@ -101,6 +101,9 @@ for x in env.android_jni_dirs:
|
||||||
|
|
||||||
gradle_asset_dirs_text = ""
|
gradle_asset_dirs_text = ""
|
||||||
|
|
||||||
|
for x in env.android_asset_dirs:
|
||||||
|
gradle_asset_dirs_text += ",'" + x.replace("\\", "/") + "'"
|
||||||
|
|
||||||
gradle_default_config_text = ""
|
gradle_default_config_text = ""
|
||||||
|
|
||||||
minSdk = 18
|
minSdk = 18
|
||||||
|
|
Loading…
Reference in New Issue