forked from upstream-mirrors/OpenTracks
Add support to show both moving time and total time.
This commit is contained in:
@@ -29,21 +29,32 @@ limitations under the License.
|
||||
<!-- Total time/moving time -->
|
||||
<TableRow>
|
||||
<TextView
|
||||
android:id="@+id/stats_total_time_label"
|
||||
android:text="@string/stats_total_time"
|
||||
style="@style/StatsLabel" />
|
||||
<TextView
|
||||
android:id="@+id/stats_moving_time_label"
|
||||
android:layout_column="2"
|
||||
android:text="@string/stats_moving_time"
|
||||
style="@style/StatsLabel" />
|
||||
</TableRow>
|
||||
<TableRow>
|
||||
<TextView
|
||||
android:id="@+id/stats_total_time_value"
|
||||
style="@style/StatsValue" />
|
||||
<TextView
|
||||
android:id="@+id/stats_moving_time_spacer"
|
||||
style="@style/StatsSpacer" />
|
||||
<TextView
|
||||
android:id="@+id/stats_moving_time_value"
|
||||
style="@style/StatsValue" />
|
||||
</TableRow>
|
||||
<!-- Average speed/average moving speed and max speed (average pace/average moving pace and fastest pace) -->
|
||||
<!-- Average speed/average moving speed (average pace/average moving pace) -->
|
||||
<TableRow>
|
||||
<TextView
|
||||
android:id="@+id/stats_average_speed_label"
|
||||
style="@style/StatsLabel" />
|
||||
<TextView
|
||||
android:id="@+id/stats_max_speed_label"
|
||||
android:id="@+id/stats_average_moving_speed_label"
|
||||
android:layout_column="2"
|
||||
style="@style/StatsLabel" />
|
||||
</TableRow>
|
||||
@@ -51,7 +62,20 @@ limitations under the License.
|
||||
<TextView
|
||||
android:id="@+id/stats_average_speed_value"
|
||||
style="@style/StatsValue" />
|
||||
<TextView style="@style/StatsSpacer" />
|
||||
<TextView
|
||||
android:id="@+id/stats_average_moving_speed_spacer"
|
||||
style="@style/StatsSpacer" />
|
||||
<TextView
|
||||
android:id="@+id/stats_average_moving_speed_value"
|
||||
style="@style/StatsValue" />
|
||||
</TableRow>
|
||||
<!-- Max speed (fastest pace) -->
|
||||
<TableRow>
|
||||
<TextView
|
||||
android:id="@+id/stats_max_speed_label"
|
||||
style="@style/StatsLabel" />
|
||||
</TableRow>
|
||||
<TableRow>
|
||||
<TextView
|
||||
android:id="@+id/stats_max_speed_value"
|
||||
style="@style/StatsValue" />
|
||||
|
||||
@@ -39,10 +39,7 @@ limitations under the License.
|
||||
android:layout_width="0dp"
|
||||
android:orientation="vertical"
|
||||
android:paddingLeft="8dp" >
|
||||
<LinearLayout
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="fill_parent"
|
||||
android:orientation="horizontal" >
|
||||
<LinearLayout style="@style/TrackWidgetStat" >
|
||||
<TextView
|
||||
android:id="@+id/track_widget_distance_value"
|
||||
style="@style/TrackWidgetValue" />
|
||||
@@ -50,34 +47,48 @@ limitations under the License.
|
||||
android:text="@string/stats_total_distance"
|
||||
style="@style/TrackWidgetLabel" />
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:background="@color/track_widget_line"
|
||||
android:layout_height="1dp"
|
||||
android:layout_width="fill_parent" />
|
||||
<LinearLayout
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="fill_parent"
|
||||
android:orientation="horizontal" >
|
||||
<LinearLayout style="@style/TrackWidgetSeparator" />
|
||||
<LinearLayout style="@style/TrackWidgetStat" >
|
||||
<TextView
|
||||
android:id="@+id/track_widget_time_value"
|
||||
android:id="@+id/track_widget_total_time_value"
|
||||
style="@style/TrackWidgetValue" />
|
||||
<TextView
|
||||
android:id="@+id/track_widget_time_label"
|
||||
android:text="@string/stats_total_time"
|
||||
style="@style/TrackWidgetLabel" />
|
||||
</LinearLayout>
|
||||
<LinearLayout style="@style/TrackWidgetSeparator" />
|
||||
<LinearLayout style="@style/TrackWidgetStat" >
|
||||
<TextView
|
||||
android:id="@+id/track_widget_average_speed_value"
|
||||
style="@style/TrackWidgetValue" />
|
||||
<TextView
|
||||
android:id="@+id/track_widget_average_speed_label"
|
||||
style="@style/TrackWidgetLabel" />
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:background="@color/track_widget_line"
|
||||
android:layout_height="1dp"
|
||||
android:layout_width="fill_parent" />
|
||||
android:id="@+id/track_widget_moving_time_separator"
|
||||
style="@style/TrackWidgetSeparator" />
|
||||
<LinearLayout
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="fill_parent"
|
||||
android:orientation="horizontal" >
|
||||
android:id="@+id/track_widget_moving_time_stat"
|
||||
style="@style/TrackWidgetStat" >
|
||||
<TextView
|
||||
android:id="@+id/track_widget_speed_value"
|
||||
android:id="@+id/track_widget_moving_time_value"
|
||||
style="@style/TrackWidgetValue" />
|
||||
<TextView
|
||||
android:id="@+id/track_widget_speed_label"
|
||||
android:text="@string/stats_moving_time"
|
||||
style="@style/TrackWidgetLabel" />
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:id="@+id/track_widget_average_moving_speed_separator"
|
||||
style="@style/TrackWidgetSeparator" />
|
||||
<LinearLayout
|
||||
android:id="@+id/track_widget_average_moving_speed_stat"
|
||||
style="@style/TrackWidgetStat" >
|
||||
<TextView
|
||||
android:id="@+id/track_widget_average_moving_speed_value"
|
||||
style="@style/TrackWidgetValue" />
|
||||
<TextView
|
||||
android:id="@+id/track_widget_average_moving_speed_label"
|
||||
style="@style/TrackWidgetLabel" />
|
||||
</LinearLayout>
|
||||
<ImageButton
|
||||
|
||||
@@ -53,7 +53,7 @@ limitations under the License.
|
||||
<string name="stats_show_coordinate_key">statsShowCoordinate</string>
|
||||
<string name="stats_show_elevation_key">statsShowElevation</string>
|
||||
<string name="stats_show_grade_key">statsShowGrade</string>
|
||||
<string name="stats_use_total_time_key">statsUseTotalTime</string>
|
||||
<string name="stats_show_moving_time_key">statsShowMovingTime</string>
|
||||
<string name="track_color_mode_medium_key">trackColorModeMedium</string>
|
||||
<string name="track_color_mode_percentage_key">trackColorModePercentage</string>
|
||||
<string name="track_color_mode_slow_key">trackColorModeSlow</string>
|
||||
|
||||
@@ -2038,13 +2038,6 @@ limitations under the License.
|
||||
Character limit: ~23 (1 line)">
|
||||
Preferred rate
|
||||
</string>
|
||||
<string name="settings_stats_time_title"
|
||||
translation_description="In the 'Stats' settings, the option to change the time measurement,
|
||||
either total time or moving time.
|
||||
|
||||
Character limit: ~23 (1 line)">
|
||||
Time measurement
|
||||
</string>
|
||||
<string name="settings_stats_units_imperial"
|
||||
translation_description="In the 'Stats' settings, the option to use imperial units, with
|
||||
examples.">
|
||||
|
||||
@@ -14,7 +14,7 @@ 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.
|
||||
-->
|
||||
<resources>
|
||||
<resources xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<!-- The style for the about value -->
|
||||
<style name="AboutValue" parent="@style/TextMedium">
|
||||
<item name="android:paddingLeft">48dp</item>
|
||||
@@ -180,10 +180,6 @@ limitations under the License.
|
||||
</style>
|
||||
<!-- Theme selector -->
|
||||
<style name="ThemeSelector" parent="android:Theme" />
|
||||
<!-- The style for the track widget label -->
|
||||
<style name="TrackWidgetLabel" parent="@style/TextSmall">
|
||||
<item name="android:width">100dp</item>
|
||||
</style>
|
||||
<!-- The style for the track widget button -->
|
||||
<style name="TrackWidgetButton">
|
||||
<item name="android:layout_gravity">center_horizontal</item>
|
||||
@@ -192,6 +188,22 @@ limitations under the License.
|
||||
<item name="android:layout_width">fill_parent</item>
|
||||
<item name="android:padding">8dp</item>
|
||||
</style>
|
||||
<!-- The style for the track widget label -->
|
||||
<style name="TrackWidgetLabel" parent="@style/TextSmall">
|
||||
<item name="android:width">100dp</item>
|
||||
</style>
|
||||
<!-- The style for the track widget separator -->
|
||||
<style name="TrackWidgetSeparator">
|
||||
<item name="android:background">@color/track_widget_line</item>
|
||||
<item name="android:layout_height">1dp</item>
|
||||
<item name="android:layout_width">fill_parent</item>
|
||||
</style>
|
||||
<!-- The style for the track widget stat -->
|
||||
<style name="TrackWidgetStat">
|
||||
<item name="android:layout_height">wrap_content</item>
|
||||
<item name="android:layout_width">fill_parent</item>
|
||||
<item name="android:orientation">horizontal</item>
|
||||
</style>
|
||||
<!-- The style for the track widget value -->
|
||||
<style name="TrackWidgetValue" parent="@style/TextSmall">
|
||||
<item name="android:layout_weight">1</item>
|
||||
|
||||
@@ -26,13 +26,11 @@ limitations under the License.
|
||||
android:defaultValue="true"
|
||||
android:key="@string/report_speed_key"
|
||||
android:title="@string/settings_stats_rate_title" />
|
||||
<CheckBoxPreference
|
||||
android:defaultValue="true"
|
||||
android:key="@string/stats_use_total_time_key"
|
||||
android:summaryOff="@string/stats_moving_time"
|
||||
android:summaryOn="@string/stats_total_time"
|
||||
android:title="@string/settings_stats_time_title" />
|
||||
<PreferenceCategory android:title="@string/settings_show" >
|
||||
<CheckBoxPreference
|
||||
android:defaultValue="false"
|
||||
android:key="@string/stats_show_moving_time_key"
|
||||
android:title="@string/stats_moving_time" />
|
||||
<CheckBoxPreference
|
||||
android:defaultValue="false"
|
||||
android:key="@string/stats_show_elevation_key"
|
||||
|
||||
Reference in New Issue
Block a user