external/koush/Superuser
Revision | 2c2f827da27ee2280730cbc8a2b27593e292f2a5 (tree) |
---|---|
Time | 2019-12-24 01:57:43 |
Author | Chih-Wei Huang <cwhuang@linu...> |
Commiter | Chih-Wei Huang |
Replace android.support.v4.app by AndroidX
AndroidX is a major improvement to the original Android Support
Library, which is no longer maintained.
@@ -17,7 +17,7 @@ | ||
17 | 17 | package com.koushikdutta.superuser; |
18 | 18 | |
19 | 19 | |
20 | -import android.support.v4.app.Fragment; | |
20 | +import androidx.fragment.app.Fragment; | |
21 | 21 | |
22 | 22 | import com.koushikdutta.widgets.SupportFragment; |
23 | 23 |
@@ -35,8 +35,6 @@ public class LogFragment extends SupportFragment<LogFragmentInternal> { | ||
35 | 35 | } |
36 | 36 | |
37 | 37 | void onDelete(int id) { |
38 | -// getFragmentManager().beginTransaction().remove(this).commit(); | |
39 | -// getFragmentManager().popBackStack("content", FragmentManager.POP_BACK_STACK_INCLUSIVE); | |
40 | 38 | Fragment f = getFragmentManager().findFragmentById(id); |
41 | 39 | if (f != null && f instanceof PolicyFragment) { |
42 | 40 | PolicyFragment p = (PolicyFragment)f; |
@@ -17,13 +17,13 @@ | ||
17 | 17 | package com.koushikdutta.superuser; |
18 | 18 | |
19 | 19 | import android.annotation.SuppressLint; |
20 | -import android.app.Fragment; | |
21 | 20 | import android.content.Context; |
22 | 21 | import android.os.Bundle; |
23 | 22 | import android.view.ContextThemeWrapper; |
24 | 23 | import android.view.LayoutInflater; |
25 | 24 | import android.view.View; |
26 | 25 | import android.view.ViewGroup; |
26 | +import androidx.fragment.app.Fragment; | |
27 | 27 | |
28 | 28 | import com.koushikdutta.widgets.NativeFragment; |
29 | 29 |
@@ -59,8 +59,6 @@ public class LogNativeFragment extends NativeFragment<LogFragmentInternal> { | ||
59 | 59 | } |
60 | 60 | |
61 | 61 | void onDelete(int id) { |
62 | -// getFragmentManager().beginTransaction().remove(this).commit(); | |
63 | -// getFragmentManager().popBackStack("content", FragmentManager.POP_BACK_STACK_INCLUSIVE); | |
64 | 62 | Fragment f = getFragmentManager().findFragmentById(id); |
65 | 63 | if (f != null && f instanceof PolicyNativeFragment) { |
66 | 64 | PolicyNativeFragment p = (PolicyNativeFragment)f; |
@@ -31,7 +31,6 @@ import android.net.LocalSocketAddress; | ||
31 | 31 | import android.net.LocalSocketAddress.Namespace; |
32 | 32 | import android.os.Bundle; |
33 | 33 | import android.os.Handler; |
34 | -import android.support.v4.app.FragmentActivity; | |
35 | 34 | import android.util.Log; |
36 | 35 | import android.view.View; |
37 | 36 | import android.view.View.OnClickListener; |
@@ -44,6 +43,7 @@ import android.widget.RadioGroup; | ||
44 | 43 | import android.widget.Spinner; |
45 | 44 | import android.widget.TextView; |
46 | 45 | import android.widget.Toast; |
46 | +import androidx.fragment.app.FragmentActivity; | |
47 | 47 | |
48 | 48 | import com.koushikdutta.superuser.db.SuDatabaseHelper; |
49 | 49 | import com.koushikdutta.superuser.db.UidPolicy; |
@@ -32,7 +32,6 @@ import android.graphics.drawable.Drawable; | ||
32 | 32 | import android.os.Bundle; |
33 | 33 | import android.os.Handler; |
34 | 34 | import android.os.Message; |
35 | -import android.support.v4.app.FragmentActivity; | |
36 | 35 | import android.text.format.DateFormat; |
37 | 36 | import android.util.TypedValue; |
38 | 37 | import android.view.ContextThemeWrapper; |
@@ -42,6 +41,7 @@ import android.view.MenuItem; | ||
42 | 41 | import android.view.MenuItem.OnMenuItemClickListener; |
43 | 42 | import android.view.View; |
44 | 43 | import android.widget.ImageView; |
44 | +import androidx.fragment.app.FragmentActivity; | |
45 | 45 | |
46 | 46 | import com.koushikdutta.superuser.db.LogEntry; |
47 | 47 | import com.koushikdutta.superuser.db.SuDatabaseHelper; |
@@ -6,8 +6,8 @@ import android.content.BroadcastReceiver; | ||
6 | 6 | import android.content.Context; |
7 | 7 | import android.content.Intent; |
8 | 8 | import android.os.Handler; |
9 | -import android.support.v4.app.NotificationCompat; | |
10 | 9 | import android.util.Log; |
10 | +import androidx.core.app.NotificationCompat; | |
11 | 11 | |
12 | 12 | import com.koushikdutta.superuser.util.Settings; |
13 | 13 | import com.koushikdutta.superuser.util.SuHelper; |
@@ -21,8 +21,8 @@ import android.app.PendingIntent; | ||
21 | 21 | import android.content.BroadcastReceiver; |
22 | 22 | import android.content.Context; |
23 | 23 | import android.content.Intent; |
24 | -import android.support.v4.app.NotificationCompat; | |
25 | 24 | import android.widget.Toast; |
25 | +import androidx.core.app.NotificationCompat; | |
26 | 26 | |
27 | 27 | import com.koushikdutta.superuser.db.LogEntry; |
28 | 28 | import com.koushikdutta.superuser.db.SuperuserDatabaseHelper; |