Commit 9d8b1ca4 authored by Michael Bestas's avatar Michael Bestas
Browse files

Rebrand for Lineage SDK

Change-Id: I4f70fa62db38f29a279d8cc3082b61aa08ab48fd
parent 9754959f
......@@ -24,7 +24,7 @@ android {
}
dependencies {
compile 'org.cyanogenmod:platform.sdk:5.+'
compile 'org.lineageos:platform.sdk:8.+'
compile 'com.google.code.gson:gson:2.7'
compile 'com.squareup.retrofit2:retrofit:2.0.1'
compile 'com.squareup.retrofit2:converter-gson:2.0.1'
......
......@@ -16,9 +16,9 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.lineageos.openweathermapprovider">
<uses-permission android:name="cyanogenmod.permission.ACCESS_WEATHER_MANAGER" />
<uses-permission android:name="lineageos.permission.ACCESS_WEATHER_MANAGER" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-feature android:name="org.cyanogenmod.weather" android:required="true" />
<uses-feature android:name="org.lineageos.weather" android:required="true" />
<application
android:allowBackup="true"
......@@ -31,12 +31,12 @@
android:name="org.lineageos.openweathermapprovider.OpenWeatherMapProviderService"
android:label="@string/app_name"
android:exported="true"
android:permission="cyanogenmod.permission.BIND_WEATHER_PROVIDER_SERVICE">
android:permission="lineageos.permission.BIND_WEATHER_PROVIDER_SERVICE">
<intent-filter>
<action android:name="cyanogenmod.weatherservice.WeatherProviderService" />
<action android:name="lineageos.weatherservice.WeatherProviderService" />
</intent-filter>
<meta-data
android:name="cyanogenmod.weatherservice"
android:name="lineageos.weatherservice"
android:resource="@xml/openweathermap" />
</service>
......
......@@ -29,13 +29,13 @@ import java.util.HashMap;
import java.util.List;
import java.util.Map;
import cyanogenmod.weather.CMWeatherManager;
import cyanogenmod.weather.RequestInfo;
import cyanogenmod.weather.WeatherInfo;
import cyanogenmod.weather.WeatherLocation;
import cyanogenmod.weatherservice.ServiceRequest;
import cyanogenmod.weatherservice.ServiceRequestResult;
import cyanogenmod.weatherservice.WeatherProviderService;
import lineageos.weather.LineageWeatherManager;
import lineageos.weather.RequestInfo;
import lineageos.weather.WeatherInfo;
import lineageos.weather.WeatherLocation;
import lineageos.weatherservice.ServiceRequest;
import lineageos.weatherservice.ServiceRequestResult;
import lineageos.weatherservice.WeatherProviderService;
public class OpenWeatherMapProviderService extends WeatherProviderService
implements SharedPreferences.OnSharedPreferenceChangeListener {
......@@ -90,7 +90,7 @@ public class OpenWeatherMapProviderService extends WeatherProviderService
|| (requestType == RequestInfo.TYPE_WEATHER_BY_WEATHER_LOCATION_REQ &&
isSameWeatherLocation(requestInfo.getWeatherLocation(),
mLastWeatherLocation))) && wasRequestSubmittedTooSoon()) {
request.reject(CMWeatherManager.RequestStatus.SUBMITTED_TOO_SOON);
request.reject(LineageWeatherManager.RequestStatus.SUBMITTED_TOO_SOON);
return;
}
......
......@@ -21,7 +21,7 @@ import com.google.gson.annotations.SerializedName;
import java.io.Serializable;
import java.util.List;
import cyanogenmod.providers.WeatherContract;
import lineageos.providers.WeatherContract;
public class CurrentWeatherResponse implements Serializable {
@SerializedName("cod")
......
......@@ -23,7 +23,7 @@ import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
import cyanogenmod.providers.WeatherContract;
import lineageos.providers.WeatherContract;
public class ForecastResponse implements Serializable {
......
......@@ -32,10 +32,10 @@ import java.util.List;
import java.util.Locale;
import java.util.Set;
import cyanogenmod.providers.CMSettings;
import cyanogenmod.providers.WeatherContract;
import cyanogenmod.weather.WeatherInfo;
import cyanogenmod.weather.WeatherLocation;
import lineageos.providers.LineageSettings;
import lineageos.providers.WeatherContract;
import lineageos.weather.WeatherInfo;
import lineageos.weather.WeatherLocation;
import okhttp3.OkHttpClient;
import retrofit2.Call;
import retrofit2.Response;
......@@ -535,10 +535,10 @@ public class OpenWeatherMapService {
private int getTempUnitFromSettings() {
try {
final int tempUnit = CMSettings.Global.getInt(mContext.getContentResolver(),
CMSettings.Global.WEATHER_TEMPERATURE_UNIT);
final int tempUnit = LineageSettings.Global.getInt(mContext.getContentResolver(),
LineageSettings.Global.WEATHER_TEMPERATURE_UNIT);
return tempUnit;
} catch (CMSettings.CMSettingNotFoundException e) {
} catch (LineageSettings.LineageSettingNotFoundException e) {
//Default to metric
return WeatherContract.WeatherColumns.TempUnit.CELSIUS;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment