Skip to content

Commit

Permalink
Updated locations of nearly all files
Browse files Browse the repository at this point in the history
This has been done in preparations for rewrite to kotlin and upcoming design changes.
Nothing should be broken but use caution.
  • Loading branch information
diareuse authored and topjohnwu committed Apr 12, 2019
1 parent 540000d commit a028cd5
Show file tree
Hide file tree
Showing 69 changed files with 334 additions and 329 deletions.
7 changes: 6 additions & 1 deletion app/proguard-rules.pro
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
}

# DelegateWorker
-keep,allowobfuscation class * extends com.topjohnwu.magisk.components.DelegateWorker
-keep,allowobfuscation class * extends com.topjohnwu.magisk.model.worker.DelegateWorker

# BootSigner
-keepclassmembers class com.topjohnwu.signing.BootSigner { *; }
Expand All @@ -49,3 +49,8 @@
# Excessive obfuscation
-repackageclasses 'a'
-allowaccessmodification

# QOL
-dontnote **
-dontwarn com.caverock.androidsvg.**
-dontwarn ru.noties.markwon.**
2 changes: 1 addition & 1 deletion app/src/main/java/a/b.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package a;

import com.topjohnwu.magisk.MainActivity;
import com.topjohnwu.magisk.ui.MainActivity;

public class b extends MainActivity {
/* stub */
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/java/a/c.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package a;

import com.topjohnwu.magisk.SplashActivity;
import com.topjohnwu.magisk.ui.SplashActivity;

public class c extends SplashActivity {
/* stub */
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/java/a/f.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package a;

import com.topjohnwu.magisk.FlashActivity;
import com.topjohnwu.magisk.ui.flash.FlashActivity;

public class f extends FlashActivity {
/* stub */
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/java/a/g.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import android.content.Context;

import com.topjohnwu.magisk.components.UpdateCheckService;
import com.topjohnwu.magisk.model.update.UpdateCheckService;

import androidx.annotation.NonNull;
import androidx.work.WorkerParameters;
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/java/a/h.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package a;

import com.topjohnwu.magisk.components.GeneralReceiver;
import com.topjohnwu.magisk.model.receiver.GeneralReceiver;

public class h extends GeneralReceiver {
/* stub */
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/java/a/j.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package a;

import com.topjohnwu.magisk.components.DownloadModuleService;
import com.topjohnwu.magisk.model.download.DownloadModuleService;

public class j extends DownloadModuleService {
/* stub */
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/java/a/m.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package a;

import com.topjohnwu.magisk.SuRequestActivity;
import com.topjohnwu.magisk.ui.surequest.SuRequestActivity;

public class m extends SuRequestActivity {
/* stub */
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/java/a/w.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import android.content.Context;

import com.topjohnwu.magisk.components.DelegateWorker;
import com.topjohnwu.magisk.model.worker.DelegateWorker;

import java.lang.reflect.ParameterizedType;

Expand Down
14 changes: 7 additions & 7 deletions app/src/main/java/com/topjohnwu/magisk/App.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,20 @@
import android.os.Bundle;
import android.preference.PreferenceManager;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.appcompat.app.AppCompatDelegate;

import com.topjohnwu.magisk.components.BaseActivity;
import com.topjohnwu.magisk.database.MagiskDB;
import com.topjohnwu.magisk.database.RepoDatabaseHelper;
import com.topjohnwu.magisk.data.database.MagiskDB;
import com.topjohnwu.magisk.data.database.RepoDatabaseHelper;
import com.topjohnwu.magisk.ui.base.BaseActivity;
import com.topjohnwu.magisk.utils.LocaleManager;
import com.topjohnwu.magisk.utils.RootUtils;
import com.topjohnwu.net.Networking;
import com.topjohnwu.superuser.Shell;

import java.util.concurrent.ThreadPoolExecutor;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.appcompat.app.AppCompatDelegate;

public class App extends Application implements Application.ActivityLifecycleCallbacks {

public static App self;
Expand Down
10 changes: 7 additions & 3 deletions app/src/main/java/com/topjohnwu/magisk/ClassMap.java
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
package com.topjohnwu.magisk;

import com.topjohnwu.magisk.components.DownloadModuleService;
import com.topjohnwu.magisk.components.GeneralReceiver;
import com.topjohnwu.magisk.components.UpdateCheckService;
import com.topjohnwu.magisk.model.download.DownloadModuleService;
import com.topjohnwu.magisk.model.receiver.GeneralReceiver;
import com.topjohnwu.magisk.model.update.UpdateCheckService;
import com.topjohnwu.magisk.ui.MainActivity;
import com.topjohnwu.magisk.ui.SplashActivity;
import com.topjohnwu.magisk.ui.flash.FlashActivity;
import com.topjohnwu.magisk.ui.surequest.SuRequestActivity;

import java.util.HashMap;
import java.util.Map;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.topjohnwu.magisk.database;
package com.topjohnwu.magisk.data.database;

import android.content.ContentValues;
import android.content.Context;
Expand All @@ -7,8 +7,8 @@

import com.topjohnwu.magisk.Config;
import com.topjohnwu.magisk.Const;
import com.topjohnwu.magisk.container.Policy;
import com.topjohnwu.magisk.container.SuLogEntry;
import com.topjohnwu.magisk.model.entity.Policy;
import com.topjohnwu.magisk.model.entity.SuLogEntry;
import com.topjohnwu.magisk.utils.LocaleManager;
import com.topjohnwu.magisk.utils.Utils;
import com.topjohnwu.superuser.Shell;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
package com.topjohnwu.magisk.database;
package com.topjohnwu.magisk.data.database;

import android.content.Context;
import android.database.Cursor;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;

import com.topjohnwu.magisk.Config;
import com.topjohnwu.magisk.container.Repo;
import com.topjohnwu.magisk.model.entity.Repo;

import java.util.HashSet;
import java.util.Set;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.topjohnwu.magisk.adapters;
package com.topjohnwu.magisk.model.adapters;

import android.content.Context;
import android.content.pm.ApplicationInfo;
Expand All @@ -13,20 +13,14 @@
import android.widget.ImageView;
import android.widget.TextView;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.annotation.WorkerThread;
import androidx.collection.ArraySet;
import androidx.recyclerview.widget.RecyclerView;

import com.buildware.widget.indeterm.IndeterminateCheckBox;
import com.topjohnwu.magisk.App;
import com.topjohnwu.magisk.Config;
import com.topjohnwu.magisk.R;
import com.topjohnwu.magisk.uicomponents.ArrowExpandable;
import com.topjohnwu.magisk.uicomponents.Expandable;
import com.topjohnwu.magisk.utils.Event;
import com.topjohnwu.magisk.utils.Utils;
import com.topjohnwu.magisk.view.ArrowExpandable;
import com.topjohnwu.magisk.view.Expandable;
import com.topjohnwu.superuser.Shell;
import com.topjohnwu.superuser.internal.UiThreadHandler;

Expand All @@ -35,6 +29,11 @@
import java.util.List;
import java.util.Set;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.annotation.WorkerThread;
import androidx.collection.ArraySet;
import androidx.recyclerview.widget.RecyclerView;
import butterknife.BindView;
import java9.util.Comparators;
import java9.util.Lists;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.topjohnwu.magisk.adapters;
package com.topjohnwu.magisk.model.adapters;

import android.content.Context;
import android.text.TextUtils;
Expand All @@ -9,17 +9,16 @@
import android.widget.ImageView;
import android.widget.TextView;

import androidx.annotation.NonNull;
import androidx.recyclerview.widget.RecyclerView;

import com.google.android.material.snackbar.Snackbar;
import com.topjohnwu.magisk.R;
import com.topjohnwu.magisk.container.Module;
import com.topjohnwu.magisk.uicomponents.SnackbarMaker;
import com.topjohnwu.magisk.model.entity.Module;
import com.topjohnwu.magisk.view.SnackbarMaker;
import com.topjohnwu.superuser.Shell;

import java.util.List;

import androidx.annotation.NonNull;
import androidx.recyclerview.widget.RecyclerView;
import butterknife.BindView;

public class ModulesAdapter extends RecyclerView.Adapter<ModulesAdapter.ViewHolder> {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.topjohnwu.magisk.adapters;
package com.topjohnwu.magisk.model.adapters;

import android.app.Activity;
import android.content.DialogInterface;
Expand All @@ -9,24 +9,23 @@
import android.widget.ImageView;
import android.widget.TextView;

import androidx.annotation.NonNull;
import androidx.appcompat.widget.SwitchCompat;
import androidx.recyclerview.widget.RecyclerView;

import com.google.android.material.snackbar.Snackbar;
import com.topjohnwu.magisk.R;
import com.topjohnwu.magisk.container.Policy;
import com.topjohnwu.magisk.database.MagiskDB;
import com.topjohnwu.magisk.dialogs.CustomAlertDialog;
import com.topjohnwu.magisk.dialogs.FingerprintAuthDialog;
import com.topjohnwu.magisk.uicomponents.ArrowExpandable;
import com.topjohnwu.magisk.uicomponents.Expandable;
import com.topjohnwu.magisk.uicomponents.ExpandableViewHolder;
import com.topjohnwu.magisk.uicomponents.SnackbarMaker;
import com.topjohnwu.magisk.data.database.MagiskDB;
import com.topjohnwu.magisk.model.entity.Policy;
import com.topjohnwu.magisk.utils.FingerprintHelper;
import com.topjohnwu.magisk.view.ArrowExpandable;
import com.topjohnwu.magisk.view.Expandable;
import com.topjohnwu.magisk.view.ExpandableViewHolder;
import com.topjohnwu.magisk.view.SnackbarMaker;
import com.topjohnwu.magisk.view.dialogs.CustomAlertDialog;
import com.topjohnwu.magisk.view.dialogs.FingerprintAuthDialog;

import java.util.List;

import androidx.annotation.NonNull;
import androidx.appcompat.widget.SwitchCompat;
import androidx.recyclerview.widget.RecyclerView;
import butterknife.BindView;

public class PolicyAdapter extends RecyclerView.Adapter<PolicyAdapter.ViewHolder> {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.topjohnwu.magisk.adapters;
package com.topjohnwu.magisk.model.adapters;

import android.content.Context;
import android.content.Intent;
Expand All @@ -13,25 +13,24 @@
import android.widget.SearchView;
import android.widget.TextView;

import androidx.recyclerview.widget.RecyclerView;

import com.topjohnwu.magisk.App;
import com.topjohnwu.magisk.ClassMap;
import com.topjohnwu.magisk.R;
import com.topjohnwu.magisk.components.BaseActivity;
import com.topjohnwu.magisk.components.DownloadModuleService;
import com.topjohnwu.magisk.container.Module;
import com.topjohnwu.magisk.container.Repo;
import com.topjohnwu.magisk.database.RepoDatabaseHelper;
import com.topjohnwu.magisk.dialogs.CustomAlertDialog;
import com.topjohnwu.magisk.uicomponents.MarkDownWindow;
import com.topjohnwu.magisk.data.database.RepoDatabaseHelper;
import com.topjohnwu.magisk.model.download.DownloadModuleService;
import com.topjohnwu.magisk.model.entity.Module;
import com.topjohnwu.magisk.model.entity.Repo;
import com.topjohnwu.magisk.ui.base.BaseActivity;
import com.topjohnwu.magisk.utils.Event;
import com.topjohnwu.magisk.view.MarkDownWindow;
import com.topjohnwu.magisk.view.dialogs.CustomAlertDialog;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Map;

import androidx.recyclerview.widget.RecyclerView;
import butterknife.BindView;
import java9.util.stream.StreamSupport;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.topjohnwu.magisk.adapters;
package com.topjohnwu.magisk.model.adapters;

import android.view.ViewGroup;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.topjohnwu.magisk.adapters;
package com.topjohnwu.magisk.model.adapters;

import android.app.Activity;
import android.util.DisplayMetrics;
Expand All @@ -7,13 +7,13 @@
import android.view.ViewGroup;
import android.widget.TextView;

import java.util.List;

import androidx.annotation.IdRes;
import androidx.annotation.LayoutRes;
import androidx.annotation.NonNull;
import androidx.recyclerview.widget.RecyclerView;

import java.util.List;

public abstract class StringListAdapter<VH extends StringListAdapter.ViewHolder>
extends RecyclerView.Adapter<VH> {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.topjohnwu.magisk.adapters;
package com.topjohnwu.magisk.model.adapters;

import android.content.Context;
import android.view.LayoutInflater;
Expand All @@ -9,18 +9,17 @@
import android.widget.ImageView;
import android.widget.TextView;

import androidx.recyclerview.widget.RecyclerView;

import com.topjohnwu.magisk.R;
import com.topjohnwu.magisk.container.SuLogEntry;
import com.topjohnwu.magisk.database.MagiskDB;
import com.topjohnwu.magisk.uicomponents.ExpandableViewHolder;
import com.topjohnwu.magisk.data.database.MagiskDB;
import com.topjohnwu.magisk.model.entity.SuLogEntry;
import com.topjohnwu.magisk.view.ExpandableViewHolder;

import java.util.Collections;
import java.util.HashSet;
import java.util.List;
import java.util.Set;

import androidx.recyclerview.widget.RecyclerView;
import butterknife.BindView;

public class SuLogAdapter extends SectionedAdapter<SuLogAdapter.SectionHolder, SuLogAdapter.LogViewHolder> {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
package com.topjohnwu.magisk.adapters;
package com.topjohnwu.magisk.model.adapters;


import java.util.ArrayList;
import java.util.List;

import androidx.fragment.app.Fragment;
import androidx.fragment.app.FragmentManager;
import androidx.fragment.app.FragmentPagerAdapter;

import java.util.ArrayList;
import java.util.List;

public class TabFragmentAdapter extends FragmentPagerAdapter {

private List<Fragment> fragmentList;
Expand Down
Loading

0 comments on commit a028cd5

Please sign in to comment.