Merge "Remove PeopleSpace icon, enable widget by default."

This commit is contained in:
Flavio Fiszman
2020-12-16 21:07:43 +00:00
committed by Android (Google) Code Review
2 changed files with 2 additions and 22 deletions

View File

@@ -570,15 +570,10 @@
<!-- People Space UI Screen -->
<activity android:name=".people.PeopleSpaceActivity"
android:label="People"
android:icon="@drawable/ic_music_note"
android:exported="true"
android:enabled="false"
android:theme="@android:style/Theme.Material.NoActionBar"
android:launchMode="singleInstance">
android:theme="@android:style/Theme.Material.NoActionBar">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<action android:name="android.appwidget.action.APPWIDGET_CONFIGURE"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>

View File

@@ -40,7 +40,6 @@ import com.android.systemui.dagger.ContextComponentHelper;
import com.android.systemui.dagger.GlobalRootComponent;
import com.android.systemui.dagger.SysUIComponent;
import com.android.systemui.dump.DumpManager;
import com.android.systemui.people.PeopleSpaceActivity;
import com.android.systemui.people.widget.PeopleSpaceWidgetProvider;
import com.android.systemui.shared.system.ThreadedRendererCompat;
import com.android.systemui.util.NotificationChannels;
@@ -126,26 +125,12 @@ public class SystemUIApplication extends Application implements
mServices[i].onBootCompleted();
}
}
// If flag SHOW_PEOPLE_SPACE is true, enable People Space launcher icon.
// TODO(b/170396074): Remove this when we don't need an icon anymore.
try {
int showPeopleSpace = Settings.Global.getInt(context.getContentResolver(),
Settings.Global.SHOW_PEOPLE_SPACE, 0);
context.getPackageManager().setComponentEnabledSetting(
new ComponentName(context, PeopleSpaceActivity.class),
showPeopleSpace == 1
? PackageManager.COMPONENT_ENABLED_STATE_ENABLED
: PackageManager.COMPONENT_ENABLED_STATE_DISABLED,
PackageManager.DONT_KILL_APP);
} catch (Exception e) {
Log.w(TAG, "Error enabling People Space launch icon:", e);
}
// If SHOW_PEOPLE_SPACE is true, enable People Space widget provider.
// TODO(b/170396074): Remove this when we don't need a widget anymore.
try {
int showPeopleSpace = Settings.Global.getInt(context.getContentResolver(),
Settings.Global.SHOW_PEOPLE_SPACE, 0);
Settings.Global.SHOW_PEOPLE_SPACE, 1);
context.getPackageManager().setComponentEnabledSetting(
new ComponentName(context, PeopleSpaceWidgetProvider.class),
showPeopleSpace == 1