Adds editing of condition immunities.
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".ui.editmonster.EditConditionImmunitiesFragment">
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/list"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:divider="?android:attr/dividerVertical"
|
||||
android:dividerPadding="@dimen/text_margin"
|
||||
app:layoutManager="LinearLayoutManager"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:listitem="@layout/fragment_edit_condition_immunities_list_item" />
|
||||
|
||||
<com.google.android.material.floatingactionbutton.FloatingActionButton
|
||||
android:id="@+id/add_condition_immunity"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="bottom|end"
|
||||
android:layout_margin="@dimen/fab_margin"
|
||||
android:contentDescription="@string/action_add_condition_immunity"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:srcCompat="@android:drawable/ic_input_add"
|
||||
app:tint="@android:color/white" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -0,0 +1,13 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/content"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="@dimen/text_margin"
|
||||
android:textAppearance="?attr/textAppearanceListItem" />
|
||||
</LinearLayout>
|
||||
18
app/src/main/res/layout/fragment_edit_condition_immunity.xml
Normal file
18
app/src/main/res/layout/fragment_edit_condition_immunity.xml
Normal file
@@ -0,0 +1,18 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.google.android.material.textfield.TextInputLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="@dimen/text_margin"
|
||||
tools:context=".ui.editmonster.EditConditionImmunityFragment">
|
||||
|
||||
<com.google.android.material.textfield.TextInputEditText
|
||||
android:id="@+id/description"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:hint="@string/label_description"
|
||||
android:importantForAutofill="no"
|
||||
android:inputType="text"
|
||||
tools:text="blinded" />
|
||||
|
||||
</com.google.android.material.textfield.TextInputLayout>
|
||||
@@ -96,6 +96,9 @@
|
||||
<action
|
||||
android:id="@+id/action_editMonsterFragment_to_editSensesFragment"
|
||||
app:destination="@id/editSensesFragment" />
|
||||
<action
|
||||
android:id="@+id/action_editMonsterFragment_to_editConditionImmunitiesFragment"
|
||||
app:destination="@id/editConditionImmunitiesFragment" />
|
||||
</fragment>
|
||||
<fragment
|
||||
android:id="@+id/editBasicInfoFragment"
|
||||
@@ -171,5 +174,23 @@
|
||||
android:name="sense"
|
||||
app:argType="string" />
|
||||
</fragment>
|
||||
<fragment
|
||||
android:id="@+id/editConditionImmunitiesFragment"
|
||||
android:name="com.majinnaibu.monstercards.ui.editmonster.EditConditionImmunitiesFragment"
|
||||
android:label="fragment_edit_condition_immunities_list"
|
||||
tools:layout="@layout/fragment_edit_condition_immunities_list">
|
||||
<action
|
||||
android:id="@+id/action_editConditionImmunitiesFragment_to_editConditionImmunity"
|
||||
app:destination="@id/editConditionImmunity" />
|
||||
</fragment>
|
||||
<fragment
|
||||
android:id="@+id/editConditionImmunity"
|
||||
android:name="com.majinnaibu.monstercards.ui.editmonster.EditConditionImmunityFragment"
|
||||
android:label="fragment_edit_condition_immunity"
|
||||
tools:layout="@layout/fragment_edit_condition_immunity">
|
||||
<argument
|
||||
android:name="condition"
|
||||
app:argType="string" />
|
||||
</fragment>
|
||||
</navigation>
|
||||
</navigation>
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
<string name="action_add_monster">Add monster</string>
|
||||
<string name="action_add_sense">Add Sense</string>
|
||||
<string name="action_add_skill">Add Skill</string>
|
||||
<string name="action_add_condition_immunity">Add Condition</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="actions_label">Actions</string>
|
||||
<string name="app_name">MonsterCards</string>
|
||||
|
||||
Reference in New Issue
Block a user