diff --git a/app/proguard-rules.pro b/app/proguard-rules.pro index f1d4d6271..dae69ac1a 100644 --- a/app/proguard-rules.pro +++ b/app/proguard-rules.pro @@ -31,8 +31,8 @@ } # Weather --keepnames class com.drdisagree.iconify.weather.** --keep class com.drdisagree.iconify.weather.** { *; } +-keepnames class com.drdisagree.iconify.utils.weather.** +-keep class com.drdisagree.iconify.utils.weather.** { *; } # EventBus -keepattributes *Annotation* diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 9521a067a..022aa2a98 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -201,7 +201,7 @@ android:exported="true" tools:ignore="ExportedContentProvider" /> diff --git a/app/src/main/java/com/drdisagree/iconify/services/WeatherScheduler.kt b/app/src/main/java/com/drdisagree/iconify/services/WeatherScheduler.kt index 852207e76..87f84d2a9 100644 --- a/app/src/main/java/com/drdisagree/iconify/services/WeatherScheduler.kt +++ b/app/src/main/java/com/drdisagree/iconify/services/WeatherScheduler.kt @@ -9,8 +9,8 @@ import androidx.work.OneTimeWorkRequest import androidx.work.PeriodicWorkRequest import androidx.work.WorkManager import com.drdisagree.iconify.BuildConfig -import com.drdisagree.iconify.weather.WeatherConfig -import com.drdisagree.iconify.weather.WeatherWork +import com.drdisagree.iconify.utils.weather.WeatherConfig +import com.drdisagree.iconify.utils.weather.WeatherWork import java.util.concurrent.TimeUnit object WeatherScheduler { diff --git a/app/src/main/java/com/drdisagree/iconify/ui/fragments/Settings.kt b/app/src/main/java/com/drdisagree/iconify/ui/fragments/Settings.kt index 3a3369360..599e5b947 100644 --- a/app/src/main/java/com/drdisagree/iconify/ui/fragments/Settings.kt +++ b/app/src/main/java/com/drdisagree/iconify/ui/fragments/Settings.kt @@ -62,7 +62,7 @@ import com.drdisagree.iconify.utils.SystemUtil.saveBootId import com.drdisagree.iconify.utils.SystemUtil.saveVersionCode import com.drdisagree.iconify.utils.helper.ImportExport.exportSettings import com.drdisagree.iconify.utils.helper.ImportExport.importSettings -import com.drdisagree.iconify.weather.WeatherConfig +import com.drdisagree.iconify.utils.weather.WeatherConfig import com.google.android.material.dialog.MaterialAlertDialogBuilder import com.topjohnwu.superuser.Shell import java.util.Date diff --git a/app/src/main/java/com/drdisagree/iconify/ui/fragments/XposedLockscreenWeather.kt b/app/src/main/java/com/drdisagree/iconify/ui/fragments/XposedLockscreenWeather.kt index 470d80ecd..4f68bf564 100644 --- a/app/src/main/java/com/drdisagree/iconify/ui/fragments/XposedLockscreenWeather.kt +++ b/app/src/main/java/com/drdisagree/iconify/ui/fragments/XposedLockscreenWeather.kt @@ -67,7 +67,7 @@ import com.drdisagree.iconify.ui.dialogs.EditTextDialog import com.drdisagree.iconify.ui.utils.ViewHelper.setHeader import com.drdisagree.iconify.utils.OmniJawsClient import com.drdisagree.iconify.utils.SystemUtil -import com.drdisagree.iconify.weather.WeatherConfig +import com.drdisagree.iconify.utils.weather.WeatherConfig import com.google.android.material.dialog.MaterialAlertDialogBuilder import com.google.android.material.slider.Slider import java.util.Locale diff --git a/app/src/main/java/com/drdisagree/iconify/utils/OmniJawsClient.kt b/app/src/main/java/com/drdisagree/iconify/utils/OmniJawsClient.kt index a4d983d4c..51b91043c 100644 --- a/app/src/main/java/com/drdisagree/iconify/utils/OmniJawsClient.kt +++ b/app/src/main/java/com/drdisagree/iconify/utils/OmniJawsClient.kt @@ -15,7 +15,7 @@ import android.text.TextUtils import android.text.format.DateFormat import android.util.Log import com.drdisagree.iconify.BuildConfig -import com.drdisagree.iconify.weather.WeatherConfig +import com.drdisagree.iconify.utils.weather.WeatherConfig import java.text.DecimalFormat import java.text.SimpleDateFormat import java.util.Date diff --git a/app/src/main/java/com/drdisagree/iconify/weather/AbstractWeatherProvider.kt b/app/src/main/java/com/drdisagree/iconify/utils/weather/AbstractWeatherProvider.kt similarity index 96% rename from app/src/main/java/com/drdisagree/iconify/weather/AbstractWeatherProvider.kt rename to app/src/main/java/com/drdisagree/iconify/utils/weather/AbstractWeatherProvider.kt index f21f4315b..feab04ad1 100644 --- a/app/src/main/java/com/drdisagree/iconify/weather/AbstractWeatherProvider.kt +++ b/app/src/main/java/com/drdisagree/iconify/utils/weather/AbstractWeatherProvider.kt @@ -1,4 +1,4 @@ -package com.drdisagree.iconify.weather +package com.drdisagree.iconify.utils.weather import android.content.Context import android.location.Geocoder @@ -7,8 +7,8 @@ import android.text.TextUtils import android.util.Log import com.drdisagree.iconify.R import com.drdisagree.iconify.utils.NetworkUtils -import com.drdisagree.iconify.weather.WeatherConfig.getLocationName -import com.drdisagree.iconify.weather.WeatherConfig.isCustomLocation +import com.drdisagree.iconify.utils.weather.WeatherConfig.getLocationName +import com.drdisagree.iconify.utils.weather.WeatherConfig.isCustomLocation import org.json.JSONObject import java.io.IOException import java.text.SimpleDateFormat diff --git a/app/src/main/java/com/drdisagree/iconify/weather/WeatherConfig.kt b/app/src/main/java/com/drdisagree/iconify/utils/weather/WeatherConfig.kt similarity index 96% rename from app/src/main/java/com/drdisagree/iconify/weather/WeatherConfig.kt rename to app/src/main/java/com/drdisagree/iconify/utils/weather/WeatherConfig.kt index 577c942cf..c21c2e635 100644 --- a/app/src/main/java/com/drdisagree/iconify/weather/WeatherConfig.kt +++ b/app/src/main/java/com/drdisagree/iconify/utils/weather/WeatherConfig.kt @@ -1,4 +1,4 @@ -package com.drdisagree.iconify.weather +package com.drdisagree.iconify.utils.weather import android.Manifest import android.content.Context @@ -15,8 +15,8 @@ import com.drdisagree.iconify.common.Preferences.WEATHER_UNITS import com.drdisagree.iconify.common.Preferences.WEATHER_UPDATE_INTERVAL import com.drdisagree.iconify.common.Resources.SHARED_XPREFERENCES import com.drdisagree.iconify.config.XPrefs.Xprefs -import com.drdisagree.iconify.weather.providers.OpenMeteoProvider -import com.drdisagree.iconify.weather.providers.OpenWeatherMapProvider +import com.drdisagree.iconify.utils.weather.providers.OpenMeteoProvider +import com.drdisagree.iconify.utils.weather.providers.OpenWeatherMapProvider object WeatherConfig { diff --git a/app/src/main/java/com/drdisagree/iconify/weather/WeatherContentProvider.kt b/app/src/main/java/com/drdisagree/iconify/utils/weather/WeatherContentProvider.kt similarity index 99% rename from app/src/main/java/com/drdisagree/iconify/weather/WeatherContentProvider.kt rename to app/src/main/java/com/drdisagree/iconify/utils/weather/WeatherContentProvider.kt index 072e0a21e..465f636c5 100644 --- a/app/src/main/java/com/drdisagree/iconify/weather/WeatherContentProvider.kt +++ b/app/src/main/java/com/drdisagree/iconify/utils/weather/WeatherContentProvider.kt @@ -1,4 +1,4 @@ -package com.drdisagree.iconify.weather +package com.drdisagree.iconify.utils.weather import android.annotation.SuppressLint import android.content.ContentProvider diff --git a/app/src/main/java/com/drdisagree/iconify/weather/WeatherInfo.kt b/app/src/main/java/com/drdisagree/iconify/utils/weather/WeatherInfo.kt similarity index 99% rename from app/src/main/java/com/drdisagree/iconify/weather/WeatherInfo.kt rename to app/src/main/java/com/drdisagree/iconify/utils/weather/WeatherInfo.kt index 4f1976062..be9237b5a 100644 --- a/app/src/main/java/com/drdisagree/iconify/weather/WeatherInfo.kt +++ b/app/src/main/java/com/drdisagree/iconify/utils/weather/WeatherInfo.kt @@ -1,4 +1,4 @@ -package com.drdisagree.iconify.weather +package com.drdisagree.iconify.utils.weather import android.content.Context import java.text.DecimalFormat diff --git a/app/src/main/java/com/drdisagree/iconify/weather/WeatherWork.kt b/app/src/main/java/com/drdisagree/iconify/utils/weather/WeatherWork.kt similarity index 94% rename from app/src/main/java/com/drdisagree/iconify/weather/WeatherWork.kt rename to app/src/main/java/com/drdisagree/iconify/utils/weather/WeatherWork.kt index 9fb0ba218..b954a6fb3 100644 --- a/app/src/main/java/com/drdisagree/iconify/weather/WeatherWork.kt +++ b/app/src/main/java/com/drdisagree/iconify/utils/weather/WeatherWork.kt @@ -1,4 +1,4 @@ -package com.drdisagree.iconify.weather +package com.drdisagree.iconify.utils.weather import android.Manifest import android.annotation.SuppressLint @@ -18,14 +18,14 @@ import com.drdisagree.iconify.utils.OmniJawsClient.Companion.EXTRA_ERROR_DISABLE import com.drdisagree.iconify.utils.OmniJawsClient.Companion.EXTRA_ERROR_LOCATION import com.drdisagree.iconify.utils.OmniJawsClient.Companion.EXTRA_ERROR_NETWORK import com.drdisagree.iconify.utils.OmniJawsClient.Companion.EXTRA_ERROR_NO_PERMISSIONS -import com.drdisagree.iconify.weather.WeatherConfig.getLocationLat -import com.drdisagree.iconify.weather.WeatherConfig.getLocationLon -import com.drdisagree.iconify.weather.WeatherConfig.getProvider -import com.drdisagree.iconify.weather.WeatherConfig.isCustomLocation -import com.drdisagree.iconify.weather.WeatherConfig.isEnabled -import com.drdisagree.iconify.weather.WeatherConfig.isMetric -import com.drdisagree.iconify.weather.WeatherConfig.setUpdateError -import com.drdisagree.iconify.weather.WeatherConfig.setWeatherData +import com.drdisagree.iconify.utils.weather.WeatherConfig.getLocationLat +import com.drdisagree.iconify.utils.weather.WeatherConfig.getLocationLon +import com.drdisagree.iconify.utils.weather.WeatherConfig.getProvider +import com.drdisagree.iconify.utils.weather.WeatherConfig.isCustomLocation +import com.drdisagree.iconify.utils.weather.WeatherConfig.isEnabled +import com.drdisagree.iconify.utils.weather.WeatherConfig.isMetric +import com.drdisagree.iconify.utils.weather.WeatherConfig.setUpdateError +import com.drdisagree.iconify.utils.weather.WeatherConfig.setWeatherData import com.google.common.util.concurrent.ListenableFuture import java.text.SimpleDateFormat import java.util.Locale diff --git a/app/src/main/java/com/drdisagree/iconify/weather/providers/OpenMeteoProvider.kt b/app/src/main/java/com/drdisagree/iconify/utils/weather/providers/OpenMeteoProvider.kt similarity index 98% rename from app/src/main/java/com/drdisagree/iconify/weather/providers/OpenMeteoProvider.kt rename to app/src/main/java/com/drdisagree/iconify/utils/weather/providers/OpenMeteoProvider.kt index a3b2fda62..57552051e 100644 --- a/app/src/main/java/com/drdisagree/iconify/weather/providers/OpenMeteoProvider.kt +++ b/app/src/main/java/com/drdisagree/iconify/utils/weather/providers/OpenMeteoProvider.kt @@ -1,10 +1,10 @@ -package com.drdisagree.iconify.weather.providers +package com.drdisagree.iconify.utils.weather.providers import android.content.Context import android.location.Location import android.util.Log -import com.drdisagree.iconify.weather.AbstractWeatherProvider -import com.drdisagree.iconify.weather.WeatherInfo +import com.drdisagree.iconify.utils.weather.AbstractWeatherProvider +import com.drdisagree.iconify.utils.weather.WeatherInfo import org.json.JSONException import org.json.JSONObject import java.text.SimpleDateFormat diff --git a/app/src/main/java/com/drdisagree/iconify/weather/providers/OpenWeatherMapProvider.kt b/app/src/main/java/com/drdisagree/iconify/utils/weather/providers/OpenWeatherMapProvider.kt similarity index 97% rename from app/src/main/java/com/drdisagree/iconify/weather/providers/OpenWeatherMapProvider.kt rename to app/src/main/java/com/drdisagree/iconify/utils/weather/providers/OpenWeatherMapProvider.kt index 8dc308493..60943b6b0 100644 --- a/app/src/main/java/com/drdisagree/iconify/weather/providers/OpenWeatherMapProvider.kt +++ b/app/src/main/java/com/drdisagree/iconify/utils/weather/providers/OpenWeatherMapProvider.kt @@ -1,12 +1,12 @@ -package com.drdisagree.iconify.weather.providers +package com.drdisagree.iconify.utils.weather.providers import android.content.Context import android.location.Location import android.text.TextUtils import android.util.Log -import com.drdisagree.iconify.weather.AbstractWeatherProvider -import com.drdisagree.iconify.weather.WeatherConfig -import com.drdisagree.iconify.weather.WeatherInfo +import com.drdisagree.iconify.utils.weather.AbstractWeatherProvider +import com.drdisagree.iconify.utils.weather.WeatherConfig +import com.drdisagree.iconify.utils.weather.WeatherInfo import org.json.JSONArray import org.json.JSONException import org.json.JSONObject