From c54035f87d25c1af07ec83abce9512cc1585bf78 Mon Sep 17 00:00:00 2001 From: Aurelien Hubert Date: Fri, 12 Apr 2019 17:05:45 +0200 Subject: [PATCH 1/2] Add new legend layout --- app/src/main/res/drawable/circle_green.xml | 11 +++ .../main/res/layout/layout_legend_color.xml | 74 +++++++++++++++++++ 2 files changed, 85 insertions(+) create mode 100644 app/src/main/res/drawable/circle_green.xml create mode 100644 app/src/main/res/layout/layout_legend_color.xml diff --git a/app/src/main/res/drawable/circle_green.xml b/app/src/main/res/drawable/circle_green.xml new file mode 100644 index 00000000..93111933 --- /dev/null +++ b/app/src/main/res/drawable/circle_green.xml @@ -0,0 +1,11 @@ + + + + + + + + \ No newline at end of file diff --git a/app/src/main/res/layout/layout_legend_color.xml b/app/src/main/res/layout/layout_legend_color.xml new file mode 100644 index 00000000..2b4b9b82 --- /dev/null +++ b/app/src/main/res/layout/layout_legend_color.xml @@ -0,0 +1,74 @@ + + + + + + + + + + + + + + + + \ No newline at end of file From 57f4f2be6ccff0c6d5342a70711737ad1d597017 Mon Sep 17 00:00:00 2001 From: Aurelien Hubert Date: Fri, 12 Apr 2019 17:15:59 +0200 Subject: [PATCH 2/2] Clean file --- .../main/java/net/pokeranalytics/android/ui/view/LegendView.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/net/pokeranalytics/android/ui/view/LegendView.kt b/app/src/main/java/net/pokeranalytics/android/ui/view/LegendView.kt index eab4bfe2..3d94b2a3 100644 --- a/app/src/main/java/net/pokeranalytics/android/ui/view/LegendView.kt +++ b/app/src/main/java/net/pokeranalytics/android/ui/view/LegendView.kt @@ -40,7 +40,7 @@ class LegendView : FrameLayout { private fun init() { val layoutInflater = LayoutInflater.from(context) legendLayout = layoutInflater.inflate(R.layout.layout_legend_default, this, false) as ConstraintLayout - val layoutParams = FrameLayout.LayoutParams(FrameLayout.LayoutParams.MATCH_PARENT, FrameLayout.LayoutParams.MATCH_PARENT) + val layoutParams = LayoutParams(LayoutParams.MATCH_PARENT, LayoutParams.MATCH_PARENT) addView(legendLayout, layoutParams) }