From 0a80588dd4d566901269f95db0b0e551724dabbd Mon Sep 17 00:00:00 2001 From: Andrii Chubko Date: Mon, 20 Sep 2021 18:51:40 +0300 Subject: [PATCH] Show recent colors in color picker --- app/build.gradle | 2 +- .../com/simplemobiletools/draw/pro/activities/MainActivity.kt | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index 5b9a468..3f4c419 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -56,6 +56,6 @@ android { } dependencies { - implementation 'com.github.SimpleMobileTools:Simple-Commons:ac45c5e893' + implementation 'com.github.SimpleMobileTools:Simple-Commons:f7575dcaa1' implementation "androidx.print:print:1.0.0" } diff --git a/app/src/main/kotlin/com/simplemobiletools/draw/pro/activities/MainActivity.kt b/app/src/main/kotlin/com/simplemobiletools/draw/pro/activities/MainActivity.kt index 368ea0c..50413c1 100644 --- a/app/src/main/kotlin/com/simplemobiletools/draw/pro/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/draw/pro/activities/MainActivity.kt @@ -318,7 +318,7 @@ class MainActivity : SimpleActivity(), CanvasListener { private fun changeBackgroundClicked() { val oldColor = (my_canvas.background as ColorDrawable).color - ColorPickerDialog(this, oldColor) { wasPositivePressed, color -> + ColorPickerDialog(this, oldColor, showRecentColors = true) { wasPositivePressed, color -> if (wasPositivePressed) { config.canvasBackgroundColor = color setBackgroundColor(color) @@ -479,7 +479,7 @@ class MainActivity : SimpleActivity(), CanvasListener { } private fun pickColor() { - ColorPickerDialog(this, color) { wasPositivePressed, color -> + ColorPickerDialog(this, color, showRecentColors = true) { wasPositivePressed, color -> if (wasPositivePressed) { setColor(color) }