add toast with information about GoingElectric.de edit page

This commit is contained in:
johan12345
2021-04-16 23:46:54 +02:00
parent 999c5b0836
commit 99263e9a66
3 changed files with 8 additions and 0 deletions

View File

@@ -13,6 +13,7 @@ import android.os.Bundle
import android.os.Handler
import android.view.*
import android.widget.TextView
import android.widget.Toast
import androidx.activity.OnBackPressedCallback
import androidx.annotation.RequiresPermission
import androidx.appcompat.app.AlertDialog
@@ -325,6 +326,11 @@ class MapFragment : Fragment(), OnMapReadyCallback, MapsActivity.FragmentCallbac
val charger = vm.charger.value?.data
if (charger != null) {
(activity as? MapsActivity)?.openUrl("https:${charger.url}edit/")
Toast.makeText(
requireContext(),
R.string.edit_on_goingelectric_info,
Toast.LENGTH_LONG
).show()
}
true
}

View File

@@ -162,4 +162,5 @@
<string name="verified_desc">Verifiziert von der GoingElectric.de Community nicht zwangsläufig auch aktuell verfügbar.</string>
<string name="update_060_androidauto_title">Neues Update: Android Auto</string>
<string name="update_060_androidauto_text">Mit diesem neuen Update kannst du EVMap nutzen, um Ladestationen in der Nähe auf unterstützen Autos direkt aus Android Auto zu finden. Öffne einfach die EVMap-App aus dem Menü von Android Auto.</string>
<string name="edit_on_goingelectric_info">Falls hier nur eine leere Seite erscheint, logge dich bitte zuerst bei GoingElectric.de ein.</string>
</resources>

View File

@@ -161,4 +161,5 @@
<string name="verified_desc">Charger verified by a member at the GoingElectric.de community — not necessarily working right now.</string>
<string name="update_060_androidauto_title">New update: Android Auto</string>
<string name="update_060_androidauto_text">With this new update, you can also use EVMap to find nearby chargers from within Android Auto on supported cars. Simply select the EVMap app in the Android Auto menu.</string>
<string name="edit_on_goingelectric_info">If only an empty page is showing here, please first log in to GoingElectric.de.</string>
</resources>