global: get rid of nonnull gradle hack
Hacking things up via gradle is not right, and package-info.java poses problems with two modules, so instead we just apply it manually to every class. Remember to add this to new classes! Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
This commit is contained in:
@@ -5,6 +5,8 @@
|
||||
|
||||
package com.wireguard.android.preference;
|
||||
|
||||
import com.wireguard.util.NonNullForAll;
|
||||
|
||||
import android.Manifest;
|
||||
import android.content.Context;
|
||||
import android.content.pm.PackageManager;
|
||||
@@ -29,6 +31,7 @@ import java.io.InputStreamReader;
|
||||
* Preference implementing a button that asynchronously exports logs.
|
||||
*/
|
||||
|
||||
@NonNullForAll
|
||||
public class LogExporterPreference extends Preference {
|
||||
private static final String TAG = "WireGuard/" + LogExporterPreference.class.getSimpleName();
|
||||
|
||||
|
||||
@@ -5,6 +5,8 @@
|
||||
|
||||
package com.wireguard.android.preference;
|
||||
|
||||
import com.wireguard.util.NonNullForAll;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.system.OsConstants;
|
||||
@@ -18,6 +20,7 @@ import com.wireguard.android.util.ErrorMessages;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.preference.Preference;
|
||||
|
||||
@NonNullForAll
|
||||
public class ModuleDownloaderPreference extends Preference {
|
||||
private State state = State.INITIAL;
|
||||
|
||||
|
||||
@@ -5,6 +5,8 @@
|
||||
|
||||
package com.wireguard.android.preference;
|
||||
|
||||
import com.wireguard.util.NonNullForAll;
|
||||
|
||||
import android.content.Context;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.preference.Preference;
|
||||
@@ -19,6 +21,7 @@ import com.wireguard.android.util.ToolsInstaller;
|
||||
* result as the preference summary.
|
||||
*/
|
||||
|
||||
@NonNullForAll
|
||||
public class ToolsInstallerPreference extends Preference {
|
||||
private State state = State.INITIAL;
|
||||
|
||||
|
||||
@@ -5,6 +5,8 @@
|
||||
|
||||
package com.wireguard.android.preference;
|
||||
|
||||
import com.wireguard.util.NonNullForAll;
|
||||
|
||||
import android.content.ActivityNotFoundException;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
@@ -22,6 +24,7 @@ import com.wireguard.android.backend.WgQuickBackend;
|
||||
|
||||
import java.util.Locale;
|
||||
|
||||
@NonNullForAll
|
||||
public class VersionPreference extends Preference {
|
||||
@Nullable private String versionSummary;
|
||||
|
||||
|
||||
@@ -5,6 +5,8 @@
|
||||
|
||||
package com.wireguard.android.preference;
|
||||
|
||||
import com.wireguard.util.NonNullForAll;
|
||||
|
||||
import android.Manifest;
|
||||
import android.content.Context;
|
||||
import android.content.pm.PackageManager;
|
||||
@@ -35,6 +37,7 @@ import java9.util.concurrent.CompletableFuture;
|
||||
* Preference implementing a button that asynchronously exports config zips.
|
||||
*/
|
||||
|
||||
@NonNullForAll
|
||||
public class ZipExporterPreference extends Preference {
|
||||
private static final String TAG = "WireGuard/" + ZipExporterPreference.class.getSimpleName();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user