minor code style formatting
This commit is contained in:
parent
51b22197ca
commit
bca4aa4704
|
@ -40,18 +40,18 @@ class EditEventTypeDialog(val activity: Activity, var eventType: EventType? = nu
|
|||
}
|
||||
|
||||
AlertDialog.Builder(activity)
|
||||
.setPositiveButton(R.string.ok, null)
|
||||
.setNegativeButton(R.string.cancel, null)
|
||||
.create().apply {
|
||||
activity.setupDialogStuff(view, this, if (isNewEvent) R.string.add_new_type else R.string.edit_type) {
|
||||
showKeyboard(view.type_title)
|
||||
getButton(AlertDialog.BUTTON_POSITIVE).setOnClickListener {
|
||||
ensureBackgroundThread {
|
||||
eventTypeConfirmed(view.type_title.value, this)
|
||||
}
|
||||
.setPositiveButton(R.string.ok, null)
|
||||
.setNegativeButton(R.string.cancel, null)
|
||||
.create().apply {
|
||||
activity.setupDialogStuff(view, this, if (isNewEvent) R.string.add_new_type else R.string.edit_type) {
|
||||
showKeyboard(view.type_title)
|
||||
getButton(AlertDialog.BUTTON_POSITIVE).setOnClickListener {
|
||||
ensureBackgroundThread {
|
||||
eventTypeConfirmed(view.type_title.value, this)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun setupColor(view: ImageView) {
|
||||
|
|
|
@ -35,13 +35,13 @@ class SelectEventTypeColorDialog(val activity: Activity, val eventType: EventTyp
|
|||
|
||||
wasInit = true
|
||||
dialog = AlertDialog.Builder(activity)
|
||||
.create().apply {
|
||||
activity.setupDialogStuff(view, this)
|
||||
.create().apply {
|
||||
activity.setupDialogStuff(view, this)
|
||||
|
||||
if (colors.isEmpty()) {
|
||||
showCustomColorPicker()
|
||||
}
|
||||
if (colors.isEmpty()) {
|
||||
showCustomColorPicker()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun addRadioButton(colorKey: Int, color: Int) {
|
||||
|
|
Loading…
Reference in New Issue