feat(createEvent): Make the close button funtional

This commit is contained in:
Peter Vacho 2025-01-02 11:35:43 +01:00
parent 24b6791a76
commit d85b685407
Signed by: school
GPG key ID: 8CFC3837052871B4

View file

@ -49,9 +49,10 @@ class CreateEventActivity : AppCompatActivity() {
private lateinit var btnDurationEvent: MaterialButton
private lateinit var txtStartTime: TextInputEditText
private lateinit var txtEndTime: TextInputEditText
private lateinit var btnCreateEvent: MaterialButton
private lateinit var btnColorPicker: MaterialButton
private lateinit var addCategoryButton: ImageButton
private lateinit var btnCreateEvent: MaterialButton
private lateinit var btnClose: MaterialButton
private lateinit var categoryRecyclerView: RecyclerView
private lateinit var categoryViewSwitcher: ViewSwitcher
@ -94,9 +95,10 @@ class CreateEventActivity : AppCompatActivity() {
btnDurationEvent = findViewById(R.id.btnDurationEvent)
txtStartTime = findViewById(R.id.txtStartTime)
txtEndTime = findViewById(R.id.txtEndTime)
btnCreateEvent = findViewById(R.id.btnCreateEvent)
btnColorPicker = findViewById(R.id.btnColorPicker)
addCategoryButton = findViewById(R.id.btnAddCategory)
btnCreateEvent = findViewById(R.id.btnCreateEvent)
btnClose = findViewById(R.id.btnClose)
categoryViewSwitcher = findViewById(R.id.categoryViewSwitcher)
categoryRecyclerView = findViewById(R.id.categoryChipRecyclerView)
@ -148,6 +150,7 @@ class CreateEventActivity : AppCompatActivity() {
addCategoryButton.setOnClickListener { addCategory() }
btnColorPicker.setOnClickListener { openColorPickerDialog() }
btnCreateEvent.setOnClickListener { createEvent() }
btnClose.setOnClickListener { finish() }
}
private fun addCategory() {