Skip to content

Commit

Permalink
add cancel button listener
Browse files Browse the repository at this point in the history
Signed-off-by: parneet-guraya <[email protected]>
  • Loading branch information
parneet-guraya committed Feb 25, 2025
1 parent 1c7dce9 commit d866202
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import android.view.View
import android.view.ViewGroup
import android.widget.AdapterView
import android.widget.AdapterView.OnItemClickListener
import android.widget.Button
import android.widget.EditText
import android.widget.FrameLayout
import android.widget.ImageView
Expand Down Expand Up @@ -330,6 +331,10 @@ class UploadMediaDetailAdapter : RecyclerView.Adapter<UploadMediaDetailAdapter.V

listView.adapter = languagesAdapter

dialog.findViewById<Button>(R.id.cancel_button)
.setOnClickListener { v: View? -> dialog.dismiss() }


editText.addTextChangedListener(object : TextWatcher {
override fun beforeTextChanged(charSequence: CharSequence, i: Int, i1: Int, i2: Int) =
hideRecentLanguagesSection()
Expand Down

0 comments on commit d866202

Please sign in to comment.