adding a missing settings divider + minor code style tweaks

This commit is contained in:
tibbi 2023-01-29 23:25:37 +01:00
parent c21408197e
commit 1c7babc410
5 changed files with 12 additions and 13 deletions

View File

@ -179,9 +179,7 @@ class MainActivity : SimpleActivity() {
isEnabled = showRedoButton && mCurrentNote.type == NoteType.TYPE_TEXT.value
icon?.alpha = if (isEnabled) 255 else 127
}
}
main_toolbar.menu.apply {
findItem(R.id.rename_note).isVisible = multipleNotesExist
findItem(R.id.open_note).isVisible = multipleNotesExist
findItem(R.id.delete_note).isVisible = multipleNotesExist
@ -556,7 +554,6 @@ class MainActivity : SimpleActivity() {
private fun openSearch() {
isSearchActive = true
search_wrapper.fadeIn()
animateTopBarColors(window.statusBarColor, getProperStatusBarColor())
showKeyboard(searchQueryET)
currentNotesView()?.let { noteView ->
@ -573,7 +570,6 @@ class MainActivity : SimpleActivity() {
searchQueryET.text?.clear()
isSearchActive = false
search_wrapper.fadeOut()
animateTopBarColors(window.statusBarColor, getProperBackgroundColor())
}
private fun getWantedNoteIndex(wantedNoteId: Long?): Int {

View File

@ -13,12 +13,10 @@ import com.simplemobiletools.commons.helpers.SORT_BY_CUSTOM
import com.simplemobiletools.notes.pro.R
import com.simplemobiletools.notes.pro.extensions.config
import kotlinx.android.synthetic.main.dialog_new_checklist_item.view.*
import kotlinx.android.synthetic.main.dialog_new_checklist_item.view.dialog_holder
import kotlinx.android.synthetic.main.item_add_checklist.view.*
class NewChecklistItemDialog(val activity: Activity, callback: (titles: ArrayList<String>) -> Unit) {
private val titles = mutableListOf<AppCompatEditText>()
private val textColor = activity.getProperTextColor()
private val view: ViewGroup = activity.layoutInflater.inflate(R.layout.dialog_new_checklist_item, null) as ViewGroup
init {

View File

@ -7,9 +7,10 @@ import androidx.room.PrimaryKey
@Entity(tableName = "widgets", indices = [(Index(value = ["widget_id"], unique = true))])
data class Widget(
@PrimaryKey(autoGenerate = true) var id: Long?,
@ColumnInfo(name = "widget_id") var widgetId: Int,
@ColumnInfo(name = "note_id") var noteId: Long,
@ColumnInfo(name = "widget_bg_color") var widgetBgColor: Int,
@ColumnInfo(name = "widget_text_color") var widgetTextColor: Int,
@ColumnInfo(name = "widget_show_title") var widgetShowTitle: Boolean)
@PrimaryKey(autoGenerate = true) var id: Long?,
@ColumnInfo(name = "widget_id") var widgetId: Int,
@ColumnInfo(name = "note_id") var noteId: Long,
@ColumnInfo(name = "widget_bg_color") var widgetBgColor: Int,
@ColumnInfo(name = "widget_text_color") var widgetTextColor: Int,
@ColumnInfo(name = "widget_show_title") var widgetShowTitle: Boolean
)

View File

@ -306,6 +306,10 @@
</RelativeLayout>
<include
android:id="@+id/settings_startup_divider"
layout="@layout/divider" />
<TextView
android:id="@+id/settings_saving_label"
style="@style/SettingsSectionLabelStyle"

View File

@ -25,7 +25,7 @@
android:id="@+id/undo"
android:icon="@drawable/ic_undo_vector"
android:title="@string/undo"
app:showAsAction="ifRoom" />
app:showAsAction="always" />
<item
android:id="@+id/redo"
android:icon="@drawable/ic_redo_vector"