From 0819deb1a718166a63729c353f48c40aecb1d8b3 Mon Sep 17 00:00:00 2001 From: kareemradwan Date: Wed, 1 Jul 2020 16:40:35 +0300 Subject: [PATCH] fix full screen step layout --- .../com/kareemradwan/stepeer/MainActivity.kt | 2 +- .../com/kareemradwan/stepeer/OrderAdapter.kt | 2 +- app/src/main/res/layout/order_step.xml | 49 +++++++++++++------ app/src/main/res/values/strings.xml | 2 + stepeer/src/main/res/layout/item_step.xml | 2 +- 5 files changed, 39 insertions(+), 18 deletions(-) diff --git a/app/src/main/java/com/kareemradwan/stepeer/MainActivity.kt b/app/src/main/java/com/kareemradwan/stepeer/MainActivity.kt index b7249be..d8b8248 100644 --- a/app/src/main/java/com/kareemradwan/stepeer/MainActivity.kt +++ b/app/src/main/java/com/kareemradwan/stepeer/MainActivity.kt @@ -18,7 +18,7 @@ class MainActivity : AppCompatActivity(), SteeperView.SteeperHandler { val adapter = OrderAdapter( this, listOf( - Order(1, "Step1" , true), + Order(1, "Step1" ), Order(2, "Step2"), Order(3, "Step3"), Order(4, "Step4") diff --git a/app/src/main/java/com/kareemradwan/stepeer/OrderAdapter.kt b/app/src/main/java/com/kareemradwan/stepeer/OrderAdapter.kt index 38c5847..43c4274 100644 --- a/app/src/main/java/com/kareemradwan/stepeer/OrderAdapter.kt +++ b/app/src/main/java/com/kareemradwan/stepeer/OrderAdapter.kt @@ -20,7 +20,7 @@ class OrderAdapter(private val context: Context, list: List) : StepAdapte val tvDescriptor = view.findViewById(R.id.tvDesc) tvTitle.text = model.title - tvDescriptor.text = "${model.id}" + tvDescriptor.text = "This Sub Title of Cutome View ${model.id}" return view } diff --git a/app/src/main/res/layout/order_step.xml b/app/src/main/res/layout/order_step.xml index 1e9ed0f..5f228b9 100644 --- a/app/src/main/res/layout/order_step.xml +++ b/app/src/main/res/layout/order_step.xml @@ -1,29 +1,48 @@ + android:layout_marginStart="20dp" + android:layout_marginLeft="20dp" + android:orientation="vertical" + android:paddingBottom="4dp"> - + android:orientation="horizontal"> - + + + + + + \ No newline at end of file diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 6da0792..d1d6883 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -1,3 +1,5 @@ Stepeer + Title + 2 hour diff --git a/stepeer/src/main/res/layout/item_step.xml b/stepeer/src/main/res/layout/item_step.xml index 092c148..aef76f0 100644 --- a/stepeer/src/main/res/layout/item_step.xml +++ b/stepeer/src/main/res/layout/item_step.xml @@ -51,7 +51,7 @@