Commit abd6e913 authored by Vladislav Bogdashkin's avatar Vladislav Bogdashkin 🎣

fix switcher for plan types

parent f2a9e182
......@@ -41,7 +41,7 @@
android:top="5dp"
android:bottom="5dp"
android:src="@drawable/ic_bell_on"
android:mipMap="true"
android:mipMap="false"
android:gravity="start"
android:tintMode="screen"
android:tint="@color/colorPrimaryDark" />
......
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android" xmlns:width="http://schemas.android.com/apk/res-auto">
<item android:state_checked="false">
<layer-list>
<item>
<shape android:shape="rectangle"
android:dither="true"
android:useLevel="false">
<size android:width="48dp" android:height="24dp"/>
<corners android:radius="12dp"/>
</shape>
</item>
<item
android:right="8dp">
<shape
android:shape="ring"
android:width="14dp"
android:height="15dp"
android:gravity="end"
android:tint="@color/colorPrimaryDark" />
</item>
</layer-list>
</item>
<item android:state_checked="true">
<layer-list>
<item>
<shape android:shape="rectangle"
android:dither="true"
android:useLevel="false">
<size android:width="48dp" android:height="24dp"/>
<solid android:color="#FFFFFFFF"/>
<corners android:radius="12dp" />
</shape>
</item>
<item
android:left="8dp">
<shape
android:shape="ring"
android:right="27dp"
android:top="5dp"
android:bottom="5dp"
android:gravity="start"
android:tintMode="screen"
android:tint="@color/colorPrimaryDark"/>
</item>
</layer-list>
</item>
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/bell_container"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical">
<com.google.android.material.switchmaterial.SwitchMaterial
style="@style/Widget.MaterialComponents.CompoundButton.Switch.DefaultSwitchStyle"
android:id="@+id/switch1"
android:layout_width="48dp"
android:layout_height="24dp"
android:height="24dp"
android:checked="false"
app:switchMinWidth="48dp" />
</LinearLayout>
\ No newline at end of file
......@@ -7,6 +7,7 @@
android:orientation="vertical">
<com.google.android.material.switchmaterial.SwitchMaterial
style="@style/Widget.MaterialComponents.CompoundButton.Switch.BellSwitchStyle"
android:id="@+id/switch1"
android:layout_width="48dp"
android:layout_height="24dp"
......
......@@ -97,7 +97,7 @@
<include
android:id="@+id/sizes_switcher"
layout="@layout/bell_switch_view"
layout="@layout/default_switch_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="end|center_vertical"
......@@ -140,7 +140,7 @@
<include
android:id="@+id/furniture_switcher"
layout="@layout/bell_switch_view"
layout="@layout/default_switch_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="end|center_vertical"
......@@ -183,7 +183,7 @@
<include
android:id="@+id/electricity_switcher"
layout="@layout/bell_switch_view"
layout="@layout/default_switch_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="end|center_vertical"
......@@ -227,7 +227,7 @@
<include
android:id="@+id/walls_switcher"
layout="@layout/bell_switch_view"
layout="@layout/default_switch_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="end|center_vertical"
......
......@@ -10,7 +10,7 @@
<item name="colorAccent">@color/colorAccent</item>
<item name="materialCardViewStyle">@style/Widget.Biganto.MaterialCardView</item>
<item name="switchStyle">@style/Widget.MaterialComponents.CompoundButton.Switch.BellSwitchStyle</item>
<!-- <item name="switchStyle">@style/Widget.MaterialComponents.CompoundButton.Switch.BellSwitchStyle</item>-->
<item name="colorControlActivated">@color/colorAccent</item>
<item name="colorControlHighlight">@color/colorAccent</item>
<item name="colorControlNormal">@color/colorAccent</item>
......@@ -43,6 +43,13 @@
<item name="trackTint">@drawable/bell_switch_track_tint</item>
</style>
<style name="Widget.MaterialComponents.CompoundButton.Switch.DefaultSwitchStyle" >
<item name="track" >@drawable/def_switch_track</item>
<item name="android:thumb" >@drawable/bell_switcher</item>
<item name="thumbTint">@color/colorPrimaryDark</item>
<item name="trackTint">@drawable/bell_switch_track_tint</item>
</style>
<style name="Widget.Biganto.MaterialCardView" parent="Widget.MaterialComponents.CardView">
<item name="cardUseCompatPadding">false</item>
<item name="strokeWidth">0dp</item>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment