From f04b69cc48d2f4ef1381d18ec691217b5299fbf6 Mon Sep 17 00:00:00 2001 From: DrDisagree Date: Mon, 6 Jan 2025 01:04:58 +0600 Subject: [PATCH] Extract string resources --- .../com/drdisagree/colorblendr/ui/fragments/StylesFragment.kt | 4 ++-- app/src/main/res/values/strings.xml | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/com/drdisagree/colorblendr/ui/fragments/StylesFragment.kt b/app/src/main/java/com/drdisagree/colorblendr/ui/fragments/StylesFragment.kt index 6539f4c2..0f789195 100644 --- a/app/src/main/java/com/drdisagree/colorblendr/ui/fragments/StylesFragment.kt +++ b/app/src/main/java/com/drdisagree/colorblendr/ui/fragments/StylesFragment.kt @@ -111,7 +111,7 @@ class StylesFragment : Fragment() { } val titleBinding = ViewTextFieldOutlinedBinding.inflate(layoutInflater).apply { - outlinedTextField.hint = "Title" + outlinedTextField.hint = getString(R.string.title) outlinedTextField.boxBackgroundMode = TextInputLayout.BOX_BACKGROUND_OUTLINE outlinedTextField.editText?.gravity = Gravity.TOP or Gravity.START if (title.isNotEmpty()) { @@ -129,7 +129,7 @@ class StylesFragment : Fragment() { } val descBinding = ViewTextFieldOutlinedBinding.inflate(layoutInflater).apply { - outlinedTextField.hint = "Description" + outlinedTextField.hint = getString(R.string.description) outlinedTextField.boxBackgroundMode = TextInputLayout.BOX_BACKGROUND_OUTLINE outlinedTextField.editText?.gravity = Gravity.TOP or Gravity.START if (desc.isNotEmpty()) { diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 83d2ede2..4e972eef 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -63,8 +63,10 @@ Content Balanced and calming palette, promoting a sense of tranquility and contentment. Save current style - Title and description can\'t be empty + Title + Description Save + Title and description can\'t be empty %s service