Snap for 8468820 from 467b85d088 to tm-release
Change-Id: Ic7cf4d2da171ee54dcfd3e5ad8bcbb776fbbc30f
This commit is contained in:
@@ -3319,6 +3319,22 @@
|
||||
android:value="@string/menu_key_notifications"/>
|
||||
</activity>
|
||||
|
||||
<!-- Application-level notification settings page, same as above but only accessible
|
||||
internally from system server -->
|
||||
<activity android:name="Settings$NotificationReviewPermissionsActivity"
|
||||
android:label="@string/app_notifications_title"
|
||||
android:icon="@drawable/ic_notifications"
|
||||
android:exported="false">
|
||||
<intent-filter android:priority="1">
|
||||
<action android:name="android.settings.ALL_APPS_NOTIFICATION_SETTINGS_FOR_REVIEW" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
</intent-filter>
|
||||
<meta-data android:name="com.android.settings.FRAGMENT_CLASS"
|
||||
android:value="com.android.settings.applications.manageapplications.ManageApplications" />
|
||||
<meta-data android:name="com.android.settings.HIGHLIGHT_MENU_KEY"
|
||||
android:value="@string/menu_key_notifications"/>
|
||||
</activity>
|
||||
|
||||
<!-- Show application-level notification settings (app passed in as extras) -->
|
||||
<activity android:name="Settings$AppNotificationSettingsActivity"
|
||||
android:exported="true">
|
||||
|
||||
@@ -26,5 +26,6 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_marginStart="24dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:theme="@style/Widget.PopupWindow.Settings"/>
|
||||
</FrameLayout>
|
||||
|
||||
@@ -13770,12 +13770,6 @@
|
||||
<!-- Title for if toggle access is disabled by carrier [CHAR LIMIT=NONE] -->
|
||||
<string name="enable_2g_summary_disabled_carrier"><xliff:g id="carrier_name_2g" example="Google Fi">%1$s</xliff:g> requires 2G to be available</string>
|
||||
|
||||
|
||||
<!-- Label for extra app info settings for a specific app [CHAR LIMIT=40] -->
|
||||
<string name="extra_app_info_label" translatable="false"></string>
|
||||
<!-- Summary for extra app info settings for a specific app [CHAR LIMIT=40] -->
|
||||
<string name="extra_app_info_summary" translatable="false"></string>
|
||||
|
||||
<!-- Label for All Services preference in App info settings [CHAR LIMIT=40] -->
|
||||
<string name="app_info_all_services_label">All Services</string>
|
||||
|
||||
|
||||
@@ -77,12 +77,6 @@
|
||||
android:summary="@string/summary_placeholder"
|
||||
settings:controller="com.android.settings.applications.appinfo.AppDataUsagePreferenceController" />
|
||||
|
||||
<Preference
|
||||
android:key="extra_app_info_settings"
|
||||
android:title="@string/extra_app_info_label"
|
||||
android:summary="@string/extra_app_info_summary"
|
||||
settings:controller="com.android.settings.applications.appinfo.ExtraAppInfoPreferenceController" />
|
||||
|
||||
<Preference
|
||||
android:key="time_spent_in_app"
|
||||
android:title="@string/time_spent_in_app_pref_title"
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
|
||||
<PreferenceCategory
|
||||
android:key="previously_connected_devices"
|
||||
android:title="@string/connected_device_previously_connected_title"
|
||||
android:title="@string/connected_device_saved_title"
|
||||
settings:controller="com.android.settings.connecteddevice.PreviouslyConnectedDevicePreferenceController">
|
||||
|
||||
<Preference
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
<PreferenceScreen
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:settings="http://schemas.android.com/apk/res-auto"
|
||||
android:title="@string/connected_device_previously_connected_screen_title">
|
||||
android:title="@string/connected_device_saved_title">
|
||||
|
||||
<PreferenceCategory
|
||||
android:key="saved_device_list"
|
||||
|
||||
@@ -295,6 +295,7 @@ public class Settings extends SettingsActivity {
|
||||
public static class AppBubbleNotificationSettingsActivity extends SettingsActivity { /* empty */ }
|
||||
public static class NotificationAssistantSettingsActivity extends SettingsActivity{ /* empty */ }
|
||||
public static class NotificationAppListActivity extends SettingsActivity { /* empty */ }
|
||||
public static class NotificationReviewPermissionsActivity extends SettingsActivity { /* empty */ }
|
||||
public static class AppNotificationSettingsActivity extends SettingsActivity { /* empty */ }
|
||||
public static class ChannelNotificationSettingsActivity extends SettingsActivity { /* empty */ }
|
||||
public static class ChannelGroupNotificationSettingsActivity extends SettingsActivity { /* empty */ }
|
||||
|
||||
@@ -315,16 +315,25 @@ public class ManageApplications extends InstrumentedFragment
|
||||
mListType = LIST_TYPE_WIFI_ACCESS;
|
||||
} else if (className.equals(Settings.ManageExternalStorageActivity.class.getName())) {
|
||||
mListType = LIST_MANAGE_EXTERNAL_STORAGE;
|
||||
} else if (className.equals(Settings.MediaManagementAppsActivity.class.getName())) {
|
||||
} else if (className.equals(Settings.MediaManagementAppsActivity.class.getName())) {
|
||||
mListType = LIST_TYPE_MEDIA_MANAGEMENT_APPS;
|
||||
} else if (className.equals(Settings.AlarmsAndRemindersActivity.class.getName())) {
|
||||
mListType = LIST_TYPE_ALARMS_AND_REMINDERS;
|
||||
} else if (className.equals(Settings.NotificationAppListActivity.class.getName())) {
|
||||
} else if (className.equals(Settings.NotificationAppListActivity.class.getName())
|
||||
|| className.equals(
|
||||
Settings.NotificationReviewPermissionsActivity.class.getName())) {
|
||||
mListType = LIST_TYPE_NOTIFICATION;
|
||||
mUsageStatsManager = IUsageStatsManager.Stub.asInterface(
|
||||
ServiceManager.getService(Context.USAGE_STATS_SERVICE));
|
||||
mNotificationBackend = new NotificationBackend();
|
||||
mSortOrder = R.id.sort_order_recent_notification;
|
||||
if (className.equals(Settings.NotificationReviewPermissionsActivity.class.getName())) {
|
||||
// Special-case for a case where a user is directed to the all apps notification
|
||||
// preferences page via a notification prompt to review permissions settings.
|
||||
android.provider.Settings.Secure.putInt(getContext().getContentResolver(),
|
||||
android.provider.Settings.Secure.REVIEW_PERMISSIONS_NOTIFICATION_STATE,
|
||||
1); // USER_INTERACTED
|
||||
}
|
||||
} else if (className.equals(AppLocaleDetails.class.getName())) {
|
||||
mListType = LIST_TYPE_APPS_LOCALE;
|
||||
} else {
|
||||
@@ -915,7 +924,9 @@ public class ManageApplications extends InstrumentedFragment
|
||||
screenTitle = R.string.media_management_apps_title;
|
||||
} else if (className.equals(Settings.AlarmsAndRemindersActivity.class.getName())) {
|
||||
screenTitle = R.string.alarms_and_reminders_title;
|
||||
} else if (className.equals(Settings.NotificationAppListActivity.class.getName())) {
|
||||
} else if (className.equals(Settings.NotificationAppListActivity.class.getName())
|
||||
|| className.equals(
|
||||
Settings.NotificationReviewPermissionsActivity.class.getName())) {
|
||||
screenTitle = R.string.app_notifications_title;
|
||||
} else if (className.equals(AppLocaleDetails.class.getName())) {
|
||||
screenTitle = R.string.app_locales_picker_menu_title;
|
||||
|
||||
@@ -18,14 +18,7 @@ package com.android.settings.fuelgauge;
|
||||
|
||||
import android.content.ComponentName;
|
||||
|
||||
/**
|
||||
* Feature provider for battery settings usage.
|
||||
*/
|
||||
/** Feature provider for battery settings usage. */
|
||||
public interface BatterySettingsFeatureProvider {
|
||||
|
||||
/**
|
||||
* Get replacement activity for a given activity or fragment path.
|
||||
*/
|
||||
ComponentName getReplacingActivity(ComponentName originalActivity);
|
||||
|
||||
}
|
||||
|
||||
@@ -16,12 +16,9 @@
|
||||
|
||||
package com.android.settings.fuelgauge;
|
||||
|
||||
import android.content.ComponentName;
|
||||
import android.content.Context;
|
||||
|
||||
/**
|
||||
* Feature provider implementation for battery settings usage.
|
||||
*/
|
||||
/** Feature provider implementation for battery settings usage. */
|
||||
public class BatterySettingsFeatureProviderImpl implements BatterySettingsFeatureProvider {
|
||||
|
||||
protected Context mContext;
|
||||
@@ -29,9 +26,4 @@ public class BatterySettingsFeatureProviderImpl implements BatterySettingsFeatur
|
||||
public BatterySettingsFeatureProviderImpl(Context context) {
|
||||
mContext = context.getApplicationContext();
|
||||
}
|
||||
|
||||
@Override
|
||||
public ComponentName getReplacingActivity(ComponentName originalActivity) {
|
||||
return originalActivity;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -28,7 +28,6 @@ import androidx.preference.PreferenceCategory;
|
||||
import androidx.preference.PreferenceScreen;
|
||||
|
||||
import com.android.settings.R;
|
||||
import com.android.settings.core.BasePreferenceController;
|
||||
import com.android.settings.dashboard.DashboardFragment;
|
||||
import com.android.settings.dashboard.profileselector.ProfileSelectFragment;
|
||||
import com.android.settingslib.applications.RecentAppOpsAccess;
|
||||
@@ -41,8 +40,7 @@ import java.util.List;
|
||||
/**
|
||||
* Preference controller that handles the display of apps that access locations.
|
||||
*/
|
||||
public class RecentLocationAccessPreferenceController extends LocationBasePreferenceController
|
||||
implements BasePreferenceController.UiBlocker {
|
||||
public class RecentLocationAccessPreferenceController extends LocationBasePreferenceController {
|
||||
public static final int MAX_APPS = 3;
|
||||
@VisibleForTesting
|
||||
RecentAppOpsAccess mRecentLocationApps;
|
||||
@@ -131,16 +129,12 @@ public class RecentLocationAccessPreferenceController extends LocationBasePrefer
|
||||
banner.setSelectable(false);
|
||||
mCategoryRecentLocationRequests.addPreference(banner);
|
||||
}
|
||||
|
||||
if (mUiBlockListener != null) {
|
||||
mUiBlockListener.onBlockerWorkFinished(this);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onLocationModeChanged(int mode, boolean restricted) {
|
||||
boolean enabled = mLocationEnabler.isEnabled(mode);
|
||||
updatePreferenceVisibilityDelegate(mCategoryRecentLocationRequests, enabled);
|
||||
mCategoryRecentLocationRequests.setVisible(enabled);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -20,13 +20,11 @@ import android.content.Context;
|
||||
import androidx.preference.Preference;
|
||||
import androidx.preference.PreferenceScreen;
|
||||
|
||||
import com.android.settings.core.BasePreferenceController;
|
||||
|
||||
/**
|
||||
* Preference controller that handles the "See All" button for recent location access.
|
||||
*/
|
||||
public class RecentLocationAccessSeeAllButtonPreferenceController extends
|
||||
LocationBasePreferenceController implements BasePreferenceController.UiBlocker {
|
||||
LocationBasePreferenceController {
|
||||
|
||||
private Preference mPreference;
|
||||
|
||||
@@ -46,6 +44,6 @@ public class RecentLocationAccessSeeAllButtonPreferenceController extends
|
||||
@Override
|
||||
public void onLocationModeChanged(int mode, boolean restricted) {
|
||||
boolean enabled = mLocationEnabler.isEnabled(mode);
|
||||
updatePreferenceVisibilityDelegate(mPreference, enabled);
|
||||
mPreference.setVisible(enabled);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user