1 Commits

Author SHA1 Message Date
d8978a9b8c events: allow editing of all used values
Allow to change the date/time and
other relevant values of an event
on creation and after it was created.
2025-11-12 00:17:21 +01:00
4 changed files with 3 additions and 3 deletions

View File

@@ -371,7 +371,7 @@ class MainActivity : AppCompatActivity() {
fun askPukeValue(event: LunaEvent, showTime: Boolean, onPositive: () -> Unit) { fun askPukeValue(event: LunaEvent, showTime: Boolean, onPositive: () -> Unit) {
val d = AlertDialog.Builder(this) val d = AlertDialog.Builder(this)
val dialogView = layoutInflater.inflate(R.layout.dialog_edit_puke, null) val dialogView = layoutInflater.inflate(R.layout.dialog_puke, null)
d.setTitle(R.string.log_puke_dialog_title) d.setTitle(R.string.log_puke_dialog_title)
d.setMessage(R.string.log_puke_dialog_description) d.setMessage(R.string.log_puke_dialog_description)
d.setView(dialogView) d.setView(dialogView)
@@ -412,7 +412,7 @@ class MainActivity : AppCompatActivity() {
// Ask to edit events to be edited (only affects date) // Ask to edit events to be edited (only affects date)
fun askDateValue(event: LunaEvent, showTime: Boolean, onPositive: () -> Unit) { fun askDateValue(event: LunaEvent, showTime: Boolean, onPositive: () -> Unit) {
val d = AlertDialog.Builder(this) val d = AlertDialog.Builder(this)
val dialogView = layoutInflater.inflate(R.layout.dialog_edit_plain, null) val dialogView = layoutInflater.inflate(R.layout.dialog_plain_event, null)
d.setTitle(event.getTypeDescription(this)) d.setTitle(event.getTypeDescription(this))
d.setMessage(event.getDialogMessage(this)) d.setMessage(event.getDialogMessage(this))
d.setView(dialogView) d.setView(dialogView)
@@ -445,7 +445,7 @@ class MainActivity : AppCompatActivity() {
val useQuantity = (event.type != LunaEvent.TYPE_NOTE && event.type != LunaEvent.TYPE_CUSTOM) val useQuantity = (event.type != LunaEvent.TYPE_NOTE && event.type != LunaEvent.TYPE_CUSTOM)
val d = AlertDialog.Builder(this) val d = AlertDialog.Builder(this)
val dialogView = layoutInflater.inflate(R.layout.dialog_edit_notes, null) val dialogView = layoutInflater.inflate(R.layout.dialog_notes, null)
d.setTitle(event.getTypeDescription(this)) d.setTitle(event.getTypeDescription(this))
d.setMessage(event.getDialogMessage(this)) d.setMessage(event.getDialogMessage(this))
d.setView(dialogView) d.setView(dialogView)