mirror of
https://github.com/M66B/FairEmail.git
synced 2025-12-26 23:50:58 +01:00
Show number of processors
This commit is contained in:
@@ -57,6 +57,7 @@ public class FragmentOptionsMisc extends FragmentBase implements SharedPreferenc
|
||||
private SwitchCompat swCrashReports;
|
||||
private SwitchCompat swDebug;
|
||||
|
||||
private TextView tvProcessors;
|
||||
private TextView tvMemoryClass;
|
||||
private TextView tvLastCleanup;
|
||||
private TextView tvUuid;
|
||||
@@ -93,6 +94,7 @@ public class FragmentOptionsMisc extends FragmentBase implements SharedPreferenc
|
||||
swCrashReports = view.findViewById(R.id.swCrashReports);
|
||||
swDebug = view.findViewById(R.id.swDebug);
|
||||
|
||||
tvProcessors = view.findViewById(R.id.tvProcessors);
|
||||
tvMemoryClass = view.findViewById(R.id.tvMemoryClass);
|
||||
tvLastCleanup = view.findViewById(R.id.tvLastCleanup);
|
||||
tvUuid = view.findViewById(R.id.tvUuid);
|
||||
@@ -261,6 +263,8 @@ public class FragmentOptionsMisc extends FragmentBase implements SharedPreferenc
|
||||
swCrashReports.setChecked(prefs.getBoolean("crash_reports", false));
|
||||
swDebug.setChecked(prefs.getBoolean("debug", false));
|
||||
|
||||
tvProcessors.setText(getString(R.string.title_advanced_processors, Runtime.getRuntime().availableProcessors()));
|
||||
|
||||
ActivityManager am = (ActivityManager) getContext().getSystemService(Context.ACTIVITY_SERVICE);
|
||||
int class_mb = am.getMemoryClass();
|
||||
tvMemoryClass.setText(getString(R.string.title_advanced_memory_class, class_mb + " MB"));
|
||||
|
||||
Reference in New Issue
Block a user