Skip to content

Commit

Permalink
Fixed Skins
Browse files Browse the repository at this point in the history
  • Loading branch information
XayUp committed Aug 12, 2023
1 parent 9316bfe commit 87f94f0
Showing 1 changed file with 11 additions and 6 deletions.
17 changes: 11 additions & 6 deletions app/src/main/java/com/xayup/multipad/SkinTheme.java
Original file line number Diff line number Diff line change
Expand Up @@ -68,14 +68,19 @@ private static boolean setResources(Activity context) {
} catch (Resources.NotFoundException nfr) {
bgDrawable = skinRes.getDrawable(skinRes.getIdentifier("playbg", "drawable", packageName));
}
int tmp_res_id;
setDrawables(
skinRes.getDrawable(skinRes.getIdentifier("phantom_", "drawable", packageName)), //phantomCenter
skinRes.getDrawable(skinRes.getIdentifier("phantom", "drawable", packageName)), //phantom
skinRes.getDrawable(skinRes.getIdentifier("chainled", "drawable", packageName)), //chain
skinRes.getDrawable(skinRes.getIdentifier("btn", "drawable", packageName)), //btn
skinRes.getDrawable(skinRes.getIdentifier("btn_", "drawable", packageName)), //btn_
skinRes.getDrawable(skinRes.getIdentifier("phantom_", "drawable", packageName), null), //phantomCenter
skinRes.getDrawable(skinRes.getIdentifier("phantom", "drawable", packageName), null), //phantom
skinRes.getDrawable(skinRes.getIdentifier("chainled", "drawable", packageName), null), //chain
skinRes.getDrawable(skinRes.getIdentifier("btn", "drawable", packageName), null), //btn
skinRes.getDrawable(skinRes.getIdentifier("btn_", "drawable", packageName), null), //btn_
bgDrawable, //playbg
skinRes.getDrawable(skinRes.getIdentifier("logo", "drawable", packageName))); //logo
(tmp_res_id = skinRes.getIdentifier("logo", "drawable", packageName)) == 0
? (tmp_res_id = skinRes.getIdentifier("custom_logo", "drawable", packageName)) == 0
? context.getDrawable(R.drawable.customlogo)
: skinRes.getDrawable(tmp_res_id, null)
: skinRes.getDrawable(tmp_res_id, null)); //logo
return true;
} catch (PackageManager.NameNotFoundException nnfe) {
return false;
Expand Down

0 comments on commit 87f94f0

Please sign in to comment.