mirror of
https://github.com/SimpleMobileTools/Simple-Notes.git
synced 2025-06-05 17:00:23 +02:00
Allow to choose whether to put cursor to end of note
This commit is contained in:
@ -31,6 +31,7 @@ class SettingsActivity : SimpleActivity() {
|
||||
setupFontSize()
|
||||
setupGravity()
|
||||
setupWidgetNote()
|
||||
setupCursorPlacement()
|
||||
updateTextColors(settings_scrollview)
|
||||
}
|
||||
|
||||
@ -121,6 +122,14 @@ class SettingsActivity : SimpleActivity() {
|
||||
}
|
||||
}
|
||||
|
||||
private fun setupCursorPlacement() {
|
||||
settings_cursor_placement.isChecked = config.placeCursorToEnd
|
||||
settings_cursor_placement_holder.setOnClickListener {
|
||||
settings_cursor_placement.toggle()
|
||||
config.placeCursorToEnd = settings_cursor_placement.isChecked
|
||||
}
|
||||
}
|
||||
|
||||
private fun getCurrentWidgetNoteTitle(currentNoteId: Int, notes: List<Note>): String {
|
||||
return notes.firstOrNull { it.id == currentNoteId }?.title ?: ""
|
||||
}
|
||||
|
Reference in New Issue
Block a user