From d24f8d3a75703efc148042c20d2c05b748669db1 Mon Sep 17 00:00:00 2001 From: Vitaliy Date: Wed, 6 May 2020 15:00:11 +0300 Subject: [PATCH] Update tracker aidl --- .../net/osmand/aidl/IOsmAndAidlInterface.aidl | 4 ++ .../aidl/quickaction/QuickActionParams.aidl | 3 ++ .../aidl/quickaction/QuickActionParams.java | 47 +++++++++++++++++++ 3 files changed, 54 insertions(+) create mode 100644 OsmAnd-telegram/src/net/osmand/aidl/quickaction/QuickActionParams.aidl create mode 100644 OsmAnd-telegram/src/net/osmand/aidl/quickaction/QuickActionParams.java diff --git a/OsmAnd-telegram/src/net/osmand/aidl/IOsmAndAidlInterface.aidl b/OsmAnd-telegram/src/net/osmand/aidl/IOsmAndAidlInterface.aidl index b4394d647a..31158b895b 100644 --- a/OsmAnd-telegram/src/net/osmand/aidl/IOsmAndAidlInterface.aidl +++ b/OsmAnd-telegram/src/net/osmand/aidl/IOsmAndAidlInterface.aidl @@ -94,6 +94,8 @@ import net.osmand.aidl.contextmenu.RemoveContextMenuButtonsParams; import net.osmand.aidl.mapmarker.RemoveMapMarkersParams; +import net.osmand.aidl.quickaction.QuickActionParams; + // NOTE: Add new methods at the end of file!!! interface IOsmAndAidlInterface { @@ -849,4 +851,6 @@ interface IOsmAndAidlInterface { boolean getGpxColor(inout GpxColorParams params); boolean importProfile(in ProfileSettingsParams params); + + boolean executeQuickAction(in QuickActionParams params); } diff --git a/OsmAnd-telegram/src/net/osmand/aidl/quickaction/QuickActionParams.aidl b/OsmAnd-telegram/src/net/osmand/aidl/quickaction/QuickActionParams.aidl new file mode 100644 index 0000000000..2a2fca38d8 --- /dev/null +++ b/OsmAnd-telegram/src/net/osmand/aidl/quickaction/QuickActionParams.aidl @@ -0,0 +1,3 @@ +package net.osmand.aidl.quickaction; + +parcelable QuickActionParams; \ No newline at end of file diff --git a/OsmAnd-telegram/src/net/osmand/aidl/quickaction/QuickActionParams.java b/OsmAnd-telegram/src/net/osmand/aidl/quickaction/QuickActionParams.java new file mode 100644 index 0000000000..b9fd262600 --- /dev/null +++ b/OsmAnd-telegram/src/net/osmand/aidl/quickaction/QuickActionParams.java @@ -0,0 +1,47 @@ +package net.osmand.aidl.quickaction; + +import android.os.Parcel; +import android.os.Parcelable; + +public class QuickActionParams implements Parcelable { + + private int actionNumber; + + public QuickActionParams(int actionNumber) { + this.actionNumber = actionNumber; + } + + public QuickActionParams(Parcel in) { + readFromParcel(in); + } + + public static final Creator CREATOR = new Creator() { + @Override + public QuickActionParams createFromParcel(Parcel in) { + return new QuickActionParams(in); + } + + @Override + public QuickActionParams[] newArray(int size) { + return new QuickActionParams[size]; + } + }; + + public int getActionNumber() { + return actionNumber; + } + + @Override + public void writeToParcel(Parcel out, int flags) { + out.writeInt(actionNumber); + } + + private void readFromParcel(Parcel in) { + actionNumber = in.readInt(); + } + + @Override + public int describeContents() { + return 0; + } +} \ No newline at end of file