Этот коммит содержится в:
Anton Tananaev
2019-11-11 23:51:04 -08:00
родитель 93456bf7fb
Коммит 4c6c79b6a2
9 изменённых файлов: 6 добавлений и 96 удалений
-2
Просмотреть файл
@@ -48,8 +48,6 @@
<activity android:name=".StatusActivity"/>
<activity android:name=".AboutActivity"/>
<activity
android:name=".ShortcutActivity"
android:label="@string/menu_shortcuts">
-39
Просмотреть файл
@@ -1,39 +0,0 @@
/*
* Copyright 2012 - 2017 Anton Tananaev (anton@traccar.org)
*
* 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.
*/
package org.traccar.client;
import android.content.pm.PackageManager.NameNotFoundException;
import android.os.Bundle;
import androidx.appcompat.app.AppCompatActivity;
import android.util.Log;
import android.widget.TextView;
public class AboutActivity extends AppCompatActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.about);
TextView title = findViewById(R.id.title);
try {
title.setText(title.getText() + " " + getPackageManager().getPackageInfo(this.getPackageName(), 0).versionName);
} catch (NameNotFoundException e) {
Log.w(AboutActivity.class.getSimpleName(), e);
}
}
}
-3
Просмотреть файл
@@ -195,9 +195,6 @@ public class MainFragment extends PreferenceFragmentCompat implements OnSharedPr
if (item.getItemId() == R.id.status) {
startActivity(new Intent(getActivity(), StatusActivity.class));
return true;
} else if (item.getItemId() == R.id.about) {
startActivity(new Intent(getActivity(), AboutActivity.class));
return true;
}
return super.onOptionsItemSelected(item);
}
-37
Просмотреть файл
@@ -1,37 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_toRightOf="@+id/logo"
android:layout_toEndOf="@+id/logo"
android:padding="@dimen/spacing_normal"
android:orientation="vertical" >
<TextView
android:id="@+id/title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="@dimen/spacing_normal"
android:text="@string/app_name"
android:textAppearance="?android:attr/textAppearanceLarge" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="@dimen/spacing_normal"
android:text="@string/about_description" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="@dimen/spacing_normal"
android:text="@string/about_license" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/about_web"
android:autoLink="web" />
</LinearLayout>
-5
Просмотреть файл
@@ -8,9 +8,4 @@
android:title="@string/menu_status"
app:showAsAction="ifRoom" />
<item
android:id="@+id/about"
android:title="@string/menu_about"
app:showAsAction="never" />
</menu>
-4
Просмотреть файл
@@ -28,12 +28,8 @@
<string name="settings_foreground_title">Foreground service</string>
<string name="settings_foreground_summary">Increase service priority</string>
<string name="menu_status">Status</string>
<string name="menu_about">About</string>
<string name="menu_shortcuts">Add shortcuts</string>
<string name="menu_clear">Clear</string>
<string name="about_description">Real time GPS tracker for Android devices. Compatible with Traccar Server and other tracking systems.</string>
<string name="about_license">This application is free and open source, source code is licensed under Apache License Version 2.0 and available on GitHub.</string>
<string name="about_web">For more information visit\nwww.traccar.org/client</string>
<string name="status_service_create">Service started</string>
<string name="status_service_destroy">Service stopped</string>
<string name="status_send_success">Send successfully</string>