Commit 56ff5606 authored by Govind Dixit's avatar Govind Dixit

feat: add erase feature in drawing

parent ac4ffd53
......@@ -53,8 +53,18 @@ class DrawingActivity : DaggerAppCompatActivity(), DrawView {
}
private fun setupDrawTools() {
image_draw_eraser.setOnClickListener {
image_draw_eraser.setOnLongClickListener{
custom_draw_view.clearCanvas()
return@setOnLongClickListener true
}
image_draw_eraser.setOnClickListener {
custom_draw_view.setColor(
ResourcesCompat.getColor(
resources,
R.color.color_white, null
)
)
toggleDrawTools(draw_tools, false)
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment