mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-11-24 19:06:53 +01:00
Adjust personal settings defaults to prevent zero values
Show/hide intensity in sleep per preference Optimize icons
This commit is contained in:
parent
551a5c1a66
commit
db7280b359
@ -421,6 +421,7 @@ public class SleepChartFragment extends AbstractChartFragment {
|
||||
deepSleepEntry.formColor = akDeepSleep.color;
|
||||
legendEntries.add(deepSleepEntry);
|
||||
heartRateIcon.setVisibility(View.GONE); //hide heart icon
|
||||
intensityTotalIcon.setVisibility(View.GONE); //hide intensity icon
|
||||
|
||||
if (supportsHeartrate(getChartsHost().getDevice())) {
|
||||
LegendEntry hrEntry = new LegendEntry();
|
||||
@ -433,6 +434,7 @@ public class SleepChartFragment extends AbstractChartFragment {
|
||||
hrAverageEntry.formColor = Color.RED;
|
||||
legendEntries.add(hrAverageEntry);
|
||||
heartRateIcon.setVisibility(View.VISIBLE);
|
||||
intensityTotalIcon.setVisibility(View.VISIBLE);
|
||||
}
|
||||
}
|
||||
chart.getLegend().setCustom(legendEntries);
|
||||
|
@ -116,7 +116,7 @@ public class ActivityUser {
|
||||
}
|
||||
|
||||
public int getStepsGoal() {
|
||||
if (activityUserStepsGoal < 0) {
|
||||
if (activityUserStepsGoal < 1) {
|
||||
activityUserStepsGoal = defaultUserStepsGoal;
|
||||
}
|
||||
return activityUserStepsGoal;
|
||||
@ -157,7 +157,7 @@ public class ActivityUser {
|
||||
|
||||
public int getCaloriesBurnt()
|
||||
{
|
||||
if (activityUserCaloriesBurnt < 0) {
|
||||
if (activityUserCaloriesBurnt < 1) {
|
||||
activityUserCaloriesBurnt = defaultUserCaloriesBurnt;
|
||||
}
|
||||
return activityUserCaloriesBurnt;
|
||||
@ -165,7 +165,7 @@ public class ActivityUser {
|
||||
|
||||
public int getDistanceMeters()
|
||||
{
|
||||
if (activityUserDistanceMeters < 0) {
|
||||
if (activityUserDistanceMeters < 1) {
|
||||
activityUserDistanceMeters = defaultUserDistanceMeters;
|
||||
}
|
||||
return activityUserDistanceMeters;
|
||||
@ -173,7 +173,7 @@ public class ActivityUser {
|
||||
|
||||
public int getActiveTimeMinutes()
|
||||
{
|
||||
if (activityUserActiveTimeMinutes < 0) {
|
||||
if (activityUserActiveTimeMinutes < 1) {
|
||||
activityUserActiveTimeMinutes = defaultUserActiveTimeMinutes;
|
||||
}
|
||||
return activityUserActiveTimeMinutes;
|
||||
|
@ -1,31 +1,6 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="26dp"
|
||||
android:height="26dp"
|
||||
android:tint="#7E7E7E"
|
||||
android:viewportWidth="26"
|
||||
android:viewportHeight="26">
|
||||
<path
|
||||
android:pathData="m11.711,16.3278a4.8542,7.133 75.8015,0 1,-5.6028 -5.0206,4.8542 7.133,75.8015 0,1 8.1903,-5.0206 4.8542,7.133 75.8015,0 1,5.6028 5.0206,4.8542 7.133,75.8015 0,1 -8.1903,5.0206M21.4865,14.0769 L26.0048,11.3072 22.914,8.5375L23.9253,4.613L18.5345,4.613L15.4436,1.8433 10.9253,4.613L5.5345,4.613L4.5232,8.5375L0.0048,11.3072 3.0957,14.0769L2.0844,18.0013L7.4752,18.0013L10.566,20.771 15.0844,18.0013L20.4752,18.0013Z"
|
||||
android:strokeWidth="1.01966"
|
||||
android:fillColor="#000000"/>
|
||||
<path
|
||||
android:pathData="m4.273,11.6324l4.094,0l3.4795,-4.2078 1.0371,4.5933 2.6841,-2.2817l7.4587,0l-0.8601,1.1607L16.1168,10.897l-4.3503,3.7731 -0.8612,-3.8037 -1.6109,2.011 -4.0304,-0.0003z"
|
||||
android:strokeWidth="1.01966"
|
||||
android:fillColor="#000000"/>
|
||||
<path
|
||||
android:pathData="m1.8709,18.7471l-0.3147,1.2211l5.343,0l3.129,2.807 4.5735,-2.807l5.3453,0l0.3147,-1.2211l-5.4373,0l-4.4626,2.734 -3.0558,-2.734z"
|
||||
android:strokeLineJoin="miter"
|
||||
android:strokeWidth="0.591009"
|
||||
android:fillColor="#000000"
|
||||
android:strokeColor="#00000000"
|
||||
android:fillType="evenOdd"
|
||||
android:strokeLineCap="butt"/>
|
||||
<path
|
||||
android:pathData="m1.367,20.7367l-0.3147,1.2211l5.3453,0l3.1268,2.807 4.5735,-2.807l5.3453,0l0.3147,-1.2211l-5.4373,0l-4.4626,2.734 -3.0535,-2.734z"
|
||||
android:strokeLineJoin="miter"
|
||||
android:strokeWidth="0.591009"
|
||||
android:fillColor="#000000"
|
||||
android:strokeColor="#00000000"
|
||||
android:fillType="evenOdd"
|
||||
android:strokeLineCap="butt"/>
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="26dp" android:height="26dp" android:tint="#7E7E7E" android:viewportWidth="26" android:viewportHeight="26">
|
||||
<path android:pathData="M11.711 16.328a4.854 7.133 75.802 0 1-5.603-5.02 4.854 7.133 75.802 0 1 8.19-5.021 4.854 7.133 75.802 0 1 5.603 5.02 4.854 7.133 75.802 0 1-8.19 5.02m9.775-2.25l4.519-2.77-3.091-2.77 1.011-3.924h-5.39l-3.091-2.77-4.519 2.77h-5.39L4.523 8.537l-4.518 2.77 3.09 2.77L2.086 18h5.39l3.091 2.77L15.085 18h5.391z" android:strokeWidth="1.01966" android:fillColor="#000000"/>
|
||||
<path android:pathData="M4.273 11.632h4.094l3.48-4.207 1.037 4.593 2.684-2.282h7.458l-0.86 1.16-6.05 0.001-4.35 3.773-0.86-3.804-1.612 2.011h-4.03z" android:strokeWidth="1.01966" android:fillColor="#000000"/>
|
||||
<path android:pathData="M1.87 18.747l-0.314 1.221H6.9l3.13 2.807 4.573-2.807h5.345l0.315-1.22h-5.438l-4.462 2.733-3.056-2.734z" android:strokeWidth="0.591009" android:fillColor="#000000" android:fillType="evenOdd"/>
|
||||
<path android:pathData="M1.367 20.737l-0.315 1.22h5.346l3.126 2.808 4.574-2.807h5.345l0.315-1.221H14.32L9.858 23.47l-3.054-2.734z" android:strokeWidth="0.591009" android:fillColor="#000000" android:fillType="evenOdd"/>
|
||||
</vector>
|
||||
|
@ -1,10 +0,0 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24"
|
||||
android:tint="?attr/colorControlNormal">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M3,5L1,5v16c0,1.1 0.9,2 2,2h16v-2L3,21L3,5zM21,1L7,1c-1.1,0 -2,0.9 -2,2v14c0,1.1 0.9,2 2,2h14c1.1,0 2,-0.9 2,-2L23,3c0,-1.1 -0.9,-2 -2,-2zM21,17L7,17L7,3h14v14z"/>
|
||||
</vector>
|
@ -1,11 +0,0 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24"
|
||||
android:tint="#7E7E7E"
|
||||
>
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M18,4H6v2l6.5,6L6,18v2h12v-3h-7l5,-5 -5,-5h7V4z"/>
|
||||
</vector>
|
@ -1,10 +1,3 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="#7E7E7E"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M11.57,13.16c-1.36,0.28 -2.17,1.16 -2.17,2.41 0,1.34 1.11,2.42 2.49,2.42 2.05,0 3.71,-1.66 3.71,-3.71 0,-1.07 -0.15,-2.12 -0.46,-3.12 -0.79,1.07 -2.2,1.72 -3.57,2zM13.5,0.67s0.74,2.65 0.74,4.8c0,2.06 -1.35,3.73 -3.41,3.73 -2.07,0 -3.63,-1.67 -3.63,-3.73l0.03,-0.36C5.21,7.51 4,10.62 4,14c0,4.42 3.58,8 8,8s8,-3.58 8,-8C20,8.61 17.41,3.8 13.5,0.67zM12,20c-3.31,0 -6,-2.69 -6,-6 0,-1.53 0.3,-3.04 0.86,-4.43 1.01,1.01 2.41,1.63 3.97,1.63 2.66,0 4.75,-1.83 5.28,-4.43C17.34,8.97 18,11.44 18,14c0,3.31 -2.69,6 -6,6z" />
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:tint="#7E7E7E" android:viewportWidth="24" android:viewportHeight="24">
|
||||
<path android:fillColor="@android:color/white" android:pathData="M11.57 13.16c-1.36 0.28-2.17 1.16-2.17 2.41 0 1.34 1.11 2.42 2.49 2.42 2.05 0 3.71-1.66 3.71-3.71 0-1.07-0.15-2.12-0.46-3.12-0.79 1.07-2.2 1.72-3.57 2zM13.5 0.67s0.74 2.65 0.74 4.8c0 2.06-1.35 3.73-3.41 3.73-2.07 0-3.63-1.67-3.63-3.73l0.03-0.36C5.21 7.51 4 10.62 4 14c0 4.42 3.58 8 8 8s8-3.58 8-8c0-5.39-2.59-10.2-6.5-13.33zM12 20c-3.31 0-6-2.69-6-6 0-1.53 0.3-3.04 0.86-4.43 1.01 1.01 2.41 1.63 3.97 1.63 2.66 0 4.75-1.83 5.28-4.43C17.34 8.97 18 11.44 18 14c0 3.31-2.69 6-6 6z"/>
|
||||
</vector>
|
||||
|
@ -1,10 +1,3 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24"
|
||||
android:tint="#7E7E7E"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
android:fillColor="#FF000000"
|
||||
android:pathData="m13.5,0.67c0,0 0.74,2.65 0.74,4.8 0,2.06 -1.35,3.73 -3.41,3.73C8.76,9.2 7.2,7.53 7.2,5.47L7.23,5.11C5.21,7.51 4,10.62 4,14c0,4.42 3.58,8 8,8 4.42,0 8,-3.58 8,-8C20,8.61 17.41,3.8 13.5,0.67ZM12,20C8.69,20 6,17.31 6,14 6,12.47 6.3,10.96 6.86,9.57c1.01,1.01 2.41,1.63 3.97,1.63 2.66,0 4.75,-1.83 5.28,-4.43 1.23,2.2 1.89,4.67 1.89,7.23 0,3.31 -2.69,6 -6,6z"/>
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:viewportWidth="24" android:tint="#7E7E7E" android:viewportHeight="24">
|
||||
<path android:fillColor="#FF000000" android:pathData="M13.5 0.67s0.74 2.65 0.74 4.8c0 2.06-1.35 3.73-3.41 3.73-2.07 0-3.63-1.67-3.63-3.73l0.03-0.36C5.21 7.51 4 10.62 4 14c0 4.42 3.58 8 8 8s8-3.58 8-8c0-5.39-2.59-10.2-6.5-13.33zM12 20c-3.31 0-6-2.69-6-6 0-1.53 0.3-3.04 0.86-4.43 1.01 1.01 2.41 1.63 3.97 1.63 2.66 0 4.75-1.83 5.28-4.43C17.34 8.97 18 11.44 18 14c0 3.31-2.69 6-6 6z"/>
|
||||
</vector>
|
||||
|
@ -1,10 +1,3 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:height="24dp"
|
||||
android:viewportHeight="24"
|
||||
android:viewportWidth="24"
|
||||
android:tint="#7E7E7E"
|
||||
android:width="24dp">
|
||||
<path
|
||||
android:fillColor="#000"
|
||||
android:pathData="M10.74,11.72C11.21,12.95 11.16,14.23 9.75,14.74C6.85,15.81 6.2,13 6.16,12.86L10.74,11.72M5.71,10.91L10.03,9.84C9.84,8.79 10.13,7.74 10.13,6.5C10.13,4.82 8.8,1.53 6.68,2.06C4.26,2.66 3.91,5.35 4,6.65C4.12,7.95 5.64,10.73 5.71,10.91M17.85,19.85C17.82,20 17.16,22.8 14.26,21.74C12.86,21.22 12.8,19.94 13.27,18.71L17.85,19.85M20,13.65C20.1,12.35 19.76,9.65 17.33,9.05C15.22,8.5 13.89,11.81 13.89,13.5C13.89,14.73 14.17,15.78 14,16.83L18.3,17.9C18.38,17.72 19.89,14.94 20,13.65Z" />
|
||||
</vector>
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:height="24dp" android:viewportHeight="24" android:viewportWidth="24" android:tint="#7E7E7E" android:width="24dp">
|
||||
<path android:fillColor="#000" android:pathData="M10.74 11.72c0.47 1.23 0.42 2.51-0.99 3.02-2.9 1.07-3.55-1.74-3.59-1.88l4.58-1.14m-5.03-0.81l4.32-1.07c-0.19-1.05 0.1-2.1 0.1-3.34 0-1.68-1.33-4.97-3.45-4.44C4.26 2.66 3.91 5.35 4 6.65c0.12 1.3 1.64 4.08 1.71 4.26m12.14 8.94c-0.03 0.15-0.69 2.95-3.59 1.89-1.4-0.52-1.46-1.8-0.99-3.03l4.58 1.14m2.15-6.2c0.1-1.3-0.24-4-2.67-4.6-2.11-0.55-3.44 2.76-3.44 4.45 0 1.23 0.28 2.28 0.11 3.33l4.3 1.07c0.08-0.18 1.59-2.96 1.7-4.25z"/>
|
||||
</vector>
|
||||
|
@ -1,15 +1,4 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24"
|
||||
android:tint="#7E7E7E"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
android:fillColor="#FF000000"
|
||||
android:pathData="m6.4801,14.3793c0.3823,1.0311 0.3416,2.104 -0.8053,2.5316C3.3159,17.8078 2.7872,15.4522 2.7547,15.3349l3.7255,-0.9556M2.3886,13.7003 L5.9026,12.8033c-0.1546,-0.8802 0.0813,-1.7604 0.0813,-2.7998 0,-1.4083 -1.0819,-4.1662 -2.8063,-3.7219 -1.9685,0.503 -2.2532,2.7579 -2.18,3.8476 0.0976,1.0897 1.334,3.4201 1.391,3.571m9.8749,7.4941C12.2392,21.3201 11.7023,23.6672 9.3434,22.7787 8.2046,22.3428 8.1558,21.2698 8.5381,20.2387l3.7255,0.9556m1.7489,-5.1972c0.0813,-1.0897 -0.1952,-3.3531 -2.1718,-3.856 -1.7163,-0.461 -2.7982,2.3136 -2.7982,3.7303 0,1.0311 0.2278,1.9112 0.0895,2.7914l3.4977,0.8969c0.0651,-0.1509 1.2933,-2.4813 1.3828,-3.5626z"
|
||||
android:strokeWidth="0.999999"/>
|
||||
<path
|
||||
android:fillColor="#FF000000"
|
||||
android:pathData="M14.7308,7.4903C14.986,8.2348 14.9589,9.0096 14.1934,9.3183 12.6189,9.9659 12.266,8.2651 12.2443,8.1803L14.7308,7.4903M12,7 L14.3454,6.3523c-0.1032,-0.6356 0.0543,-1.2711 0.0543,-2.0217 0,-1.0169 -0.7221,-3.0083 -1.873,-2.6875 -1.3138,0.3632 -1.5039,1.9914 -1.455,2.7783C11.1368,5.2083 11.962,6.891 12,7m6.5909,5.4113c-0.0162,0.0908 -0.3746,1.7856 -1.949,1.144 -0.7601,-0.3148 -0.7926,-1.0895 -0.5375,-1.834l2.4865,0.69m1.1673,-3.7528c0.0543,-0.7869 -0.1303,-2.4212 -1.4496,-2.7843 -1.1455,-0.3329 -1.8676,1.6706 -1.8676,2.6935 0,0.7445 0.152,1.3801 0.0597,2.0156l2.3345,0.6477c0.0435,-0.109 0.8632,-1.7917 0.9229,-2.5725z"
|
||||
android:strokeWidth="0.999998"/>
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:viewportWidth="24" android:tint="#7E7E7E" android:viewportHeight="24">
|
||||
<path android:fillColor="#FF000000" android:pathData="M6.48 14.38c0.382 1.03 0.342 2.103-0.805 2.53-2.36 0.898-2.888-1.458-2.92-1.575l3.725-0.956M2.39 13.7l3.514-0.897c-0.155-0.88 0.08-1.76 0.08-2.8 0-1.408-1.081-4.166-2.805-3.721-1.969 0.503-2.254 2.758-2.18 3.847 0.097 1.09 1.334 3.42 1.39 3.571m9.875 7.494c-0.024 0.126-0.56 2.473-2.92 1.585-1.138-0.436-1.187-1.51-0.805-2.54l3.726 0.955m1.749-5.197c0.08-1.09-0.196-3.353-2.172-3.856-1.717-0.46-2.799 2.314-2.799 3.73 0 1.032 0.228 1.912 0.09 2.792l3.498 0.897c0.065-0.151 1.293-2.482 1.382-3.563z" android:strokeWidth="0.999999"/>
|
||||
<path android:fillColor="#FF000000" android:pathData="M14.73 7.49c0.256 0.745 0.229 1.52-0.537 1.828-1.574 0.648-1.927-1.053-1.949-1.138l2.487-0.69M12 7l2.345-0.648C14.242 5.717 14.4 5.082 14.4 4.331c0-1.017-0.722-3.009-1.873-2.688-1.314 0.363-1.504 1.991-1.455 2.778C11.137 5.208 11.962 6.891 12 7m6.59 5.411c-0.015 0.091-0.374 1.786-1.948 1.144-0.76-0.314-0.793-1.09-0.538-1.834l2.487 0.69m1.167-3.752c0.054-0.787-0.13-2.422-1.45-2.785-1.145-0.333-1.867 1.67-1.867 2.694 0 0.744 0.152 1.38 0.06 2.015l2.334 0.648c0.044-0.109 0.863-1.792 0.923-2.572z" android:strokeWidth="0.999998"/>
|
||||
</vector>
|
||||
|
Loading…
Reference in New Issue
Block a user