show toasts at long pressing Undo/Redo too

This commit is contained in:
tibbi 2022-12-20 17:36:06 +01:00
parent 1902593dea
commit 66d4a28296
1 changed files with 10 additions and 0 deletions

View File

@ -94,6 +94,11 @@ class MainActivity : SimpleActivity(), CanvasListener {
color_picker.setOnClickListener { pickColor() } color_picker.setOnClickListener { pickColor() }
undo.setOnClickListener { my_canvas.undo() } undo.setOnClickListener { my_canvas.undo() }
undo.setOnLongClickListener {
toast(R.string.undo)
true
}
eraser.setOnClickListener { eraserClicked() } eraser.setOnClickListener { eraserClicked() }
eraser.setOnLongClickListener { eraser.setOnLongClickListener {
toast(R.string.eraser) toast(R.string.eraser)
@ -101,6 +106,11 @@ class MainActivity : SimpleActivity(), CanvasListener {
} }
redo.setOnClickListener { my_canvas.redo() } redo.setOnClickListener { my_canvas.redo() }
redo.setOnLongClickListener {
toast(R.string.redo)
true
}
eye_dropper.setOnClickListener { eyeDropperClicked() } eye_dropper.setOnClickListener { eyeDropperClicked() }
eye_dropper.setOnLongClickListener { eye_dropper.setOnLongClickListener {
toast(R.string.eyedropper) toast(R.string.eyedropper)