Update tracker aidl
This commit is contained in:
parent
f7e7b388cc
commit
100561be7b
3 changed files with 87 additions and 17 deletions
|
@ -73,6 +73,7 @@ import net.osmand.aidl.customization.SetWidgetsParams;
|
|||
import net.osmand.aidl.customization.OsmandSettingsParams;
|
||||
import net.osmand.aidl.customization.OsmandSettingsInfoParams;
|
||||
import net.osmand.aidl.customization.CustomizationInfoParams;
|
||||
import net.osmand.aidl.customization.ProfileSettingsParams;
|
||||
|
||||
import net.osmand.aidl.gpx.AGpxFile;
|
||||
import net.osmand.aidl.gpx.AGpxFileDetails;
|
||||
|
@ -305,6 +306,13 @@ interface IOsmAndAidlInterface {
|
|||
*/
|
||||
boolean addFavoriteGroup(in AddFavoriteGroupParams params);
|
||||
|
||||
/**
|
||||
* Remove favorite group with given name.
|
||||
*
|
||||
* @param name (String) - name of favorite group.
|
||||
*/
|
||||
boolean removeFavoriteGroup(in RemoveFavoriteGroupParams params);
|
||||
|
||||
/**
|
||||
* Update favorite group with given params.
|
||||
*
|
||||
|
@ -315,13 +323,6 @@ interface IOsmAndAidlInterface {
|
|||
* @param colorNew (String) - group color (new).
|
||||
* @param visibleNew (boolean) - group visibility (new).
|
||||
*/
|
||||
boolean removeFavoriteGroup(in RemoveFavoriteGroupParams params);
|
||||
|
||||
/**
|
||||
* Remove favorite group with given name.
|
||||
*
|
||||
* @param name (String) - name of favorite group.
|
||||
*/
|
||||
boolean updateFavoriteGroup(in UpdateFavoriteGroupParams params);
|
||||
|
||||
/**
|
||||
|
@ -338,6 +339,16 @@ interface IOsmAndAidlInterface {
|
|||
*/
|
||||
boolean addFavorite(in AddFavoriteParams params);
|
||||
|
||||
/**
|
||||
* Remove favorite at given location with given params.
|
||||
*
|
||||
* @param lat (double) - latitude.
|
||||
* @param lon (double) - longitude.
|
||||
* @param name (String) - name of favorite item.
|
||||
* @param category (String) - category of favorite item.
|
||||
*/
|
||||
boolean removeFavorite(in RemoveFavoriteParams params);
|
||||
|
||||
/**
|
||||
* Update favorite at given location with given params.
|
||||
*
|
||||
|
@ -356,16 +367,6 @@ interface IOsmAndAidlInterface {
|
|||
* "lightgreen", "green", "lightblue", "blue", "purple", "pink", "brown".
|
||||
* @param visibleNew (boolean) - should new category be visible after creation.
|
||||
*/
|
||||
boolean removeFavorite(in RemoveFavoriteParams params);
|
||||
|
||||
/**
|
||||
* Remove favorite at given location with given params.
|
||||
*
|
||||
* @param lat (double) - latitude.
|
||||
* @param lon (double) - longitude.
|
||||
* @param name (String) - name of favorite item.
|
||||
* @param category (String) - category of favorite item.
|
||||
*/
|
||||
boolean updateFavorite(in UpdateFavoriteParams params);
|
||||
|
||||
/**
|
||||
|
@ -846,4 +847,6 @@ interface IOsmAndAidlInterface {
|
|||
*
|
||||
*/
|
||||
boolean getGpxColor(inout GpxColorParams params);
|
||||
|
||||
boolean importProfile(in ProfileSettingsParams params);
|
||||
}
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
package net.osmand.aidl.customization;
|
||||
|
||||
parcelable ProfileSettingsParams;
|
|
@ -0,0 +1,64 @@
|
|||
package net.osmand.aidl.customization;
|
||||
|
||||
import android.net.Uri;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
public class ProfileSettingsParams implements Parcelable {
|
||||
|
||||
private Uri profileSettingsUri;
|
||||
private String latestChanges;
|
||||
private int version;
|
||||
|
||||
public ProfileSettingsParams(Uri profileSettingsUri, String latestChanges, int version) {
|
||||
this.profileSettingsUri = profileSettingsUri;
|
||||
this.latestChanges = latestChanges;
|
||||
this.version = version;
|
||||
}
|
||||
|
||||
public ProfileSettingsParams(Parcel in) {
|
||||
readFromParcel(in);
|
||||
}
|
||||
|
||||
public static final Creator<ProfileSettingsParams> CREATOR = new Creator<ProfileSettingsParams>() {
|
||||
@Override
|
||||
public ProfileSettingsParams createFromParcel(Parcel in) {
|
||||
return new ProfileSettingsParams(in);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ProfileSettingsParams[] newArray(int size) {
|
||||
return new ProfileSettingsParams[size];
|
||||
}
|
||||
};
|
||||
|
||||
public int getVersion() {
|
||||
return version;
|
||||
}
|
||||
|
||||
public String getLatestChanges() {
|
||||
return latestChanges;
|
||||
}
|
||||
|
||||
public Uri getProfileSettingsUri() {
|
||||
return profileSettingsUri;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeToParcel(Parcel out, int flags) {
|
||||
out.writeInt(version);
|
||||
out.writeString(latestChanges);
|
||||
out.writeParcelable(profileSettingsUri, flags);
|
||||
}
|
||||
|
||||
private void readFromParcel(Parcel in) {
|
||||
version = in.readInt();
|
||||
latestChanges = in.readString();
|
||||
profileSettingsUri = in.readParcelable(Uri.class.getClassLoader());
|
||||
}
|
||||
|
||||
@Override
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue