Skip to content

Commit f319965

Browse files
authored
Merge pull request #31 from afrinlibrary/v3_openjdk
feat: mod store, manage mods UI, landscape fix, CF mod install fix
2 parents 0144a14 + e3afd08 commit f319965

2 files changed

Lines changed: 7 additions & 16 deletions

File tree

app_pojavlauncher/src/main/java/net/kdt/pojavlaunch/fragments/ModsSearchFragment.java

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
import android.graphics.Color;
66
import android.os.Bundle;
77
import android.util.Log;
8-
import android.view.ContextThemeWrapper;
8+
import android.widget.Toast;
99
import android.view.View;
1010
import android.widget.Button;
1111
import android.widget.EditText;
@@ -268,16 +268,11 @@ public void handleInstallation(Context context, ModDetail modDetail, int selecte
268268
try {
269269
DownloadUtils.downloadFile(url, destFile);
270270
ProgressLayout.clearProgress(ProgressLayout.INSTALL_MODPACK);
271-
Tools.runOnUiThread(() -> {
272-
// context here is getApplicationContext() from ModItemAdapter —
273-
// must wrap with AppTheme or AlertDialog crashes on Android 9
274-
Context themedCtx = new ContextThemeWrapper(context, R.style.AppTheme);
275-
new AlertDialog.Builder(themedCtx)
276-
.setTitle(modDetail.title)
277-
.setMessage(context.getString(R.string.mod_install_success, finalFileName))
278-
.setPositiveButton(android.R.string.ok, null)
279-
.show();
280-
});
271+
Tools.runOnUiThread(() ->
272+
Toast.makeText(context,
273+
context.getString(R.string.mod_install_success, finalFileName),
274+
Toast.LENGTH_LONG).show()
275+
);
281276
} catch (Exception e) {
282277
ProgressLayout.clearProgress(ProgressLayout.INSTALL_MODPACK);
283278
Tools.showErrorRemote(context, R.string.modpack_install_download_failed, e);

app_pojavlauncher/src/main/res/drawable/ic_folder_managed.xml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,9 @@
44
android:height="24dp"
55
android:viewportWidth="960"
66
android:viewportHeight="960">
7-
<!--
8-
Material Symbols SVG uses viewBox="0 -960 960 960" (Y: -960..0).
9-
Android viewport is 0..960, so we translateY +960 to align coordinates.
10-
-->
117
<group android:translateY="960">
128
<path
13-
android:fillColor="?android:attr/textColorPrimary"
9+
android:fillColor="#FFCC80"
1410
android:pathData="m680-80-12-60q-12-5-22.5-10.5T624-164l-58 18-40-68 46-40q-2-12-2-26t2-26l-46-40 40-68 58 18q11-8 21.5-13.5T668-420l12-60h80l12 60q12 5 22.5 10.5T816-396l58-18 40 68-46 40q2 12 2 26t-2 26l46 40-40 68-58-18q-11 8-21.5 13.5T772-140l-12 60h-80Zm96.5-143.5Q800-247 800-280t-23.5-56.5Q753-360 720-360t-56.5 23.5Q640-313 640-280t23.5 56.5Q687-200 720-200t56.5-23.5ZM160-240v-480 172-12 320Zm0 80q-33 0-56.5-23.5T80-240v-480q0-33 23.5-56.5T160-800h240l80 80h320q33 0 56.5 23.5T880-640v131q-18-13-38-22.5T800-548v-92H447l-80-80H160v480h283q3 21 9.5 41t15.5 39H160Z" />
1511
</group>
1612
</vector>

0 commit comments

Comments
 (0)