ref: motis2_journeys
app/src/main/java/xyz/apiote/bimba/czwek/dashboard/DashboardViewModel.kt
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 |
// SPDX-FileCopyrightText: Adam Evyčędo // // SPDX-License-Identifier: GPL-3.0-or-later package xyz.apiote.bimba.czwek.dashboard import androidx.lifecycle.LiveData import androidx.lifecycle.MutableLiveData import androidx.lifecycle.ViewModel import xyz.apiote.bimba.czwek.repo.Place class DashboardViewModel : ViewModel() { private val _origin = MutableLiveData<Place>() val origin: LiveData<Place> = _origin fun setOrigin(o: Place) { _origin.value = o } private val _destination = MutableLiveData<Place>() val destination: LiveData<Place> = _destination fun setDestination(d: Place) { _destination.value = d } } |