This commit is contained in:
Dennis Guse
2020-09-23 08:11:10 +02:00
parent 833a387574
commit 74e42525d4
5 changed files with 25 additions and 61 deletions
@@ -905,7 +905,7 @@ public class ChartView extends View {
for (ChartValueSeries chartValueSeries : seriesList) {
chartValueSeries.updateDimension();
}
float density = getContext().getResources().getDisplayMetrics().density;
float density = getResources().getDisplayMetrics().density;
spacer = (int) (density * SPACER);
yAxisOffset = (int) (density * Y_AXIS_OFFSET);
@@ -201,7 +201,7 @@ public class StatisticsRecordingFragment extends Fragment implements TrackDataLi
public void onActivityCreated(Bundle savedInstanceState) {
super.onActivityCreated(savedInstanceState);
recordingGpsAccuracy = Integer.parseInt(getContext().getResources().getString(R.string.recording_gps_accuracy_default));
recordingGpsAccuracy = Integer.parseInt(getResources().getString(R.string.recording_gps_accuracy_default));
handlerUpdateUI = new Handler();
@@ -31,7 +31,7 @@ public class AnnouncementUtils {
String rate;
String currentRate;
String currentRateMsg = "";
String currentRateMsg;
if (reportSpeed) {
int speedId = metricUnits ? R.plurals.voiceSpeedKilometersPerHour : R.plurals.voiceSpeedMilesPerHour;
rate = context.getResources().getQuantityString(speedId, getQuantityCount(distancePerTime), distancePerTime);
@@ -2,38 +2,31 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
android:layout_marginBottom="8dp"
android:orientation="horizontal">
<LinearLayout
android:layout_width="match_parent"
<TextView
android:id="@+id/interval_item_distance"
style="@style/TextMedium"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_marginBottom="8dp">
android:layout_weight="1"
tools:text="1 km" />
<TextView
android:id="@+id/interval_item_distance"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
style="@style/TextMedium"
tools:text="1 km" />
<TextView
android:id="@+id/interval_item_speed"
style="@style/TextMedium"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
tools:text="15 km/h" />
<TextView
android:id="@+id/interval_item_speed"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
style="@style/TextMedium"
tools:text="15 km/h" />
<TextView
android:id="@+id/interval_item_pace"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
style="@style/TextMedium"
tools:text="4:00" />
</LinearLayout>
<TextView
android:id="@+id/interval_item_pace"
style="@style/TextMedium"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
tools:text="4:00" />
</LinearLayout>
@@ -1,29 +0,0 @@
<?xml version="1.0" encoding="utf-8"?><!--
Copyright 2013 Google Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
style="@style/StatsLargeItemContainer">
<TextView
android:id="@+id/stats_activity_type_label"
style="@style/StatsLargeLabel"
android:text="@string/track_edit_activity_type_hint" />
<Spinner
android:id="@+id/stats_activity_type_icon"
style="@style/StatsLargeValue"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
</LinearLayout>