diff options
author | twyen <twyen@google.com> | 2017-09-25 13:35:19 -0700 |
---|---|---|
committer | Eric Erfanian <erfanian@google.com> | 2017-09-26 08:34:46 -0700 |
commit | 727f602e81db45b2840836fd7206114da81f08e1 (patch) | |
tree | ec51b87854b0a3f66b5b4ec1eb380adc4c1fb038 | |
parent | a8d660986f87fbfdcd7310fbc7ec0b20c3b56b10 (diff) |
Use help center for GoogleDialer about
The about in settings is removed in google dialer, it is accessed through the dialtacts overflow "Help & feedback" instead:
https://screenshot.googleplex.com/9L1kdQz6c2B
https://screenshot.googleplex.com/FqqdG6X9JTR
Note that help articles has not been migrated at this moment.
Features in the original about is placed in the overflow
https://screenshot.googleplex.com/OmCVPqwGBM9
Version info is stock google help
https://screenshot.googleplex.com/EdveVnXUSML
Privacy policy/Terms of service opens the browser to the link we had before
Open source license opens the same license activity in about.
Bug: 34872689
Test: manual
PiperOrigin-RevId: 169953610
Change-Id: Ib1c25ddecbf28293b447112cb280a8f9788692d3
-rw-r--r-- | java/com/android/dialer/about/AndroidManifest.xml | 16 | ||||
-rw-r--r-- | java/com/android/dialer/app/settings/DialerSettingsActivity.java | 15 |
2 files changed, 26 insertions, 5 deletions
diff --git a/java/com/android/dialer/about/AndroidManifest.xml b/java/com/android/dialer/about/AndroidManifest.xml index 85c750826..3d5067ade 100644 --- a/java/com/android/dialer/about/AndroidManifest.xml +++ b/java/com/android/dialer/about/AndroidManifest.xml @@ -1,10 +1,24 @@ +<!-- Copyright (C) 2017 The Android Open Source Project + + 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. +--> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.android.dialer.about"> <application android:theme="@style/Theme.AppCompat"> <activity android:name="com.android.dialer.about.LicenseMenuActivity" android:label="@string/licenseActivityLabel" - android:exported="false" + android:exported="true" android:theme="@style/Theme.AppCompat.Light"> </activity> <activity diff --git a/java/com/android/dialer/app/settings/DialerSettingsActivity.java b/java/com/android/dialer/app/settings/DialerSettingsActivity.java index 6010f92b5..6286bfc88 100644 --- a/java/com/android/dialer/app/settings/DialerSettingsActivity.java +++ b/java/com/android/dialer/app/settings/DialerSettingsActivity.java @@ -135,10 +135,12 @@ public class DialerSettingsActivity extends AppCompatPreferenceActivity { target.add(accessibilitySettingsHeader); } - Header aboutPhoneHeader = new Header(); - aboutPhoneHeader.titleRes = R.string.about_phone_label; - aboutPhoneHeader.fragment = AboutPhoneFragment.class.getName(); - target.add(aboutPhoneHeader); + if (showAbout()) { + Header aboutPhoneHeader = new Header(); + aboutPhoneHeader.titleRes = R.string.about_phone_label; + aboutPhoneHeader.fragment = AboutPhoneFragment.class.getName(); + target.add(aboutPhoneHeader); + } } private void addVoicemailSettings(List<Header> target, boolean isPrimaryUser) { @@ -208,6 +210,11 @@ public class DialerSettingsActivity extends AppCompatPreferenceActivity { return result; } + /** Whether "about" should be shown in settings. Override to hide about. */ + public boolean showAbout() { + return true; + } + /** * Returns {@code true} or {@code false} based on whether the display options setting should be * shown. For languages such as Chinese, Japanese, or Korean, display options aren't useful since |