handle adaptive icon (#924)

* handle adaptive icon
This commit is contained in:
superpoussin22
2019-05-16 00:08:41 -04:00
committed by Ajin Abraham
parent 6680b0f281
commit 60a0d3d2d1
+10 -4
View File
@@ -116,10 +116,16 @@ def get_icon(apk_path, res_dir):
icon_resolution = 0xFFFE - 1
icon_name = a.get_app_icon(max_dpi=icon_resolution)
if icon_name:
return {
'path': os.path.join(os.path.dirname(apk_path), icon_name),
'hidden': False
}
if '.xml' in icon_name:
return {
'path': guess_icon_path(res_dir),
'hidden': False
}
else:
return {
'path': os.path.join(os.path.dirname(apk_path), icon_name),
'hidden': False
}
return {
'path': guess_icon_path(res_dir),
'hidden': True