From 8f6d141d84385af60ab5266bc319392f41306183 Mon Sep 17 00:00:00 2001 From: Samuel Fufa Date: Tue, 21 Jan 2020 09:58:14 -0800 Subject: [PATCH] Work toggle improvements Bug:141289979 Test:Manual Change-Id: If96845c0220816f9ffd5a5c86ec33b2674d15d1d --- .../res/layout/predicted_hotseat_edu.xml | 2 +- res/drawable/ic_corp.xml | 6 +- res/drawable/ic_corp_off.xml | 25 ++++++ res/layout/work_apps_paused.xml | 50 ++++++++++++ res/layout/work_profile_edu.xml | 2 +- res/layout/work_tab_footer.xml | 68 +++++----------- res/values/dimens.xml | 3 + res/values/strings.xml | 7 +- res/values/styles.xml | 2 + .../allapps/AllAppsContainerView.java | 67 +++++++++++++++- .../launcher3/allapps/AllAppsGridAdapter.java | 14 ---- .../allapps/AlphabeticalAppsList.java | 22 ------ .../android/launcher3/views/WorkEduView.java | 2 - .../launcher3/views/WorkFooterContainer.java | 77 ++++++++++++++++++- 14 files changed, 245 insertions(+), 102 deletions(-) create mode 100644 res/drawable/ic_corp_off.xml create mode 100644 res/layout/work_apps_paused.xml diff --git a/quickstep/recents_ui_overrides/res/layout/predicted_hotseat_edu.xml b/quickstep/recents_ui_overrides/res/layout/predicted_hotseat_edu.xml index a7cd167020..d94c665e86 100644 --- a/quickstep/recents_ui_overrides/res/layout/predicted_hotseat_edu.xml +++ b/quickstep/recents_ui_overrides/res/layout/predicted_hotseat_edu.xml @@ -34,10 +34,10 @@ android:orientation="vertical"> - + \ No newline at end of file diff --git a/res/drawable/ic_corp_off.xml b/res/drawable/ic_corp_off.xml new file mode 100644 index 0000000000..62a978741d --- /dev/null +++ b/res/drawable/ic_corp_off.xml @@ -0,0 +1,25 @@ + + + + + \ No newline at end of file diff --git a/res/layout/work_apps_paused.xml b/res/layout/work_apps_paused.xml new file mode 100644 index 0000000000..5607e788c4 --- /dev/null +++ b/res/layout/work_apps_paused.xml @@ -0,0 +1,50 @@ + + + + + + + + + \ No newline at end of file diff --git a/res/layout/work_profile_edu.xml b/res/layout/work_profile_edu.xml index a8e3d20d86..f7a529dc70 100644 --- a/res/layout/work_profile_edu.xml +++ b/res/layout/work_profile_edu.xml @@ -35,12 +35,12 @@ android:paddingRight="@dimen/bottom_sheet_edu_padding"> - - - - + android:paddingBottom="@dimen/all_apps_work_profile_tab_footer_padding_vertical" + android:orientation="horizontal" + android:paddingLeft="@dimen/all_apps_work_profile_tab_footer_padding_horizontal" + android:background="?attr/allAppsScrimColor" + android:paddingRight="@dimen/all_apps_work_profile_tab_footer_padding_horizontal" + android:paddingTop="@dimen/all_apps_work_profile_tab_footer_padding_vertical"> - - - - + android:paddingEnd="12dp" + android:textSize="16sp"/> + \ No newline at end of file diff --git a/res/values/dimens.xml b/res/values/dimens.xml index 029357380a..edae7f427c 100644 --- a/res/values/dimens.xml +++ b/res/values/dimens.xml @@ -85,6 +85,9 @@ 12dp 1dp + 20dp + 24dp + 3dp 16dp diff --git a/res/values/strings.xml b/res/values/strings.xml index 3f279f43bf..bfa92f7537 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -338,9 +338,12 @@ - Managed by your organization + Work apps: On - Notifications and apps are off + Work apps: Paused + + Work apps are paused + You won\'t get any work notifications, and your IT admin can\'t see your location Failed: %1$s diff --git a/res/values/styles.xml b/res/values/styles.xml index 80c791c589..35ae49c8ee 100644 --- a/res/values/styles.xml +++ b/res/values/styles.xml @@ -55,6 +55,8 @@ true #00000000 #00000000 + +