diff --git a/app/build.gradle b/app/build.gradle index 8704501f2..1ac0a3f09 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -1,5 +1,4 @@ apply plugin: 'com.android.application' -//apply plugin: 'android-apt' android { compileSdkVersion 24 diff --git a/app/src/main/java/com/topjohnwu/magisk/MagiskFragment.java b/app/src/main/java/com/topjohnwu/magisk/MagiskFragment.java index b32daaecc..0af73c1b6 100644 --- a/app/src/main/java/com/topjohnwu/magisk/MagiskFragment.java +++ b/app/src/main/java/com/topjohnwu/magisk/MagiskFragment.java @@ -2,25 +2,20 @@ package com.topjohnwu.magisk; import android.Manifest; import android.app.DownloadManager; -import android.content.BroadcastReceiver; import android.content.Context; -import android.content.DialogInterface; import android.content.Intent; import android.content.IntentFilter; import android.content.pm.PackageManager; -import android.database.Cursor; import android.net.Uri; import android.os.AsyncTask; import android.os.Bundle; import android.os.Environment; -import android.support.annotation.NonNull; import android.support.annotation.Nullable; import android.support.v4.app.ActivityCompat; import android.support.v4.app.Fragment; import android.support.v4.content.FileProvider; import android.support.v7.app.AlertDialog; import android.text.Html; -import android.text.TextUtils; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; @@ -29,8 +24,11 @@ import android.widget.ProgressBar; import android.widget.TextView; import android.widget.Toast; -import com.topjohnwu.magisk.utils.DownloadReceiver; +import com.topjohnwu.magisk.receivers.ApkReceiver; +import com.topjohnwu.magisk.receivers.DownloadReceiver; +import com.topjohnwu.magisk.receivers.ZipReceiver; import com.topjohnwu.magisk.utils.Shell; +import com.topjohnwu.magisk.utils.Utils; import org.json.JSONException; import org.json.JSONObject; @@ -39,7 +37,6 @@ import java.io.BufferedReader; import java.io.File; import java.io.IOException; import java.io.InputStreamReader; -import java.lang.reflect.Method; import java.net.HttpURLConnection; import java.net.URL; import java.util.List; @@ -79,10 +76,9 @@ public class MagiskFragment extends Fragment { int statusOK = R.drawable.ic_check_circle; int statusUnknown = R.drawable.ic_help; - private String mLastLink; + private String mLastLink, mLastFile; private boolean mLastIsApp; private List version; - private long apkID, zipID; @Nullable @Override @@ -96,103 +92,38 @@ public class MagiskFragment extends Fragment { return v; } - @Override - public void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) { - super.onRequestPermissionsResult(requestCode, permissions, grantResults); - - if (requestCode == 0 && grantResults[0] == PackageManager.PERMISSION_GRANTED) { - downloadFile(); - } else { - Toast.makeText(getContext(), R.string.permissionNotGranted, Toast.LENGTH_LONG).show(); - } - } - - private void setupCardView(final boolean app, final String versionCode, final String link, String changelog) { - View clickView; - if (app) { - clickView = appUpdateView; - appCheckUpdatesContainer.setBackgroundColor(blue500); - appCheckUpdatesIcon.setImageResource(R.drawable.ic_file_download); - appCheckUpdatesStatus.setText(R.string.app_update_available); - } else { - clickView = magiskUpdateView; - magiskCheckUpdatesContainer.setBackgroundColor(blue500); - magiskCheckUpdatesIcon.setImageResource(R.drawable.ic_file_download); - magiskCheckUpdatesStatus.setText(R.string.magisk_update_available); - } - - String text = app ? getString(R.string.app_name) : getString(R.string.magisk); - final String msg = getString(R.string.update_available_message, text, versionCode, changelog); - + private void setListener(View clickView, DownloadReceiver receiver, String link, String msg, String file) { clickView.setOnClickListener(view -> new AlertDialog.Builder(getContext()) .setTitle(R.string.update_available) .setMessage(Html.fromHtml(msg)) .setCancelable(false) - .setPositiveButton(R.string.update, (dialogInterface, i) -> { - mLastLink = link; - mLastIsApp = app; + .setPositiveButton(R.string.download, (dialogInterface, i) -> { - if (ActivityCompat.checkSelfPermission(getContext(), Manifest.permission.WRITE_EXTERNAL_STORAGE) == PackageManager.PERMISSION_GRANTED) { - downloadFile(); - } else { - requestPermissions(new String[]{Manifest.permission.WRITE_EXTERNAL_STORAGE}, 0); + if (ActivityCompat.checkSelfPermission(getContext(), Manifest.permission.WRITE_EXTERNAL_STORAGE) != PackageManager.PERMISSION_GRANTED) { + Toast.makeText(getContext(), R.string.permissionNotGranted, Toast.LENGTH_LONG).show(); + return; } + File downloadFile, dir = new File(Environment.getExternalStorageDirectory() + "/MagiskManager"); + + downloadFile = new File(dir + "/" + file); + + if (!dir.exists()) dir.mkdir(); + + DownloadManager downloadManager = (DownloadManager) getContext().getSystemService(Context.DOWNLOAD_SERVICE); + DownloadManager.Request request = new DownloadManager.Request(Uri.parse(link)); + request.setDestinationUri(Uri.fromFile(downloadFile)); + + if (downloadFile.exists()) downloadFile.delete(); + + receiver.setDownloadID(downloadManager.enqueue(request)); + + getActivity().registerReceiver(receiver, new IntentFilter(DownloadManager.ACTION_DOWNLOAD_COMPLETE)); }) .setNegativeButton(R.string.no_thanks, null) .show()); } - private void downloadFile() { - - File downloadFile, dir = new File(Environment.getExternalStorageDirectory() + "/MagiskManager"); - DownloadReceiver receiver; - - if (mLastIsApp) { - downloadFile = new File(dir + "/MagiskManager.apk"); - - } else { - downloadFile = new File(dir + "/Magisk.zip"); - } - - if (!dir.exists()) dir.mkdir(); - - DownloadManager downloadManager = (DownloadManager) getContext().getSystemService(Context.DOWNLOAD_SERVICE); - DownloadManager.Request request = new DownloadManager.Request(Uri.parse(mLastLink)); - request.setNotificationVisibility(DownloadManager.Request.VISIBILITY_VISIBLE_NOTIFY_COMPLETED) - .setDestinationUri(Uri.fromFile(downloadFile)); - - if (downloadFile.exists()) downloadFile.delete(); - - long downloadID = downloadManager.enqueue(request); - - if (mLastIsApp) { - receiver = new DownloadReceiver(downloadID) { - @Override - public void task(File file) { - Intent install = new Intent(Intent.ACTION_INSTALL_PACKAGE); - install.setFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION); - install.setData(FileProvider.getUriForFile(context, "com.topjohnwu.magisk.provider", file)); - context.startActivity(install); - } - }; - } else { - receiver = new DownloadReceiver(downloadID) { - @Override - public void task(final File file) { - new AlertDialog.Builder(context) - .setTitle("Reboot Recovery") - .setMessage("Do you want to flash in recovery now?") - .setCancelable(false) - .setPositiveButton("Yes, flash now", (dialogInterface, i) -> Toast.makeText(context, file.getPath(), Toast.LENGTH_LONG).show()) - .setNegativeButton(R.string.no_thanks, null) - .show(); - } - }; - } - getActivity().registerReceiver(receiver, new IntentFilter(DownloadManager.ACTION_DOWNLOAD_COMPLETE)); - } - private class updateUI extends AsyncTask { @Override @@ -206,9 +137,7 @@ public class MagiskFragment extends Fragment { protected void onPostExecute(Void v) { super.onPostExecute(v); - version = Shell.sh("getprop magisk.version"); - - if (version.get(0).replaceAll("\\s", "").isEmpty()) { + if (Shell.magiskVersion == -1) { magiskStatusContainer.setBackgroundColor(grey500); magiskStatusIcon.setImageResource(statusUnknown); @@ -219,7 +148,7 @@ public class MagiskFragment extends Fragment { magiskStatusIcon.setImageResource(statusOK); magiskVersion.setTextColor(green500); - magiskVersion.setText(getString(R.string.magisk_version, version.get(0))); + magiskVersion.setText(getString(R.string.magisk_version, String.valueOf(Shell.magiskVersion))); } progressBar.setVisibility(View.GONE); @@ -270,6 +199,9 @@ public class MagiskFragment extends Fragment { return; } + magiskUpdateView.setVisibility(View.VISIBLE); + appUpdateView.setVisibility(View.VISIBLE); + try { JSONObject json = new JSONObject(result); @@ -284,26 +216,37 @@ public class MagiskFragment extends Fragment { String magiskLink = magisk.getString("link"); String magiskChangelog = magisk.getString("changelog"); - if (Integer.parseInt(appVersionCode) > BuildConfig.VERSION_CODE) { - setupCardView(true, appVersionCode, appLink, appChangelog); - } else { - appCheckUpdatesContainer.setBackgroundColor(green500); - appCheckUpdatesIcon.setImageResource(R.drawable.ic_check_circle); - appCheckUpdatesStatus.setText(getString(R.string.up_to_date, getString(R.string.app_name))); - } - - String v = version.get(0).replaceAll("\\s", ""); - - int versionInt = TextUtils.isEmpty(v) ? 0 : Integer.parseInt(v); - - if (Integer.parseInt(magiskVersionCode) > versionInt) { - setupCardView(false, magiskVersionCode, magiskLink, magiskChangelog); + //if (Integer.parseInt(magiskVersionCode) > versionInt) { + if (99 > Shell.magiskVersion) { + magiskCheckUpdatesContainer.setBackgroundColor(blue500); + magiskCheckUpdatesIcon.setImageResource(R.drawable.ic_file_download); + magiskCheckUpdatesStatus.setText(getString(R.string.magisk_update_available, magiskVersionCode)); + setListener(magiskUpdateView, new ZipReceiver(), "https://www.dropbox.com/s/dc16jf1ifhv6ef4/Magisk-v7.zip?dl=1", + getString(R.string.update_available_message, "Magisk", appVersionCode, magiskChangelog), + "latest_magisk.zip" + ); } else { magiskCheckUpdatesContainer.setBackgroundColor(green500); magiskCheckUpdatesIcon.setImageResource(R.drawable.ic_check_circle); magiskCheckUpdatesStatus.setText(getString(R.string.up_to_date, getString(R.string.magisk))); } + if (Integer.parseInt(appVersionCode) > BuildConfig.VERSION_CODE) { + appCheckUpdatesContainer.setBackgroundColor(blue500); + appCheckUpdatesIcon.setImageResource(R.drawable.ic_file_download); + appCheckUpdatesStatus.setText(getString(R.string.app_update_available, appVersionCode)); + setListener(appUpdateView, new ApkReceiver(), appLink, + getString(R.string.update_available_message, "Magisk Manager", appVersionCode, appChangelog), + "latest_manager.apk" + ); + + } else { + appCheckUpdatesContainer.setBackgroundColor(green500); + appCheckUpdatesIcon.setImageResource(R.drawable.ic_check_circle); + appCheckUpdatesStatus.setText(getString(R.string.up_to_date, getString(R.string.app_name))); + } + + } catch (JSONException ignored) { } } diff --git a/app/src/main/java/com/topjohnwu/magisk/ModulesFragment.java b/app/src/main/java/com/topjohnwu/magisk/ModulesFragment.java index 4acada288..c28d0428d 100644 --- a/app/src/main/java/com/topjohnwu/magisk/ModulesFragment.java +++ b/app/src/main/java/com/topjohnwu/magisk/ModulesFragment.java @@ -9,6 +9,8 @@ import android.support.v4.app.FragmentManager; import android.support.v4.app.FragmentPagerAdapter; import android.support.v4.view.ViewPager; import android.view.LayoutInflater; +import android.view.Menu; +import android.view.MenuInflater; import android.view.MenuItem; import android.view.View; import android.view.ViewGroup; @@ -50,10 +52,21 @@ public class ModulesFragment extends Fragment { return view; } + @Override + public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) { + super.onCreateOptionsMenu(menu, inflater); + inflater.inflate(R.menu.menu_module, menu); + } + @Override public boolean onOptionsItemSelected(MenuItem item) { switch (item.getItemId()) { case R.id.force_reload: + listModules.clear(); + listModulesCache.clear(); + progressBar.setVisibility(View.VISIBLE); + viewPager.setAdapter(new TabsAdapter(getChildFragmentManager())); + tabLayout.setupWithViewPager(viewPager); loadMod = new loadModules(); loadMod.execute(); new updateUI().execute(); diff --git a/app/src/main/java/com/topjohnwu/magisk/WelcomeActivity.java b/app/src/main/java/com/topjohnwu/magisk/WelcomeActivity.java index bf0356ec8..ed5ae920a 100644 --- a/app/src/main/java/com/topjohnwu/magisk/WelcomeActivity.java +++ b/app/src/main/java/com/topjohnwu/magisk/WelcomeActivity.java @@ -1,12 +1,17 @@ package com.topjohnwu.magisk; +import android.Manifest; import android.content.Intent; +import android.content.pm.PackageManager; +import android.os.AsyncTask; import android.os.Build; import android.os.Bundle; import android.os.Handler; import android.support.annotation.IdRes; import android.support.annotation.NonNull; import android.support.design.widget.NavigationView; +import android.support.design.widget.Snackbar; +import android.support.v4.app.ActivityCompat; import android.support.v4.app.Fragment; import android.support.v4.app.FragmentTransaction; import android.support.v4.view.GravityCompat; @@ -17,6 +22,8 @@ import android.support.v7.widget.Toolbar; import android.view.MenuItem; import android.view.View; +import com.topjohnwu.magisk.utils.Shell; + import butterknife.BindView; import butterknife.ButterKnife; @@ -43,9 +50,10 @@ public class WelcomeActivity extends AppCompatActivity implements NavigationView getWindow().getDecorView().setSystemUiVisibility(View.SYSTEM_UI_FLAG_LIGHT_STATUS_BAR); } - // Load mods in the background + // Load mods in the background, as it is time consuming ModulesFragment.loadMod = new ModulesFragment.loadModules(); ModulesFragment.loadMod.execute(); + new Popups().execute(); setSupportActionBar(toolbar); @@ -76,7 +84,11 @@ public class WelcomeActivity extends AppCompatActivity implements NavigationView navigationView.setNavigationItemSelectedListener(this); - } + if (ActivityCompat.checkSelfPermission(this, Manifest.permission.WRITE_EXTERNAL_STORAGE) != PackageManager.PERMISSION_GRANTED + && Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) { + requestPermissions(new String[]{Manifest.permission.WRITE_EXTERNAL_STORAGE}, 0); + } + } @Override protected void onSaveInstanceState(Bundle outState) { @@ -145,4 +157,19 @@ public class WelcomeActivity extends AppCompatActivity implements NavigationView } } + private class Popups extends AsyncTask { + + @Override + protected Boolean doInBackground(Void... voids) { + return Shell.rootAccess(); + } + + @Override + protected void onPostExecute(Boolean rootAccess) { + super.onPostExecute(rootAccess); + if (!rootAccess) { + Snackbar.make(findViewById(android.R.id.content), R.string.no_root_access, Snackbar.LENGTH_LONG).show(); + } + } + } } diff --git a/app/src/main/java/com/topjohnwu/magisk/receivers/ApkReceiver.java b/app/src/main/java/com/topjohnwu/magisk/receivers/ApkReceiver.java new file mode 100644 index 000000000..8a81bbac3 --- /dev/null +++ b/app/src/main/java/com/topjohnwu/magisk/receivers/ApkReceiver.java @@ -0,0 +1,17 @@ +package com.topjohnwu.magisk.receivers; + +import android.content.Intent; +import android.support.v4.content.FileProvider; + +import java.io.File; + +public class ApkReceiver extends DownloadReceiver { + + @Override + public void task(File file) { + Intent install = new Intent(Intent.ACTION_INSTALL_PACKAGE); + install.setFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION); + install.setData(FileProvider.getUriForFile(mContext, "com.topjohnwu.magisk.provider", file)); + mContext.startActivity(install); + } +} diff --git a/app/src/main/java/com/topjohnwu/magisk/utils/DownloadReceiver.java b/app/src/main/java/com/topjohnwu/magisk/receivers/DownloadReceiver.java similarity index 79% rename from app/src/main/java/com/topjohnwu/magisk/utils/DownloadReceiver.java rename to app/src/main/java/com/topjohnwu/magisk/receivers/DownloadReceiver.java index 58703ee2e..8227a4d25 100644 --- a/app/src/main/java/com/topjohnwu/magisk/utils/DownloadReceiver.java +++ b/app/src/main/java/com/topjohnwu/magisk/receivers/DownloadReceiver.java @@ -1,4 +1,4 @@ -package com.topjohnwu.magisk.utils; +package com.topjohnwu.magisk.receivers; import android.app.DownloadManager; import android.content.BroadcastReceiver; @@ -6,7 +6,7 @@ import android.content.Context; import android.content.Intent; import android.database.Cursor; import android.net.Uri; -import android.util.Log; +import android.support.v4.content.FileProvider; import android.widget.Toast; import com.topjohnwu.magisk.R; @@ -14,20 +14,16 @@ import com.topjohnwu.magisk.R; import java.io.File; /** - * Created by topjohnwu on 2016/8/27. + * Created by topjohnwu */ -public abstract class DownloadReceiver extends BroadcastReceiver{ - public Context context; - DownloadManager downloadManager; +public abstract class DownloadReceiver extends BroadcastReceiver { + public Context mContext; long downloadID; - public DownloadReceiver(long downloadID) { - this.downloadID = downloadID; - } @Override public void onReceive(Context context, Intent intent) { - this.context = context; - downloadManager = (DownloadManager) context.getSystemService(Context.DOWNLOAD_SERVICE); + mContext = context; + DownloadManager downloadManager = (DownloadManager) context.getSystemService(Context.DOWNLOAD_SERVICE); String action = intent.getAction(); if(DownloadManager.ACTION_DOWNLOAD_COMPLETE.equals(action)){ DownloadManager.Query query = new DownloadManager.Query(); @@ -50,5 +46,7 @@ public abstract class DownloadReceiver extends BroadcastReceiver{ } } + public void setDownloadID(long id) { downloadID = id;} + public abstract void task(File file); -} +} \ No newline at end of file diff --git a/app/src/main/java/com/topjohnwu/magisk/receivers/ZipReceiver.java b/app/src/main/java/com/topjohnwu/magisk/receivers/ZipReceiver.java new file mode 100644 index 000000000..bd29aaae3 --- /dev/null +++ b/app/src/main/java/com/topjohnwu/magisk/receivers/ZipReceiver.java @@ -0,0 +1,23 @@ +package com.topjohnwu.magisk.receivers; + +import android.support.v7.app.AlertDialog; + +import com.topjohnwu.magisk.R; +import com.topjohnwu.magisk.utils.Utils; + +import java.io.File; + +public class ZipReceiver extends DownloadReceiver { + @Override + public void task(File file) { + new AlertDialog.Builder(mContext) + .setTitle("Installation") + .setMessage("Do you want to install now?") + .setCancelable(false) + .setPositiveButton("Yes, flash now", (dialogInterface, i) -> { + new Utils.flashZIP(file.getPath(), mContext).execute(); + }) + .setNegativeButton(R.string.no_thanks, null) + .show(); + } +} diff --git a/app/src/main/java/com/topjohnwu/magisk/utils/Shell.java b/app/src/main/java/com/topjohnwu/magisk/utils/Shell.java index 0f47f27ff..c91c46e46 100644 --- a/app/src/main/java/com/topjohnwu/magisk/utils/Shell.java +++ b/app/src/main/java/com/topjohnwu/magisk/utils/Shell.java @@ -1,6 +1,7 @@ package com.topjohnwu.magisk.utils; import android.os.AsyncTask; +import android.util.Log; import java.io.DataOutputStream; import java.io.IOException; @@ -16,6 +17,7 @@ public class Shell { // -1 = problematic/unknown issue; 0 = not rooted; 1 = properly rooted; 2 = improperly rooted; public static int rootStatus; + public static int magiskVersion; private static Process rootShell; private static DataOutputStream rootSTDIN; @@ -28,6 +30,13 @@ public class Shell { private static void init() { + List ret = sh("getprop magisk.version"); + if (ret.get(0).replaceAll("\\s", "").isEmpty()) { + magiskVersion = -1; + } else { + magiskVersion = Integer.parseInt(ret.get(0)); + } + try { rootShell = Runtime.getRuntime().exec(sh("getprop magisk.supath").get(0) + "/su"); rootStatus = 1; @@ -47,7 +56,7 @@ public class Shell { rootSTDOUT = new StreamGobbler(rootShell.getInputStream(), rootOutList); rootSTDOUT.start(); - List ret = su("echo -BOC-", "id"); + ret = su("echo -BOC-", "id"); if (ret == null) { // Something wrong with root, not allowed? rootStatus = -1; @@ -66,19 +75,6 @@ public class Shell { } } - @Override - protected void finalize() throws Throwable { - super.finalize(); - if (rootAccess()) { - rootSTDIN.write("exit\n".getBytes("UTF-8")); - rootSTDIN.flush(); - rootShell.waitFor(); - rootSTDIN.close(); - rootSTDOUT.join(); - rootShell.destroy(); - } - } - public static boolean rootAccess() { return rootStatus > 0; } diff --git a/app/src/main/java/com/topjohnwu/magisk/utils/StreamGobbler.java b/app/src/main/java/com/topjohnwu/magisk/utils/StreamGobbler.java index 8b40775ab..ce7c9eb5b 100644 --- a/app/src/main/java/com/topjohnwu/magisk/utils/StreamGobbler.java +++ b/app/src/main/java/com/topjohnwu/magisk/utils/StreamGobbler.java @@ -1,5 +1,7 @@ package com.topjohnwu.magisk.utils; +import android.util.Log; + import java.io.BufferedReader; import java.io.IOException; import java.io.InputStream; diff --git a/app/src/main/java/com/topjohnwu/magisk/utils/Utils.java b/app/src/main/java/com/topjohnwu/magisk/utils/Utils.java index 526f03914..d8607e29f 100644 --- a/app/src/main/java/com/topjohnwu/magisk/utils/Utils.java +++ b/app/src/main/java/com/topjohnwu/magisk/utils/Utils.java @@ -1,5 +1,13 @@ package com.topjohnwu.magisk.utils; +import android.app.ProgressDialog; +import android.content.Context; +import android.os.AsyncTask; +import android.support.v7.app.AlertDialog; +import android.widget.Toast; + +import com.topjohnwu.magisk.R; + import java.util.List; public class Utils { @@ -41,6 +49,54 @@ public class Utils { return ret; } + public static class flashZIP extends AsyncTask { + private String mPath; + private ProgressDialog progress; + Context mContext; + + public flashZIP(String path, Context context) { + mPath = path; + mContext = context; + } + + @Override + protected void onPreExecute() { + super.onPreExecute(); + progress = ProgressDialog.show(mContext, "Installing", "Patching boot image for Magisk...."); + } + + @Override + protected Boolean doInBackground(Void... voids) { + if (!Shell.rootAccess()) { + return false; + } else { + Shell.su( + "rm -rf /data/tmp", + "mkdir -p /data/tmp", + "cp -af " + mPath + " /data/tmp/install.zip", + "unzip -o /data/tmp/install.zip META-INF/com/google/android/* -d /data/tmp", + "BOOTMODE=true sh /data/tmp/META-INF/com/google/android/update-binary dummy 1 /data/tmp/install.zip" + ); + return Boolean.parseBoolean(Shell.su("if [ $? -eq 0 ]; then echo true; else echo false; fi").get(0)); + } + } + + @Override + protected void onPostExecute(Boolean result) { + super.onPostExecute(result); + Shell.su("rm -rf /data/tmp"); + progress.dismiss(); + if (!result) { + Toast.makeText(mContext, "Installation failed...", Toast.LENGTH_LONG).show(); + return; + } + new AlertDialog.Builder(mContext) + .setTitle("Reboot now?") + .setPositiveButton("Yes", (dialogInterface1, i1) -> Toast.makeText(mContext, "Reboot...", Toast.LENGTH_LONG).show()) + .setNegativeButton(R.string.no_thanks, null) + .show(); + } + } } diff --git a/app/src/main/res/layout/magisk_fragment.xml b/app/src/main/res/layout/magisk_fragment.xml index 89c5ec58d..a2ec5d6c2 100644 --- a/app/src/main/res/layout/magisk_fragment.xml +++ b/app/src/main/res/layout/magisk_fragment.xml @@ -62,56 +62,6 @@ - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 74b85f90b..b7027aa74 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -58,16 +58,16 @@ No modules found Loading… Update available! - Update - A new update of %1$s is available.\nChangelog version %2$s: \n%3$s + Download + Version: v%2$s
Changelog:
%3$s]]>
No, thanks Don\'t show again Error downloading file File downloaded in Magisk directory, you can flash it in recovery Root - An update for Magisk Manager is available! - An update for Magisk is available! + Magisk Manager App v%1$s update! + Magisk v%1$s update! Cannot check for updates - You\'ve got the latest version available of %1$s + Latest version of %1$s installed diff --git a/build.gradle b/build.gradle index fa49c82eb..ec075a896 100644 --- a/build.gradle +++ b/build.gradle @@ -6,7 +6,7 @@ buildscript { mavenCentral() } dependencies { - classpath 'com.android.tools.build:gradle:2.2.0-beta1' + classpath 'com.android.tools.build:gradle:2.2.0-beta3' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files