adding a hint at the main view, if the note is empty

This commit is contained in:
tibbi 2020-04-20 13:45:29 +02:00
parent ae0ac64278
commit b9b9333ef1
4 changed files with 14 additions and 12 deletions

View File

@ -57,7 +57,7 @@ android {
}
dependencies {
implementation 'com.simplemobiletools:commons:5.26.9'
implementation 'com.simplemobiletools:commons:5.26.10'
implementation 'androidx.constraintlayout:constraintlayout:2.0.0-beta4'
kapt 'androidx.room:room-compiler:2.2.5'

View File

@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.coordinatorlayout.widget.CoordinatorLayout
xmlns:android="http://schemas.android.com/apk/res/android"
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/checklist_holder"
android:layout_width="match_parent"
@ -18,19 +17,21 @@
android:clipToPadding="false"
android:overScrollMode="never"
android:visibility="gone"
app:layoutManager="com.simplemobiletools.commons.views.MyLinearLayoutManager"/>
app:layoutManager="com.simplemobiletools.commons.views.MyLinearLayoutManager" />
<com.simplemobiletools.commons.views.MyTextView
android:id="@+id/fragment_placeholder"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/activity_margin"
android:alpha="0.8"
android:gravity="center"
android:paddingLeft="@dimen/activity_margin"
android:paddingRight="@dimen/activity_margin"
android:paddingStart="@dimen/activity_margin"
android:paddingEnd="@dimen/activity_margin"
android:text="@string/checklist_is_empty"
android:textSize="@dimen/bigger_text_size"
android:visibility="gone"/>
android:textStyle="italic"
android:visibility="gone" />
<com.simplemobiletools.commons.views.MyTextView
android:id="@+id/fragment_placeholder_2"
@ -43,7 +44,7 @@
android:padding="@dimen/activity_margin"
android:text="@string/add_new_checklist_items"
android:textSize="@dimen/bigger_text_size"
android:visibility="gone"/>
android:visibility="gone" />
</RelativeLayout>
<com.simplemobiletools.commons.views.MyFloatingActionButton
@ -52,6 +53,6 @@
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
android:layout_margin="@dimen/activity_margin"
android:src="@drawable/ic_plus_vector"/>
android:src="@drawable/ic_plus_vector" />
</androidx.coordinatorlayout.widget.CoordinatorLayout>

View File

@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<com.simplemobiletools.notes.pro.views.MyHorizontalScrollView
xmlns:android="http://schemas.android.com/apk/res/android"
<com.simplemobiletools.notes.pro.views.MyHorizontalScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/notes_horizontal_scrollview"
android:layout_width="match_parent"
android:layout_height="match_parent"
@ -14,9 +13,10 @@
android:background="@null"
android:freezesText="true"
android:gravity="top"
android:hint="@string/insert_text_here"
android:inputType="textCapSentences|textMultiLine"
android:padding="@dimen/activity_margin"
android:scrollbars="vertical"
android:textCursorDrawable="@null"/>
android:textCursorDrawable="@null" />
</com.simplemobiletools.notes.pro.views.MyHorizontalScrollView>

View File

@ -6,6 +6,7 @@
android:layout_height="match_parent"
android:background="@null"
android:freezesText="true"
android:hint="@string/insert_text_here"
android:gravity="top"
android:inputType="textCapSentences|textMultiLine"
android:padding="@dimen/activity_margin"