Make newer checkstyle happy
Mostly just dropping public from constructors.
This commit is contained in:
parent
4f34013885
commit
f2212e33d7
@ -147,17 +147,17 @@ public class AppDetails extends AppCompatActivity implements ProgressListener, A
|
|||||||
|
|
||||||
class AppObserver extends ContentObserver {
|
class AppObserver extends ContentObserver {
|
||||||
|
|
||||||
public AppObserver(Handler handler) {
|
AppObserver(Handler handler) {
|
||||||
super(handler);
|
super(handler);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onChange(boolean selfChange) {
|
void onChange(boolean selfChange) {
|
||||||
onChange(selfChange, null);
|
onChange(selfChange, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onChange(boolean selfChange, Uri uri) {
|
void onChange(boolean selfChange, Uri uri) {
|
||||||
onAppChanged();
|
onAppChanged();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -168,7 +168,7 @@ public class AppDetails extends AppCompatActivity implements ProgressListener, A
|
|||||||
private final LayoutInflater mInflater = (LayoutInflater) mctx.getSystemService(
|
private final LayoutInflater mInflater = (LayoutInflater) mctx.getSystemService(
|
||||||
Context.LAYOUT_INFLATER_SERVICE);
|
Context.LAYOUT_INFLATER_SERVICE);
|
||||||
|
|
||||||
public ApkListAdapter(Context context, App app) {
|
ApkListAdapter(Context context, App app) {
|
||||||
super(context, 0);
|
super(context, 0);
|
||||||
final List<Apk> apks = ApkProvider.Helper.findByApp(context, app.id);
|
final List<Apk> apks = ApkProvider.Helper.findByApp(context, app.id);
|
||||||
for (final Apk apk : apks) {
|
for (final Apk apk : apks) {
|
||||||
@ -344,7 +344,7 @@ public class AppDetails extends AppCompatActivity implements ProgressListener, A
|
|||||||
public final ApkDownloader downloader;
|
public final ApkDownloader downloader;
|
||||||
public final App app;
|
public final App app;
|
||||||
|
|
||||||
public ConfigurationChangeHelper(ApkDownloader downloader, App app) {
|
ConfigurationChangeHelper(ApkDownloader downloader, App app) {
|
||||||
this.downloader = downloader;
|
this.downloader = downloader;
|
||||||
this.app = app;
|
this.app = app;
|
||||||
}
|
}
|
||||||
|
@ -365,7 +365,7 @@ public class FDroid extends ActionBarActivity {
|
|||||||
|
|
||||||
private class AppObserver extends ContentObserver {
|
private class AppObserver extends ContentObserver {
|
||||||
|
|
||||||
public AppObserver() {
|
AppObserver() {
|
||||||
super(null);
|
super(null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -146,7 +146,7 @@ public final class PRNGFixes extends Compatibility {
|
|||||||
@SuppressWarnings("serial")
|
@SuppressWarnings("serial")
|
||||||
private static class LinuxPRNGSecureRandomProvider extends Provider {
|
private static class LinuxPRNGSecureRandomProvider extends Provider {
|
||||||
|
|
||||||
public LinuxPRNGSecureRandomProvider() {
|
LinuxPRNGSecureRandomProvider() {
|
||||||
super("LinuxPRNG",
|
super("LinuxPRNG",
|
||||||
1.0,
|
1.0,
|
||||||
"A Linux-specific random number provider that uses"
|
"A Linux-specific random number provider that uses"
|
||||||
|
@ -241,21 +241,21 @@ public class AppProvider extends FDroidProvider {
|
|||||||
|
|
||||||
private boolean naturalJoinToInstalled;
|
private boolean naturalJoinToInstalled;
|
||||||
|
|
||||||
public AppQuerySelection() {
|
AppQuerySelection() {
|
||||||
// The same as no selection, because "1" will always resolve to true when executing the SQL query.
|
// The same as no selection, because "1" will always resolve to true when executing the SQL query.
|
||||||
// e.g. "WHERE 1 AND ..." is the same as "WHERE ..."
|
// e.g. "WHERE 1 AND ..." is the same as "WHERE ..."
|
||||||
super("1");
|
super("1");
|
||||||
}
|
}
|
||||||
|
|
||||||
public AppQuerySelection(String selection) {
|
AppQuerySelection(String selection) {
|
||||||
super(selection);
|
super(selection);
|
||||||
}
|
}
|
||||||
|
|
||||||
public AppQuerySelection(String selection, String[] args) {
|
AppQuerySelection(String selection, String[] args) {
|
||||||
super(selection, args);
|
super(selection, args);
|
||||||
}
|
}
|
||||||
|
|
||||||
public AppQuerySelection(String selection, List<String> args) {
|
AppQuerySelection(String selection, List<String> args) {
|
||||||
super(selection, args);
|
super(selection, args);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -124,6 +124,7 @@ public class Repo extends ValueObject {
|
|||||||
public boolean hasBeenUpdated() {
|
public boolean hasBeenUpdated() {
|
||||||
return this.lastetag != null;
|
return this.lastetag != null;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* If we haven't run an update for this repo yet, then the name
|
* If we haven't run an update for this repo yet, then the name
|
||||||
* will be unknown, in which case we will just take a guess at an
|
* will be unknown, in which case we will just take a guess at an
|
||||||
|
@ -164,7 +164,7 @@ public final class BluetoothSwap extends SwapType {
|
|||||||
|
|
||||||
private static class NoBluetoothType extends SwapType {
|
private static class NoBluetoothType extends SwapType {
|
||||||
|
|
||||||
public NoBluetoothType(@NonNull Context context) {
|
NoBluetoothType(@NonNull Context context) {
|
||||||
super(context);
|
super(context);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -28,7 +28,7 @@ class AsyncDownloadWrapper extends Handler implements AsyncDownloader {
|
|||||||
* world about completion. Therefore, we require the listener as a
|
* world about completion. Therefore, we require the listener as a
|
||||||
* parameter to the constructor.
|
* parameter to the constructor.
|
||||||
*/
|
*/
|
||||||
public AsyncDownloadWrapper(Downloader downloader, Listener listener) {
|
AsyncDownloadWrapper(Downloader downloader, Listener listener) {
|
||||||
this.downloader = downloader;
|
this.downloader = downloader;
|
||||||
this.listener = listener;
|
this.listener = listener;
|
||||||
}
|
}
|
||||||
|
@ -213,7 +213,7 @@ public abstract class Downloader {
|
|||||||
|
|
||||||
private final InputStream toWrap;
|
private final InputStream toWrap;
|
||||||
|
|
||||||
public WrappedInputStream(InputStream toWrap) {
|
WrappedInputStream(InputStream toWrap) {
|
||||||
super();
|
super();
|
||||||
this.toWrap = toWrap;
|
this.toWrap = toWrap;
|
||||||
}
|
}
|
||||||
|
@ -105,7 +105,7 @@ public class BluetoothServer extends Thread {
|
|||||||
private final BluetoothSocket socket;
|
private final BluetoothSocket socket;
|
||||||
private final File webRoot;
|
private final File webRoot;
|
||||||
|
|
||||||
public ClientConnection(BluetoothSocket socket, File webRoot) {
|
ClientConnection(BluetoothSocket socket, File webRoot) {
|
||||||
this.socket = socket;
|
this.socket = socket;
|
||||||
this.webRoot = webRoot;
|
this.webRoot = webRoot;
|
||||||
}
|
}
|
||||||
|
@ -42,7 +42,7 @@ abstract class InstallExtension {
|
|||||||
|
|
||||||
private static final String APK_FILE_NAME = "FDroidPrivileged.apk";
|
private static final String APK_FILE_NAME = "FDroidPrivileged.apk";
|
||||||
|
|
||||||
public InstallExtension(final Context context) {
|
InstallExtension(final Context context) {
|
||||||
this.context = context;
|
this.context = context;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -133,7 +133,7 @@ abstract class InstallExtension {
|
|||||||
|
|
||||||
private static class PreKitKatImpl extends InstallExtension {
|
private static class PreKitKatImpl extends InstallExtension {
|
||||||
|
|
||||||
public PreKitKatImpl(Context context) {
|
PreKitKatImpl(Context context) {
|
||||||
super(context);
|
super(context);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -146,7 +146,7 @@ abstract class InstallExtension {
|
|||||||
|
|
||||||
private static class KitKatToLollipopImpl extends InstallExtension {
|
private static class KitKatToLollipopImpl extends InstallExtension {
|
||||||
|
|
||||||
public KitKatToLollipopImpl(Context context) {
|
KitKatToLollipopImpl(Context context) {
|
||||||
super(context);
|
super(context);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -167,7 +167,7 @@ abstract class InstallExtension {
|
|||||||
*/
|
*/
|
||||||
private static class LollipopImpl extends InstallExtension {
|
private static class LollipopImpl extends InstallExtension {
|
||||||
|
|
||||||
public LollipopImpl(Context context) {
|
LollipopImpl(Context context) {
|
||||||
super(context);
|
super(context);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -53,7 +53,7 @@ public class TabsAdapter extends PagerAdapter
|
|||||||
static class DummyTabFactory implements TabHost.TabContentFactory {
|
static class DummyTabFactory implements TabHost.TabContentFactory {
|
||||||
private final Context mContext;
|
private final Context mContext;
|
||||||
|
|
||||||
public DummyTabFactory(Context context) {
|
DummyTabFactory(Context context) {
|
||||||
mContext = context;
|
mContext = context;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -219,7 +219,7 @@ public class ManageReposActivity extends ActionBarActivity {
|
|||||||
|
|
||||||
private AddRepoState addRepoState;
|
private AddRepoState addRepoState;
|
||||||
|
|
||||||
public AddRepo(String newAddress, String newFingerprint) {
|
AddRepo(String newAddress, String newFingerprint) {
|
||||||
|
|
||||||
context = ManageReposActivity.this;
|
context = ManageReposActivity.this;
|
||||||
|
|
||||||
|
@ -65,7 +65,7 @@ public class AvailableAppsFragment extends AppListFragment implements
|
|||||||
|
|
||||||
private final ArrayAdapter<String> adapter;
|
private final ArrayAdapter<String> adapter;
|
||||||
|
|
||||||
public CategoryObserver(ArrayAdapter<String> adapter) {
|
CategoryObserver(ArrayAdapter<String> adapter) {
|
||||||
super(null);
|
super(null);
|
||||||
this.adapter = adapter;
|
this.adapter = adapter;
|
||||||
}
|
}
|
||||||
|
@ -43,20 +43,20 @@ public class SelectAppsView extends ListView implements
|
|||||||
LoaderManager.LoaderCallbacks<Cursor>,
|
LoaderManager.LoaderCallbacks<Cursor>,
|
||||||
SearchView.OnQueryTextListener {
|
SearchView.OnQueryTextListener {
|
||||||
|
|
||||||
public SelectAppsView(Context context) {
|
SelectAppsView(Context context) {
|
||||||
super(context);
|
super(context);
|
||||||
}
|
}
|
||||||
|
|
||||||
public SelectAppsView(Context context, AttributeSet attrs) {
|
SelectAppsView(Context context, AttributeSet attrs) {
|
||||||
super(context, attrs);
|
super(context, attrs);
|
||||||
}
|
}
|
||||||
|
|
||||||
public SelectAppsView(Context context, AttributeSet attrs, int defStyleAttr) {
|
SelectAppsView(Context context, AttributeSet attrs, int defStyleAttr) {
|
||||||
super(context, attrs, defStyleAttr);
|
super(context, attrs, defStyleAttr);
|
||||||
}
|
}
|
||||||
|
|
||||||
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
|
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
|
||||||
public SelectAppsView(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
|
SelectAppsView(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
|
||||||
super(context, attrs, defStyleAttr, defStyleRes);
|
super(context, attrs, defStyleAttr, defStyleRes);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -223,7 +223,7 @@ public class SelectAppsView extends ListView implements
|
|||||||
@NonNull
|
@NonNull
|
||||||
private final ListView listView;
|
private final ListView listView;
|
||||||
|
|
||||||
public AppListAdapter(@NonNull ListView listView, @NonNull Context context, @Nullable Cursor c) {
|
AppListAdapter(@NonNull ListView listView, @NonNull Context context, @Nullable Cursor c) {
|
||||||
super(context, c, FLAG_REGISTER_CONTENT_OBSERVER);
|
super(context, c, FLAG_REGISTER_CONTENT_OBSERVER);
|
||||||
this.listView = listView;
|
this.listView = listView;
|
||||||
}
|
}
|
||||||
|
@ -70,7 +70,7 @@ public class StartSwapView extends ScrollView implements SwapWorkflowActivity.In
|
|||||||
|
|
||||||
private class PeopleNearbyAdapter extends ArrayAdapter<Peer> {
|
private class PeopleNearbyAdapter extends ArrayAdapter<Peer> {
|
||||||
|
|
||||||
public PeopleNearbyAdapter(Context context) {
|
PeopleNearbyAdapter(Context context) {
|
||||||
super(context, 0, new ArrayList<Peer>());
|
super(context, 0, new ArrayList<Peer>());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -340,7 +340,7 @@ public class SwapAppsView extends ListView implements
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
public ViewHolder() {
|
ViewHolder() {
|
||||||
// TODO: Unregister receivers correctly...
|
// TODO: Unregister receivers correctly...
|
||||||
IntentFilter apkFilter = new IntentFilter(ApkDownloader.ACTION_STATUS);
|
IntentFilter apkFilter = new IntentFilter(ApkDownloader.ACTION_STATUS);
|
||||||
LocalBroadcastManager.getInstance(getActivity()).registerReceiver(apkDownloadReceiver, apkFilter);
|
LocalBroadcastManager.getInstance(getActivity()).registerReceiver(apkDownloadReceiver, apkFilter);
|
||||||
@ -438,7 +438,7 @@ public class SwapAppsView extends ListView implements
|
|||||||
@Nullable
|
@Nullable
|
||||||
private Drawable defaultAppIcon;
|
private Drawable defaultAppIcon;
|
||||||
|
|
||||||
public AppListAdapter(@NonNull Context context, @Nullable Cursor c) {
|
AppListAdapter(@NonNull Context context, @Nullable Cursor c) {
|
||||||
super(context, c, FLAG_REGISTER_CONTENT_OBSERVER);
|
super(context, c, FLAG_REGISTER_CONTENT_OBSERVER);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -638,7 +638,7 @@ public class SwapWorkflowActivity extends AppCompatActivity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
class PrepareInitialSwapRepo extends PrepareSwapRepo {
|
class PrepareInitialSwapRepo extends PrepareSwapRepo {
|
||||||
public PrepareInitialSwapRepo() {
|
PrepareInitialSwapRepo() {
|
||||||
super(new HashSet<>(Arrays.asList(new String[] {"org.fdroid.fdroid"})));
|
super(new HashSet<>(Arrays.asList(new String[] {"org.fdroid.fdroid"})));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -664,7 +664,7 @@ public class SwapWorkflowActivity extends AppCompatActivity {
|
|||||||
@NonNull
|
@NonNull
|
||||||
protected final Context context;
|
protected final Context context;
|
||||||
|
|
||||||
public PrepareSwapRepo(@NonNull Set<String> apps) {
|
PrepareSwapRepo(@NonNull Set<String> apps) {
|
||||||
context = SwapWorkflowActivity.this;
|
context = SwapWorkflowActivity.this;
|
||||||
selectedApps = apps;
|
selectedApps = apps;
|
||||||
sharingUri = Utils.getSharingUri(FDroidApp.repo);
|
sharingUri = Utils.getSharingUri(FDroidApp.repo);
|
||||||
|
@ -95,6 +95,7 @@ public abstract class ProviderTestCase2MockContext<T extends ContentProvider> ex
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Constructor.
|
* Constructor.
|
||||||
*
|
*
|
||||||
|
@ -19,7 +19,7 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
abstract class BaseApkProviderTest extends FDroidProviderTest<ApkProvider> {
|
abstract class BaseApkProviderTest extends FDroidProviderTest<ApkProvider> {
|
||||||
|
|
||||||
public BaseApkProviderTest() {
|
BaseApkProviderTest() {
|
||||||
super(ApkProvider.class, ApkProvider.getAuthority());
|
super(ApkProvider.class, ApkProvider.getAuthority());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user