Commit Graph

9 Commits

Author SHA1 Message Date
Fan Zhang
23f8d59d02 Sort imports
Having consistent import order will reduce chance of merge
conflict between internal and external master

Test: rebuild
Change-Id: I0b1a170967ddcce7f388603fd521f6ed1eeba30b
2018-08-28 22:13:15 +00:00
Fan Zhang
f1f0f8bea6 Convert CreateShortcut to DashboardFragment
Created a new xml and CreateShortcutPreferenceController to deal with
querying package manager and display list on UI.

Bug: 74806595
Test: robotests
Change-Id: I0945245c3856d12b7751d26fca324d2dbf31b230
2018-06-22 11:30:56 -07:00
Fan Zhang
c7162cd24d Reorder and clean up imports.
Test: rebuild
Change-Id: I178485c84ae7146f991fd77b6d7504b029942a68
2018-06-18 15:45:09 -07:00
Aurimas Liutikas
e0069d332d Migrate Settings to androidx.
Test: make Settings
Bug: 76692459
Change-Id: I941dea40562170649bf056e675cc32e5163c0e39
2018-04-20 12:52:29 -07:00
Doris Ling
f2d7680d2c Update launch intent flags for settings shortcut widgets.
- earlier changes were made to the intent flags when creating new
settings shortcut to ensure that it is launching a new task. However,
ShortcutManager is actually caching existing shortcut info, and it will
continue to use the existing shortcut info unless we explicitly update
the info.
- when rebooting from build upgrade, we will go through all existing
shortcut to update the launch intent flags to ensure that the shortcut
info is update to date.

Change-Id: Iee2365d9aec64a47b193e3c9be443c252504815b
Fixes: 76395879
Test: make RunSettingsRoboTests
2018-04-05 10:20:26 -07:00
Fan Zhang
409eab14de Fix shortcut icon in launcher
When building icon for shortcut, check if the icon is LayerDrawable.
- If yes, only take the second layer (foreground).

Also move the class to shortcut package

Change-Id: I3513dbeb6509f11aa70ab3230d441e268ca9356d
Fixes: 72553870
Test: atest
2018-01-29 11:39:48 -08:00
Kenny Guy
4761da3b73 Disable managed profile version of shortcut picker.
Don't show managed profile version of shortcut
picker as it lunaches same activities as personal
one.

Test: manual - check badged shortcut isn't present in launcher.
Bug: 38333213
Change-Id: Iade6595255524a8dbf223a70a6c8312087258c23
2017-05-17 16:44:01 +01:00
Gustav Sennton
4d3334c50b Update WebView implementation Dev Setting - new looks + descriptions.
Now that we are changing the WebView package mechanism so that a package
can only be used as WebView implementation if that package is enabled
for all users of the device we need to tell the user why a package can't
be chosen as WebView implementation.
With this CL we do so in the 'Set WebView Implementation' Developer
Setting.

We code for the WebView implementation Developer Setting is now based on
the same code as that of the Debug App Developer Setting.

Bug: 32894154
Test: Ensure WebView Implementation setting shows correct packages.
Test: Ensure WebView Implementation setting shows correct descriptions
for why a package is not usable - including the case where packages are
disabled/uninstalled for a second user.
Test: Ensure the summary for the WebView Implmentation setting is
updated after changing WebView package.
Test: Ensure the WebView package Activity
(Settings.ACTION_WEBVIEW_SETTINGS) is similar to the Dev Setting.
Test: ensure non-admin user cannot start WV-picker activity through
'adb shell am start -n com.android.settings/.WebViewImplementation'

Change-Id: Ia6e6e9e12ce8f8f45ec539807cd0c6479acb8ecb
2017-01-23 18:34:11 +00:00
Gustav Sennton
66313bb11d Disable WebViewSetting for non-admin users.
For an app to be able to know whether the WebViewSetting is enabled for
a user we disable the setting at boot for non-admin users. In this way
an app can call intent.resolveActivity[Info] for the WebViewSetting
intent to check whether the WebViewSetting is enabled before linking to
it.

Bug: 28034166
Change-Id: I33b3fa10a38f2a2600cddd0891ef746126abdd61
2016-05-12 11:13:26 +01:00