Skip to content

Commit 0d0b86a

Browse files
committed
PR Fixes
1 parent dd45842 commit 0d0b86a

26 files changed

Lines changed: 45 additions & 25 deletions

File tree

app/src/main/java/com/philkes/notallyx/presentation/activity/main/fragment/settings/PreferenceBindingExtensions.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -542,7 +542,6 @@ fun PreferenceSeekbarBinding.setupTextSizePreference(
542542

543543
override fun onStopTrackingTouch(slider: Slider) {
544544
PreviewText.isVisible = false
545-
onChange(slider.value)
546545
}
547546
}
548547
)

app/src/main/java/com/philkes/notallyx/presentation/view/note/listitem/adapter/CheckedListItemAdapter.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,11 @@ import com.philkes.notallyx.data.model.NoteViewMode
1010
import com.philkes.notallyx.presentation.view.note.listitem.HighlightText
1111
import com.philkes.notallyx.presentation.view.note.listitem.ListManager
1212
import com.philkes.notallyx.presentation.viewmodel.preference.NotallyXPreferences
13+
import com.philkes.notallyx.presentation.viewmodel.preference.TextSizeSp
1314

1415
class CheckedListItemAdapter(
1516
@ColorInt var backgroundColor: Int,
16-
private val textSize: Int,
17+
private val textSize: TextSizeSp,
1718
elevation: Float,
1819
private val preferences: NotallyXPreferences,
1920
private val listManager: ListManager,

app/src/main/java/com/philkes/notallyx/presentation/view/note/listitem/adapter/ListItemAdapter.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,11 @@ import com.philkes.notallyx.data.model.NoteViewMode
1111
import com.philkes.notallyx.presentation.view.note.listitem.HighlightText
1212
import com.philkes.notallyx.presentation.view.note.listitem.ListManager
1313
import com.philkes.notallyx.presentation.viewmodel.preference.NotallyXPreferences
14+
import com.philkes.notallyx.presentation.viewmodel.preference.TextSizeSp
1415

1516
class ListItemAdapter(
1617
@ColorInt var backgroundColor: Int,
17-
private val textSize: Int,
18+
private val textSize: TextSizeSp,
1819
elevation: Float,
1920
private val preferences: NotallyXPreferences,
2021
private val listManager: ListManager,

app/src/main/java/com/philkes/notallyx/presentation/view/note/listitem/adapter/ListItemAdapterBase.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ import com.philkes.notallyx.databinding.RecyclerListItemBinding
1212
import com.philkes.notallyx.presentation.view.note.listitem.ListItemDragCallback
1313
import com.philkes.notallyx.presentation.view.note.listitem.ListManager
1414
import com.philkes.notallyx.presentation.viewmodel.preference.NotallyXPreferences
15+
import com.philkes.notallyx.presentation.viewmodel.preference.TextSizeSp
1516

1617
data class ListItemHighlight(
1718
val itemPos: Int,
@@ -24,7 +25,7 @@ data class ListItemHighlight(
2425
abstract class ListItemAdapterBase(
2526
private val adapter: RecyclerView.Adapter<*>,
2627
@ColorInt var backgroundColor: Int,
27-
private val textSize: Int,
28+
private val textSize: TextSizeSp,
2829
elevation: Float,
2930
private val preferences: NotallyXPreferences,
3031
private val listManager: ListManager,

app/src/main/java/com/philkes/notallyx/presentation/view/note/listitem/adapter/ListItemVH.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ class ListItemVH(
4040
val binding: RecyclerListItemBinding,
4141
val listManager: ListManager,
4242
touchHelper: ItemTouchHelper,
43-
textSize: Int,
43+
textSize: Float,
4444
private val inCheckedList: Boolean,
4545
) : RecyclerView.ViewHolder(binding.root) {
4646

app/src/main/java/com/philkes/notallyx/presentation/viewmodel/NotallyModel.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ import com.philkes.notallyx.presentation.showToast
3939
import com.philkes.notallyx.presentation.view.misc.NotNullLiveData
4040
import com.philkes.notallyx.presentation.view.misc.Progress
4141
import com.philkes.notallyx.presentation.viewmodel.preference.NotallyXPreferences
42+
import com.philkes.notallyx.presentation.viewmodel.preference.TextSizeSp
4243
import com.philkes.notallyx.presentation.viewmodel.progress.AddFilesProgress
4344
import com.philkes.notallyx.presentation.widget.WidgetProvider
4445
import com.philkes.notallyx.utils.Cache
@@ -68,7 +69,7 @@ class NotallyModel(private val app: Application) : AndroidViewModel(app) {
6869
private lateinit var baseNoteDao: BaseNoteDao
6970

7071
val preferences = NotallyXPreferences.getInstance(app)
71-
val textSize = preferences.textSizeNoteEditor.value
72+
val textSize: TextSizeSp = preferences.textSizeNoteEditor.value
7273

7374
var isNewNote = true
7475

app/src/main/res/layout/recycler_base_note.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,6 @@
125125
<com.google.android.material.chip.Chip
126126
android:id="@+id/ReminderChip"
127127
style="@style/ReminderChip"
128-
android:layout_marginStart="12dp"
129128
tools:closeIconVisible="true"
130129
tools:text="00/00/0000 00:00"
131130
tools:visibility="visible"

app/src/main/res/values-cs/strings.xml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,7 @@
319319
<string name="tap_for_more_options">Klepněte pro více možností</string>
320320
<string name="tap_to_set_up">Nastavit klepnutím sem</string>
321321
<string name="text_default">Výchozí</string>
322-
<string name="text_size_note_editor">Velikost písma</string>
322+
<string name="text_size_note_editor">Velikost písma (editor poznámek)</string>
323323
<string name="theme">Téma</string>
324324
<string name="theme_use_dynamic_colors">Použít barvy z tapety</string>
325325
<string name="title">Název</string>
@@ -350,4 +350,5 @@
350350
<string name="yearly">Ročně</string>
351351
<string name="years">Roky</string>
352352
<string name="your_notes_associated">Vaše poznámky přiřazené k tomuto štítku nebudou smazány</string>
353+
<string name="text_size_overview">Velikost písma (přehled)</string>
353354
</resources>

app/src/main/res/values-de/strings.xml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -339,7 +339,7 @@
339339
<string name="tap_for_more_options">Klick für mehr Optionen</string>
340340
<string name="tap_to_set_up">Zum Einrichten antippen</string>
341341
<string name="text_default">Standard</string>
342-
<string name="text_size_note_editor">Textgröße</string>
342+
<string name="text_size_note_editor">Textgröße (Notizeditor)</string>
343343
<string name="theme">Design</string>
344344
<string name="theme_use_dynamic_colors">Systemhintergrundfarben verwenden</string>
345345
<string name="title">Titel</string>
@@ -369,4 +369,5 @@
369369
<string name="yearly">Jährlich</string>
370370
<string name="years">Jahre</string>
371371
<string name="your_notes_associated">Notizen, welche dieses Label verwenden, werden nicht gelöscht.</string>
372+
<string name="text_size_overview">Textgröße (Übersicht)</string>
372373
</resources>

app/src/main/res/values-es/strings.xml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,7 @@
312312
<string name="tap_for_more_options">Tocar para más opciones</string>
313313
<string name="tap_to_set_up">Toque para configurar</string>
314314
<string name="text_default">Por defecto</string>
315-
<string name="text_size_note_editor">Tamaño de texto</string>
315+
<string name="text_size_note_editor">Tamaño de texto (editor de notas)</string>
316316
<string name="theme">Tema</string>
317317
<string name="theme_use_dynamic_colors">Usar color de fondo del sistema</string>
318318
<string name="title">Título</string>
@@ -342,4 +342,5 @@
342342
<string name="yearly">Anual</string>
343343
<string name="years">Años</string>
344344
<string name="your_notes_associated">Tus notas asociadas con esta etiqueta no serán eliminadas</string>
345+
<string name="text_size_overview">Tamaño de texto (descripción general)</string>
345346
</resources>

0 commit comments

Comments
 (0)