Removed Parcelable from all data classes as it not needed anymore.

This commit is contained in:
Dennis Guse
2019-09-10 20:45:00 +02:00
parent 5bc773f1aa
commit f5656470a9
7 changed files with 10 additions and 341 deletions
@@ -15,9 +15,6 @@
*/
package de.dennisguse.opentracks.content;
import android.os.Parcel;
import android.os.Parcelable;
import de.dennisguse.opentracks.content.Waypoint.WaypointType;
/**
@@ -25,7 +22,7 @@ import de.dennisguse.opentracks.content.Waypoint.WaypointType;
*
* @author Sandor Dornbush
*/
public class WaypointCreationRequest implements Parcelable {
public class WaypointCreationRequest {
public final static WaypointCreationRequest DEFAULT_WAYPOINT = new WaypointCreationRequest(WaypointType.WAYPOINT, false);
@@ -33,8 +30,6 @@ public class WaypointCreationRequest implements Parcelable {
public final static WaypointCreationRequest DEFAULT_START_TRACK = new WaypointCreationRequest(WaypointType.STATISTICS, true);
public static final Creator CREATOR = new Creator();
private WaypointType type;
// true if this marker contains the track statistics
@@ -60,22 +55,6 @@ public class WaypointCreationRequest implements Parcelable {
this.photoUrl = photoUrl;
}
@Override
public int describeContents() {
return 0;
}
@Override
public void writeToParcel(Parcel parcel, int arg1) {
parcel.writeInt(type.ordinal());
parcel.writeByte((byte) (isTrackStatistics ? 1 : 0));
parcel.writeString(name);
parcel.writeString(category);
parcel.writeString(description);
parcel.writeString(iconUrl);
parcel.writeString(photoUrl);
}
public WaypointType getType() {
return type;
}
@@ -103,23 +82,4 @@ public class WaypointCreationRequest implements Parcelable {
public String getPhotoUrl() {
return photoUrl;
}
public static class Creator implements Parcelable.Creator<WaypointCreationRequest> {
@Override
public WaypointCreationRequest createFromParcel(Parcel source) {
return new WaypointCreationRequest(
WaypointType.values()[source.readInt()],
source.readByte() == 1,
source.readString(),
source.readString(),
source.readString(),
source.readString(),
source.readString());
}
public WaypointCreationRequest[] newArray(int size) {
return new WaypointCreationRequest[size];
}
}
}