Skip to content

Commit

Permalink
Refactor weather package
Browse files Browse the repository at this point in the history
  • Loading branch information
Mahmud0808 committed Aug 21, 2024
1 parent cb361f0 commit 1ddcecd
Show file tree
Hide file tree
Showing 13 changed files with 32 additions and 32 deletions.
4 changes: 2 additions & 2 deletions app/proguard-rules.pro
Original file line number Diff line number Diff line change
Expand Up @@ -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*
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@
android:exported="true"
tools:ignore="ExportedContentProvider" /> <!-- Remote Preferences Provider -->
<provider
android:name=".weather.WeatherContentProvider"
android:name=".utils.weather.WeatherContentProvider"
android:authorities="com.drdisagree.iconify.weatherprovider"
android:exported="true"
tools:ignore="ExportedContentProvider" /> <!-- Weather Content Provider -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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 {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.drdisagree.iconify.weather
package com.drdisagree.iconify.utils.weather

import android.content.Context
import android.location.Geocoder
Expand All @@ -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
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.drdisagree.iconify.weather
package com.drdisagree.iconify.utils.weather

import android.Manifest
import android.content.Context
Expand All @@ -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 {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.drdisagree.iconify.weather
package com.drdisagree.iconify.utils.weather

import android.annotation.SuppressLint
import android.content.ContentProvider
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.drdisagree.iconify.weather
package com.drdisagree.iconify.utils.weather

import android.content.Context
import java.text.DecimalFormat
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.drdisagree.iconify.weather
package com.drdisagree.iconify.utils.weather

import android.Manifest
import android.annotation.SuppressLint
Expand All @@ -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
Expand Down
Original file line number Diff line number Diff line change
@@ -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
Expand Down
Original file line number Diff line number Diff line change
@@ -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
Expand Down

0 comments on commit 1ddcecd

Please sign in to comment.